1
0
Fork 0
flightgear/CMakeModules/Installation.cmake
James Turner 95fd692af1 CMake: move install() rule for compatability
Older CMake versions can’t install(TARGET…) from a different directory.
2020-08-23 21:50:36 +01:00

22 lines
837 B
CMake

if (TARGET sentry_crashpad::handler)
if (APPLE)
# install inside the bundle
install(FILES $<TARGET_FILE:sentry_crashpad::handler> DESTINATION fgfs.app/Contents/MacOS OPTIONAL)
else()
# install in the bin-dir, next to the application binary
install(FILES $<TARGET_FILE:sentry_crashpad::handler> DESTINATION ${CMAKE_INSTALL_BINDIR} OPTIONAL)
endif()
endif()
#-----------------------------------------------------------------------------
### uninstall target
#-----------------------------------------------------------------------------
CONFIGURE_FILE(
"${PROJECT_SOURCE_DIR}/CMakeModules/cmake_uninstall.cmake.in"
"${PROJECT_BINARY_DIR}/cmake_uninstall.cmake"
IMMEDIATE @ONLY)
ADD_CUSTOM_TARGET(uninstall
"${CMAKE_COMMAND}" -P "${PROJECT_BINARY_DIR}/cmake_uninstall.cmake")