[CDRIVER-3783] compile definitions and include directories should be specified at the target level Created: 31/Aug/20  Updated: 28/Oct/23  Resolved: 31/Aug/20

Status: Closed
Project: C Driver
Component/s: Build, cmake
Affects Version/s: None
Fix Version/s: 1.18.0, 1.18.0-alpha

Type: Improvement Priority: Major - P3
Reporter: Roberto Sanchez Assignee: Roberto Sanchez
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to CDRIVER-3784 Eliminate references to CMAKE_BINARY_... Backlog
is related to CXX-1173 Support users adding mongocxx as a CM... Closed

 Description   

The CMakeLists.txt configuration for the C driver build currently specifies some compile definitions and include directories at the directory level. This was likely done so that the properties would apply to every target in a given directory (e.g., every variant of libbson and every variant of libmongoc). However, this prevents correctly referencing the targets from an external project that includes the C driver as a sub-project in a sub-directory of the parent project build. In order to correct this it is necessary to migrate the specification of compile definitions and include directories to attach them directly to targets in every case.



 Comments   
Comment by Githook User [ 31/Aug/20 ]

Author:

{'name': 'Roberto C. Sánchez', 'email': 'roberto@connexer.com', 'username': 'rcsanchez97'}

Message: CDRIVER-3783 apply compile definition and include directory properties at the target level (#680)
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/72c0ac6753aa57da52ba3c37143efabd898b8cd7

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