使用qmake执行shell命令 [英] Execute shell command using qmake

查看:125
本文介绍了使用qmake执行shell命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用 qmake 执行Shell命令.该命令是:

I want to execute a shell command using qmake. The command is :

idlpp -S -l cpp MyModel.idl

idlpp -S -l cpp MyModel.idl

这将处理我的IDL,并生成一些我要包含在项目中的.cpp和.h文件.现在,我正在从终端手动执行它,但是我希望在运行qmake时自动完成它.

This processes my IDL and generates some .cpp and .h files that I am including in my project. Right now I am executing it manually from a terminal but I want it to be automatically done when I run qmake.

我应该在我的 .pro 文件中添加什么?是否有与 cmake 使用的 execute_process()等效的东西?

What should I add in my .pro file? Is there something equivalent to the execute_process() used by cmake?

推荐答案

使用 system()函数

这篇关于使用qmake执行shell命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆