【发布时间】:2020-04-20 06:50:48
【问题描述】:
我正在尝试在c++ 中为QNX 编写一个程序来执行其他程序。
为此,我要处理 4 个文件。
file1
file2.l
file3.c
file4.bin
算法是
if file1 is not present then execute file2.l
Execute file3.c
Execute file4.bin
这是我尝试过的代码。
#include<fstream>
#include<iostrea>
using namespace std;
int main(){
ifstream ifile;
ifile.open("file1");
if(!ifile){
// system("Code to run file2.l program in termnal")
}
// system("Code to run file3.c program in termnal")
system("./file4.bin")
我需要知道如何在QNX 中使用c++ 执行file2.l 和file3.c
【问题讨论】: