简体   繁体   中英

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++?

Please tell anything else than <cstdlib> 's system() . I want to know if there is anything with higher level and easy for use.

I have used boost.process since 0.1
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

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. 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.

Relevant in this case:

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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