当前位置: 技术问答>linux和unix
请人帮我看下我写的简单的makefile
来源: 互联网 发布时间:2016-03-02
本文导语: 当前工作目录下内容: Makefile src/ include/ include/ 目录下内容: head.h src/ 目录下内容: src.c makefile的内容: vpath= %.c ./src vpath= %.h ./include exercise:src.c head.h gcc -o exercise src.c .PHONY:cle...
当前工作目录下内容: Makefile src/ include/
include/ 目录下内容: head.h
src/ 目录下内容: src.c
makefile的内容:
vpath= %.c ./src
vpath= %.h ./include
exercise:src.c head.h
gcc -o exercise src.c
.PHONY:clean
clean:
rm *.o exercise
vpath
有什么问题?
include/ 目录下内容: head.h
src/ 目录下内容: src.c
makefile的内容:
vpath= %.c ./src
vpath= %.h ./include
exercise:src.c head.h
gcc -o exercise src.c
.PHONY:clean
clean:
rm *.o exercise
vpath
有什么问题?
|
真奇怪, 俺这里怎么没有问题
[code=BatchFile]
mymtom@fc6:src/csdn/unix/makefile$ ls -R
.:
include Makefile src
./include:
head.h
./src:
src.c
mymtom@fc6:src/csdn/unix/makefile$ cat Makefile
vpath %.c ./src
vpath %.h ./include
exercise: src.c head.h
$(CC) -o $@ $
[code=BatchFile]
mymtom@fc6:src/csdn/unix/makefile$ ls -R
.:
include Makefile src
./include:
head.h
./src:
src.c
mymtom@fc6:src/csdn/unix/makefile$ cat Makefile
vpath %.c ./src
vpath %.h ./include
exercise: src.c head.h
$(CC) -o $@ $
您可能感兴趣的文章:
本站(WWW.)旨在分享和传播互联网科技相关的资讯和技术,将尽最大努力为读者提供更好的信息聚合和浏览方式。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。
站内导航:
特别声明:169IT网站部分信息来自互联网,如果侵犯您的权利,请及时告知,本站将立即删除!