Skip to content

Commit

Permalink
Allow for app bundle destination to be specified.
Browse files Browse the repository at this point in the history
  • Loading branch information
hmatuschek committed Apr 24, 2022
1 parent a6f3a6f commit 667526a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ option(BUILD_DOCS "Build API documentation" OFF)
option(BUILD_MAN "Build man page for dmrconf" OFF)
option(INSTALL_UDEV_RULES "Install udev rules file." ON)
option(INSTALL_BUNDLE "Installs QDMR as an AppBundle under MacOS X" OFF)
option(BUNDLE_PATH "Where to install the MacOS X application bundle." "~/Applications")

set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR}/cmake)

Expand Down
4 changes: 2 additions & 2 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ target_include_directories(qdmr PUBLIC "${CMAKE_CURRENT_BINARY_DIR}")
# Install binary only if not a bundle under MacOS X
if (UNIX AND APPLE AND INSTALL_BUNDLE)
install(TARGETS qdmr
BUNDLE DESTINATION /Applications/
RESOURCE DESTINATION "/Applications/${CMAKE_PROJECT_NAME}.app/Contents/Resources")
BUNDLE DESTINATION ${BUNDLE_PATH}/
RESOURCE DESTINATION "${BUNDLE_PATH}/${CMAKE_PROJECT_NAME}.app/Contents/Resources")
else()
install(TARGETS qdmr DESTINATION ${CMAKE_INSTALL_FULL_BINDIR})
endif(UNIX AND APPLE AND INSTALL_BUNDLE)

0 comments on commit 667526a

Please sign in to comment.