Skip to content

Commit e3931c8

Browse files
committed
Sign DMG once built
1 parent 7908f02 commit e3931c8

5 files changed

Lines changed: 14 additions & 4 deletions

File tree

src/CMakeLists.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -332,6 +332,16 @@ if(APPLE)
332332
set(CPACK_DMG_FORMAT "UDZO")
333333
set(CPACK_DMG_CREATE_APPLICATIONS_LINK "ON")
334334
set(CPACK_DMG_DS_STORE "${DSSTORE_FILE}")
335+
336+
# Sign DMG after creation
337+
if(DEFINED CODESIGN_ID)
338+
configure_file(
339+
${CMAKE_SOURCE_DIR}/range-build-tools/packaging/macos/sign_dmg.cmake.in
340+
${CMAKE_BINARY_DIR}/packaging/macos/sign_dmg.cmake
341+
@ONLY
342+
)
343+
set(CPACK_POST_BUILD_SCRIPTS "${CMAKE_BINARY_DIR}/packaging/macos/sign_dmg.cmake")
344+
endif()
335345
endif()
336346

337347
# IFW

src/range-build-tools

src/range-gui-lib

0 commit comments

Comments
 (0)