[英]Compiling c program Issue in terminal
I am trying to compile ac program in terminal. 我正在尝试在终端中编译AC程序。
This is my command: 这是我的命令:
gcc -1 string -o syncing.c -o syncing
This is my result: 这是我的结果:
clang: error: no input files
I know that -1
... indicates the library I used, syncing.c
is the c file I am trying to compile 我知道
-1
...表示我使用的库, syncing.c
是我要编译的c文件
What am I doing wrong with my command or is it something else? 我的命令在做什么错还是其他问题?
I am only using standard libraries. 我只使用标准库。
Please read this intro to GCC . 请阅读此GCC简介 。 You are telling it that
syncing.c
is your output file. 您正在告诉它
syncing.c
是您的输出文件。 But you want it to be your input file. 但是您希望它成为您的输入文件。
Also, I am not so sure on the -1
there. 另外,我不确定那里的
-1
。 You might want to have a look at this on how to include/link external libraries. 你可能想看看这个如何包括/链接外部库。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.