GCC -E

days before I wrote a class with many macros, especially the ‘#'s,  to simplify the code, actually just to increase reusability, and the effect is very well. but it also brings problem to debug. it’s not easy to find out the errors if too much macros are involved, what’s worse is with template feature used. then I found the –E argument of GCC is useful, with which you can preprocess your code and check the preprocessed code to help finding the bugs. but there’s still a problem remains to resolve. the preprocessed code is bad-formatted, which is illegible. I didn’t find a good solution.

转载于:https://www.cnblogs.com/hpsoar/archive/2010/12/12/1904042.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
### 回答1: "gcc -e" 是 GCC 编译器的一个命令行选项,它用于指定程序的入口点。 "-e" 参数后跟着的是一个符号名,表示程序的入口点,在编译过程中,GCC 会将这个符号作为程序的入口。 例如,如果我们使用下面的命令编译一个程序: ``` gcc -e main test.c ``` 那么在编译过程中,GCC 就会将 "main" 这个符号作为程序的入口点。 ### 回答2: gcc -e 是指定输出文件的名称。在使用gcc编译器编译源代码时,可以使用-e选项来指定生成的可执行文件的名称。默认情况下,gcc会将可执行文件命名为a.out,但是通过使用-e选项,可以自定义可执行文件的名称。 例如,如果我们使用以下命令编译一个名为main.c的源代码文件: gcc main.c -o myprogram 其中,-o是gcc的选项之一,用于指定输出文件的名称。在上述命令中,我们通过-e选项将输出文件名设置为myprogram。这样,编译器将生成一个名为myprogram的可执行文件。 通过使用-e选项,我们可以为每个不同的可执行文件指定一个特定的名称,使得我们在编译多个源代码文件时可以很容易地区分它们。此外,自定义的输出文件名称也可以使得可执行文件更符合我们的需求和习惯。 总而言之,gcc -e是用于指定输出文件名称的选项,通过它,我们可以自定义生成的可执行文件的名称。 ### 回答3: gcc -e 是 gcc 编译器的一个选项,用于指定编译后的可执行文件的输出文件名。在命令行中,-e 后面可以跟一个文件名或者路径,这样编译后生成的可执行文件将被命名为指定的文件名或者位于指定路径下。 如果不指定 -e 选项,默认情况下,gcc 会将生成的可执行文件命名为 "a.out"。使用 -e 选项可以方便地指定可执行文件的命名,便于后续的操作和管理。例如,通过在命令行中使用 "gcc -e myprog",编译器将生成一个名为 "myprog" 的可执行文件。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值