[CXX-511] Use of TARGET_OBJECTS in CMake build produces incorrect shared library Created: 06/Feb/15  Updated: 18/Feb/15  Resolved: 06/Feb/15

Status: Closed
Project: C++ Driver
Component/s: Build
Affects Version/s: None
Fix Version/s: 0.1.0

Type: Bug Priority: Critical - P2
Reporter: Andrew Morrow (Inactive) Assignee: Tyler Brock
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: PM-123

 Description   

We currently compose our top level dynamic library out of several smaller pseudo libraries, set up with TARGET_OBJECTS.

This doesn't work quite as intended however, because it means that target properties set on the shared object at the top level are not propagated to the compilation of the individual object files. For instance, setting CMAKE_CXX_VISIBILITY_PRESET to hidden does not cause -fvisibiliity-inlines-hidden to be applied to objects that are built into one of the TARGET_OBJECTS groups.

It is possible that there is a way around this, but even if there is, I'm not sure it is what we want.

The fact is that we want .o's that are compiled and headed, ultimately, for an archive to be built with different flags than those headed for a dynamic library.


Generated at Wed Feb 07 21:59:25 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.