Skip to content

Commit 527cbe7

Browse files
committed
Initial experimen with BundleUtilities
1 parent b1494d5 commit 527cbe7

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/ngscopeclient/CMakeLists.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,8 +216,10 @@ add_custom_command(TARGET ngscopeclient POST_BUILD
216216
COMMAND_EXPAND_LISTS
217217
)
218218
endif()
219+
219220
###############################################################################
220221
# Installation
222+
221223
install(TARGETS ngscopeclient RUNTIME)
222224
install(DIRECTORY ${CMAKE_SOURCE_DIR}/src/ngscopeclient/fonts
223225
DESTINATION share/ngscopeclient)
@@ -246,6 +248,14 @@ if(LINUX)
246248
DESTINATION share/icons/hicolor/256x256/apps RENAME ngscopeclient.png)
247249
endif()
248250

251+
if(APPLE)
252+
set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR})
253+
install(CODE [[
254+
include(BundleUtilities)
255+
fixup_bundle("${CMAKE_INSTALL_PREFIX}/ngscopeclient-${NGSCOPECLIENT_VERSION}.app" "" "")
256+
]] COMPONENT Runtime)
257+
endif()
258+
249259
# ngscopeclient Windows portable zip/MSI installer build
250260
if(WIXPATH AND WIN32)
251261
# Run the command to get /mingw64/bin full path using where gcc

0 commit comments

Comments
 (0)