简体   繁体   English

是否有任何跨平台的lib可以通过c ++与shell(Windows中的cmd)一起使用?

[英]Is there any cross-platform lib to work with shell (cmd in windows) via c++?

Looking for cross-platform lib to work (run scripts, process results) with shell (cmd in windows) via c/c++? 通过c / c ++寻找跨平台的lib工作(运行脚本,处理结果)与shell(Windows中的cmd)?

Please tell anything else than <cstdlib> 's system() . 请告诉<cstdlib>system()以外的任何内容。 I want to know if there is anything with higher level and easy for use. 我想知道是否有更高级别和易于使用的东西。

I have used boost.process since 0.1 我从0.1开始使用boost.process
It is not officially included in boost mainstream, but seems to have reached a well tested state and seems to be on the point to be included. 它没有被正式纳入提升主流,但似乎已经达到了一个经过良好测试的状态,并且似乎已经被包括在内。

my2c MY2C

Maybe a little heavy-weight for just shell processing, but I find http://qt.nokia.com a very useful cross-platform library that will fulfill all needs from launching processes to parsing output and much more. 对于shell处理来说可能有点重量,但我发现http://qt.nokia.com是一个非常有用的跨平台库,可以满足从启动进程到解析输出等所有需求。 And I find it easy to use and quite well documented. 而且我发现它易于使用且记录完备。 You could probably limit yourself to using the core Qt library if you are not interested in Qt's cross-platform widget lib. 如果您对Qt的跨平台小部件库不感兴趣,您可能会限制自己使用核心Qt库。

Relevant in this case: 在这种情况下相关:

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM