+ -
当前位置:首页 → 问答吧 → 如何编译完成直接执行

如何编译完成直接执行

时间:2011-04-12

来源:互联网

不想使用  gcc a.c  && ./a.out
能不能不出现 ./a.out

作者: ryh19860922   发布时间: 2011-04-12

-o file
           Place output in file file.  This applies regard-
           less to whatever sort of output is being pro-
           duced, whether it be an executable file, an
           object file, an assembler file or preprocessed C
           code.

           If -o is not specified, the default is to put an
           executable file in a.out, the object file for
           source.suffix in source.o, its assembler file in
           source.s, a precompiled header file in
           source.suffix.gch, and all preprocessed C source
           on standard output.

作者: 南极雨   发布时间: 2011-04-12

我的意思是不希望出现 ./*.out
即编译完就执行, 二进制文件最好不出现

作者: ryh19860922   发布时间: 2011-04-12

我的意思是不希望出现 ./*.out
即编译完就执行, 二进制文件最好不出现

作者: ryh19860922   发布时间: 2011-04-12

你以为是脚本啊
可以直接执行

作者: chenbin200818   发布时间: 2011-04-12

写个makefile

作者: li2002   发布时间: 2011-04-12

类是于这样的
gcc a.c -o - | eval -
但这个执行不了

作者: ryh19860922   发布时间: 2011-04-12