You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When celero is added to a project as dependency via FetchContent and built in the consuming project build,
celeros explicit setting of CMAKE_<BUILD_TYPE>_POSTFIX spills into the consuming project.
This leads to library names added "-d" in debug mode. Which is not always wanted.
If those lines are needed, I would like to suggest putting it behind a cmake option for those who don't want this.
For example like
option(CELERO_SET_LIBRARY_POSTFIX "Set OFF to prevent celero setting cache variables for CMAKE_<BUILDTYPE>_POSTFIX." ON)
if(CELERO_SET_LIBRARY_POSTFIX)
set(CMAKE_DEBUG_POSTFIX "-d" CACHE STRING "add a postfix, usually d on windows")
set(CMAKE_RELEASE_POSTFIX "" CACHE STRING "add a postfix, usually empty on windows")
set(CMAKE_RELWITHDEBINFO_POSTFIX "-rd" CACHE STRING "add a postfix, usually empty on windows")
set(CMAKE_MINSIZEREL_POSTFIX "" CACHE STRING "add a postfix, usually empty on windows")
endif()
The text was updated successfully, but these errors were encountered:
ferkulat
added a commit
to ferkulat/Celero
that referenced
this issue
Oct 6, 2023
I see v2.9.0 might contain breaking changes.
That's why I would like to see this fix in a v2.8.X version.
Shall I make a pull request to branch "develop" instead?
When celero is added to a project as dependency via
FetchContent
and built in the consuming project build,celeros explicit setting of
CMAKE_<BUILD_TYPE>_POSTFIX
spills into the consuming project.This leads to library names added "-d" in debug mode. Which is not always wanted.
If those lines are needed, I would like to suggest putting it behind a cmake option for those who don't want this.
For example like
The text was updated successfully, but these errors were encountered: