The following issue has been SUBMITTED.
======================================================================
http://www.cmake.org/Bug/view.php?id=14968
======================================================================
Reported By: Nico
Assigned To:
======================================================================
Project: CMake
Issue ID: 14968
Category: CMake
Reproducibility: always
Severity: major
Priority: normal
Status: new
======================================================================
Date Submitted: 2014-06-11 12:08 EDT
Last Modified: 2014-06-11 12:08 EDT
======================================================================
Summary: -fPIC not properly forwarded through OBJECT
libraries
Description:
When compiling a project that includes an OBJECT library, e.g.,
```
project(mytest C)
add_library(test2 OBJECT test2.c)
add_library(test test.c $<TARGET_OBJECTS:test2>)
```
and if BUILD_SHARED_LIBS is set to ON, the compile switch `-fPIC` will be
correctly added to the sources of `test`, but not to the sources of `test2`. The
library fails to link.
Additional Information:
The attachment contains a minimal failing example.
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
2014-06-11 12:08 Nico New Issue
2014-06-11 12:08 Nico File Added: 2014-06-11-fpic-object-lib.tar.bz2
======================================================================
--
Powered by www.kitware.com
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Kitware offers various services to support the CMake community. For more
information on each offering, please visit:
CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers