View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0016050 | CMake | CMake | public | 2016-04-06 03:41 | 2016-06-10 14:31 | ||||
Reporter | Lluís Batlle | ||||||||
Assigned To | Kitware Robot | ||||||||
Priority | normal | Severity | major | Reproducibility | always | ||||
Status | closed | Resolution | moved | ||||||
Platform | i686 | OS | Windows | OS Version | 7 | ||||
Product Version | CMake 3.5.1 | ||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0016050: Missing source files generate broken Makefiles (NMake) | ||||||||
Description | Using the "NMake Makefiles" and "NMake Makefiles JOM" generate broken makefiles, in case that one source file of ADD_EXECUTABLE is missing. | ||||||||
Steps To Reproduce | In my case, I have something like: ADD_EXECUTABLE(program WIN32 src1.cpp src1.hpp help.h) TARGET_LINK_LIBRARIES(program lib1 lib2) Running "cmake -G 'NMake Makefiles'" (or JOM) it reports properly: CMake Error at CMakeLists.txt:57 (ADD_EXECUTABLE): Cannot find source file: F:/projects/prog/build/help.h But then I can type "nmake program", and it goes on building lib1 and lib2, and then it tries to link program with the libs without any object files. It does not compile any "program" source files. Of course the linker reports missing _WinMainCRTStartup. | ||||||||
Additional Information | If I use the ninja generator, it works fine. When trying to run "ninja program", it tries to run cmake again, and it fails because of the missing source file. NMake should also do the same: run cmake again, to see if the CMakeLists.txt has been fixed and all sources are found. I had missed the "CMake Error" line when using NMake, and I spent time trying to find out the sudden miss of the _WinMainCRTStartup symbol. | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
Relationships | |
Relationships |
Notes | |
(0042976) Kitware Robot (administrator) 2016-06-10 14:29 |
Resolving issue as `moved`. This issue tracker is no longer used. Further discussion of this issue may take place in the current CMake Issues page linked in the banner at the top of this page. |
Notes |
Issue History | |||
Date Modified | Username | Field | Change |
2016-04-06 03:41 | Lluís Batlle | New Issue | |
2016-06-10 14:29 | Kitware Robot | Note Added: 0042976 | |
2016-06-10 14:29 | Kitware Robot | Status | new => resolved |
2016-06-10 14:29 | Kitware Robot | Resolution | open => moved |
2016-06-10 14:29 | Kitware Robot | Assigned To | => Kitware Robot |
2016-06-10 14:31 | Kitware Robot | Status | resolved => closed |
Issue History |
Copyright © 2000 - 2018 MantisBT Team |