linker input file unused because linking not done
2012-03-10 21:39
323 查看
在我编译一个c++程序的时候,发现这个错误,
$(OUTPUTNAME):$(OBJ)
$(CXX) $(CPPFLAGS) -c $< -o $@ $(INCLUDES)
改成:
%.o:%.cpp
$(CXX) $(CPPFLAGS) -c $< -o $@ $(INCLUDES)
就好了,因为编译的时候是 -c 参数 生成目标文件,不是生成最终链接文件。
$(OUTPUTNAME):$(OBJ)
$(CXX) $(CPPFLAGS) -c $< -o $@ $(INCLUDES)
改成:
%.o:%.cpp
$(CXX) $(CPPFLAGS) -c $< -o $@ $(INCLUDES)
就好了,因为编译的时候是 -c 参数 生成目标文件,不是生成最终链接文件。
相关文章推荐
- 问题linker input file unused because linking not done
- g++: -l[some]: linker input file unused because linking not done
- g++: -l[some]: linker input file unused because linking not done
- [Linux-C++] linker input file unused because linking not done 提示 编译与链接的知识
- 编译mjpg-streamer input_uvc 错误 linker input file unused because linking not done
- 静态库调用静态库&静态库加载静态库------谈谈undefined reference to和linker input file unused because linking not done
- 关于makefile报错:linker input file unused because linking not done
- apktool 反编译 Input file was not found or was not readable.问题解决方案
- "main" org.apache.hadoop.mapred.InvalidInputException: Input path does not exist: file
- Could not allocate space for object in database because the filegroup is full
- Caused by: java.io.FileNotFoundException:... cannot be opened because it does not exist
- 转:postgresql:pg_restore: [archiver] input file does not appear to be a valid archive的解决方法
- cannot be resolved to absolute file path because it does not reside in the file system
- ActivitiController - error on deploy process, because of file input stream
- postgresql:pg_restore: [archiver] input file does not appear to be a valid archive
- The specified module 'DistributedCacheAdministration' was not loaded because no valid module file wa
- jxl.read.biff.biffexception: the input file was not found
- java.io.FileNotFoundException: class path resource [META-INF/xfire/services.xml] cannot be opened because it does not exist
- maven构建 出错:cannot be resolved to absolute file path because it does not reside in the file system
- cleanup failed because the file not under version control问题的解决