1
0
mirror of https://github.com/ThrowTheSwitch/Unity.git synced 2026-01-23 08:25:58 +01:00

Merge pull request #533 from carsonalh/master

Fixed CMake install when compiled with extensions
This commit is contained in:
Mark VanderVoord
2021-01-08 09:01:41 -05:00
committed by GitHub

View File

@@ -45,9 +45,8 @@ project(unity
option(UNITY_EXTENSION_FIXTURE "Compiles Unity with the \"fixture\" extension." OFF) option(UNITY_EXTENSION_FIXTURE "Compiles Unity with the \"fixture\" extension." OFF)
option(UNITY_EXTENSION_MEMORY "Compiles Unity with the \"memory\" extension." OFF) option(UNITY_EXTENSION_MEMORY "Compiles Unity with the \"memory\" extension." OFF)
# Fixture is a dependant of memory set(UNITY_EXTENSION_FIXTURE_ENABLED $<BOOL:${UNITY_EXTENSION_FIXTURE}>)
set(UNITY_EXTENSION_FIXTURE_ENABLED ${UNITY_EXTENSION_FIXTURE}) set(UNITY_EXTENSION_MEMORY_ENABLED $<OR:${UNITY_EXTENSION_FIXTURE_ENABLED},$<BOOL:${UNITY_EXTENSION_MEMORY}>>)
set(UNITY_EXTENSION_MEMORY_ENABLED $<OR:$<BOOL:${UNITY_EXTENSION_MEMORY}>,$<BOOL:${UNITY_EXTENSION_FIXTURE}>>)
if(${UNITY_EXTENSION_FIXTURE}) if(${UNITY_EXTENSION_FIXTURE})
message(STATUS "Unity: Bulding with the fixture extension.") message(STATUS "Unity: Bulding with the fixture extension.")
@@ -84,10 +83,9 @@ target_include_directories(${PROJECT_NAME}
set(${PROJECT_NAME}_PUBLIC_HEADERS set(${PROJECT_NAME}_PUBLIC_HEADERS
src/unity.h src/unity.h
src/unity_internals.h src/unity_internals.h
$<$<BOOL:${UNITY_EXTENSION_FIXTURE_ENABLED}>:extras/fixture/src/unity_fixture.h $<$<BOOL:${UNITY_EXTENSION_FIXTURE_ENABLED}>:${CMAKE_CURRENT_SOURCE_DIR}/extras/fixture/src/unity_fixture.h>
extras/fixture/src/unity_fixture_internals.h> $<$<BOOL:${UNITY_EXTENSION_FIXTURE_ENABLED}>:${CMAKE_CURRENT_SOURCE_DIR}/extras/fixture/src/unity_fixture_internals.h>
$<$<BOOL:${UNITY_EXTENSION_MEMORY_ENABLED}>:extras/memory/src/unity_memory.h $<$<BOOL:${UNITY_EXTENSION_MEMORY_ENABLED}>:${CMAKE_CURRENT_SOURCE_DIR}/extras/memory/src/unity_memory.h>
extras/memory/src/unity_memory_internals.h>
) )
set_target_properties(${PROJECT_NAME} set_target_properties(${PROJECT_NAME}