Redian新闻
>
help need for a make question (simple one)
avatar
help need for a make question (simple one)# Unix - 噫吁兮,危乎高哉
m*x
1
/bow first
This is a stupid simple question.
Why I cannot get "clean" functioning in make?
eg. This is my makefile:
prog: prog.o aid.o
gcc -o prog.o aid.o
prog.o: prog.c
gcc -c prog.c
aid.o: aid.c
gcc -c aid.c
clean:
rm *.o
everything is fine, except that "clean" task does not take place. Why?
/bow again
avatar
s*d
2
could it be a "tab" problem? I mean you mistakenly entered spaces instead of
a "tab" before "rm" .
br />

【在 m****x 的大作中提到】
: /bow first
: This is a stupid simple question.
: Why I cannot get "clean" functioning in make?
: eg. This is my makefile:
: prog: prog.o aid.o
: gcc -o prog.o aid.o
: prog.o: prog.c
: gcc -c prog.c
: aid.o: aid.c
: gcc -c aid.c

avatar
m*x
3
No. I have a tab there.

【在 s*****d 的大作中提到】
: could it be a "tab" problem? I mean you mistakenly entered spaces instead of
: a "tab" before "rm" .
: br />

avatar
m*m
4
Remove the empty line after "clean" target.
~{!>~} ~{TZ~} matrix (nxm matrix) ~{5D4sWwVPLa5=~}: ~{!?~}
avatar
c*t
5
You should be more careful:

^^^^^^^^^^^^^^^^^^^
gcc -o prog prog.o aid.o

【在 m****x 的大作中提到】
: /bow first
: This is a stupid simple question.
: Why I cannot get "clean" functioning in make?
: eg. This is my makefile:
: prog: prog.o aid.o
: gcc -o prog.o aid.o
: prog.o: prog.c
: gcc -c prog.c
: aid.o: aid.c
: gcc -c aid.c

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。