The following issue has been SUBMITTED. 
====================================================================== 
http://www.cmake.org/Bug/view.php?id=14044 
====================================================================== 
Reported By:                Matthias Maier
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   14044
Category:                   CMake
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2013-03-27 08:50 EDT
Last Modified:              2013-03-27 08:50 EDT
====================================================================== 
Summary:                    The Xcode generator produces an invalid target that
will not get linked if it consists only of objects from object libraries
Description: 
Example code snippet:

  ADD_LIBRARY(foo OBJECT
    foo.cc
    )
  ADD_LIBRARY(bar SHARED
    $<TARGET_OBJECTS:foo>
    )

"$ xcodebuild -target bar" will compile foo.obj but libbar.dylib doesn't get
linked.

As a workaround,

  ADD_LIBRARY(foo OBJECT
    foo.cc
    )
  ADD_LIBRARY(bar SHARED
    dummy.cc
    $<TARGET_OBJECTS:foo>
    )

does work as expected (links dummy.obj and foo.obj to a libbar.dylib).
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2013-03-27 08:50 Matthias Maier New Issue                                    
======================================================================

--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to