-
Notifications
You must be signed in to change notification settings - Fork 30
Description
Steps to reproduce:
- build libace.a with
ACE_DEBUG
cmake switch set toON
- this will set the define with same name make install
the ACE library- use
find_library()
to include libace in your project
Expected behavior:
ACE_DEBUG
define persists and is used in ACE headers
Actual behavior:
ACE_DEBUG
is not set when building user's project, because it's only set when calling the ACE's CMakeLists.txt
Possible solution variant 1:
When installing the library, create the cmake script which will be called upon finding the ACE library, which will set same defines as its build phase.
That could be done with generating custom FindACE.cmake and installing it along with the library.
This should work, but my gut tells me it's not the way to go.
Possible solution variant 2:
When building the library, ace_config.h
could be created, which would store all the required ACE defines. this would also clear up the compile commands a bit, making it a bit lighter on parameter-specified defines. This works similarly to libjpeg and other "big" and "serious" libraries, so I think it's a good pattern to pursue.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status