View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0015847 | CMake | CMake | public | 2015-11-16 16:28 | 2016-06-10 14:31 | ||||
Reporter | Erik Sjölund | ||||||||
Assigned To | Kitware Robot | ||||||||
Priority | normal | Severity | minor | Reproducibility | always | ||||
Status | closed | Resolution | moved | ||||||
Platform | x86_64 | OS | Ubuntu | OS Version | 15.10 | ||||
Product Version | CMake 3.4 | ||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0015847: ADD_LIBRARY without any sources generates an unnecessary warning | ||||||||
Description | I think this warning could be removed: "You have called ADD_LIBRARY for library foobar without any source files. This typically indicates a problem with your CMakeLists.txt file" The reason is that I would like to add the target sources at a later time with the target_sources command. For more explanation see my post: https://cmake.org/pipermail/cmake-developers/2015-July/025761.html [^] and the answer from Brad King: https://cmake.org/pipermail/cmake-developers/2015-July/025764.html [^] | ||||||||
Steps To Reproduce | See the attached file: bug.txt | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | bug.txt [^] (818 bytes) 2015-11-16 16:28 [Show Content] | ||||||||
Relationships | |
Relationships |
Notes | |
(0039944) Bartosz (reporter) 2015-12-03 04:26 |
The warning could be easily deleted from file: ./Source/cmAddLibraryCommand.cxx What kind of diagnostic (if at generate time no SOURCES are available) should be added? |
(0039947) Brad King (manager) 2015-12-03 08:23 |
> What kind of diagnostic (if at generate time no SOURCES are available) should be added? There is already a diagnostic in that case: CMake Error: Cannot determine link language for target "...". since the warning in question does not prevent generation from being attempted. If we remove the warning then the error message should be updated to mention that there are no source files (if indeed there are no sources). |
(0042888) 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 |
2015-11-16 16:28 | Erik Sjölund | New Issue | |
2015-11-16 16:28 | Erik Sjölund | File Added: bug.txt | |
2015-12-03 04:26 | Bartosz | Note Added: 0039944 | |
2015-12-03 08:23 | Brad King | Note Added: 0039947 | |
2016-06-10 14:29 | Kitware Robot | Note Added: 0042888 | |
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 |