Makefile中的宏定义必须采用 $(CC)和 $(CFLAGS)么? 磨砺技术珠矶,践行数据之道,追求卓越价值 回到上一级页面:PostgreSQL杂记页回到顶级页面:PostgreSQL索引页 如题: In particular, the macro CC is the C compiler to use, and CFLAGS is the list of flags to pass to the compilation command. 验证如下,...
LDFLAGS是选项,LIBS是要链接的库。 LDFLAGS=-L/var/xxx/lib-L/opt/mysql/lib LIBS=-lmysqlclient-liconv 命令行 建议在gcc命令行中显示的指定这些参数,而不是export的方式 $ gcc ${CFLAGS}main.c 再比如 ./configure--prefix=安装目录 CFLAGS="-I/home/testerzhang/3rd/openssl/include"LDFLAGS="-L/home/...
CFLAGS=-Wall -g hello: hello.o $(CC) $(CFLAGS) -o hello hello.o hello.o: hello.c;www.laipuhuo.com $(CC) $(CFLAGS) -c hello.c