| View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | ||||
| 0014561 | CMake | CMake | public | 2013-11-12 03:22 | 2014-06-02 08:37 | ||||
| Reporter | Kiron | ||||||||
| Assigned To | Stephen Kelly | ||||||||
| Priority | normal | Severity | minor | Reproducibility | always | ||||
| Status | closed | Resolution | fixed | ||||||
| Platform | OS | Windows | OS Version | 6.1 | |||||
| Product Version | CMake 2.8.12 | ||||||||
| Target Version | Fixed in Version | CMake 3.0 | |||||||
| Summary | 0014561: Errors with add_libaray(name INTERFACE) when TARGET_SUPPORTS_SHARED_LIBS is false | ||||||||
| Description | cmake version 2.8.12.20131111-g13da When using add_libaray(name INTERFACE) command the following warnings/errors are reported by cmake when TARGET_SUPPORTS_SHARED_LIBS is FALSE. Embedded cross compile targets usually do not support shared libs. (see also Steps To Preproduce) > cmake -H. -Bbuild -- Building for: Visual Studio 11 2012 -- The C compiler identification is MSVC 17.0.60610.1 -- The CXX compiler identification is MSVC 17.0.60610.1 -- Check for working C compiler using: Visual Studio 11 2012 -- Check for working C compiler using: Visual Studio 11 2012 -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working CXX compiler using: Visual Studio 11 2012 -- Check for working CXX compiler using: Visual Studio 11 2012 -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done CMake Warning (dev) at CMakeLists.txt:6 (add_library): ADD_LIBRARY called with MODULE option but the target platform does not support dynamic linking. Building a STATIC library instead. This may lead to problems. This warning is for project developers. Use -Wno-dev to suppress it. You have called ADD_LIBRARY for library foo without any source files. This typically indicates a problem with your CMake Lists.txt file -- Configuring done CMake Error: CMake can not determine linker language for target: foo -- Generating done -- Build files have been written to: C:/xxx/build > echo %ErrorLevel% 1 | ||||||||
| Steps To Reproduce | Create CMakeLists.txt with following content: cmake_minimum_required(VERSION 2.8.12.20131009) set_property(GLOBAL PROPERTY TARGET_SUPPORTS_SHARED_LIBS FALSE) add_library(foo INTERFACE) run following command: cmake -H. -Bbuild echo %ErrorLevel% | ||||||||
| Tags | No tags attached. | ||||||||
| Attached Files | |||||||||
| Relationships | |
| Relationships |
| Notes | |
|
(0034434) Stephen Kelly (developer) 2013-11-12 04:17 edited on: 2013-11-12 09:11 |
Fixed with add_library: Fix INTERFACE on platforms with no shared libs http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=64f73b0f [^] Thanks, |
|
(0036009) Robert Maynard (manager) 2014-06-02 08:37 |
Closing resolved issues that have not been updated in more than 4 months. |
| Notes |
| Issue History | |||
| Date Modified | Username | Field | Change |
| 2013-11-12 03:22 | Kiron | New Issue | |
| 2013-11-12 04:17 | Stephen Kelly | Note Added: 0034434 | |
| 2013-11-12 04:17 | Stephen Kelly | Status | new => resolved |
| 2013-11-12 04:17 | Stephen Kelly | Fixed in Version | => CMake 3.0 |
| 2013-11-12 04:17 | Stephen Kelly | Resolution | open => fixed |
| 2013-11-12 04:17 | Stephen Kelly | Assigned To | => Stephen Kelly |
| 2013-11-12 09:11 | Brad King | Note Edited: 0034434 | |
| 2014-06-02 08:37 | Robert Maynard | Note Added: 0036009 | |
| 2014-06-02 08:37 | Robert Maynard | Status | resolved => closed |
| Issue History |
| Copyright © 2000 - 2018 MantisBT Team |