Skip to content

Commit bd00434

Browse files
committed
Make OSC_NOTARIZATION_APPLE_ID, OSC_NOTARIZATION_TEAM_ID, and OSC_NOTARIZATION_PASSWORD required
1 parent 80204d8 commit bd00434

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

packaging/MacOS/Packaging.cmake

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ endif()
6464
if(OSC_CODESIGN_ENABLED)
6565
set(OSC_CODESIGN_DEVELOPER_ID "" CACHE STRING "The developer ID string for the codesigning key (e.g. 'Developer ID Application: Some Developer (XYA12398BF)'). Get it with `security find-identity -p codesigning -v`")
6666
if(NOT OSC_CODESIGN_DEVELOPER_ID)
67-
message(FATAL_ERROR "OSC_CODESIGN_DEVELOPER_ID must be set if OSC_CODESIGN_ENABLED is on. Example value: 'Developer ID Application Some Developer (XYA12398BF)'. Get it with `security find-identity -p codesigning -v`")
67+
message(FATAL_ERROR "OSC_CODESIGN_DEVELOPER_ID must be set if OSC_CODESIGN_ENABLED is on")
6868
endif()
6969

7070
# Specify a script that signs the built binaries just before CPack creates the DMG.
@@ -94,6 +94,16 @@ if(OSC_NOTARIZATION_ENABLED)
9494
set(OSC_NOTARIZATION_TEAM_ID "" CACHE STRING "Team ID of the signer (usually, random-looking string at the end of OSC_CODESIGN_DEVELOPER_ID)")
9595
set(OSC_NOTARIZATION_PASSWORD "" CACHE STRING "App-specific password of the signer (you can create this from your apple ID account)")
9696

97+
if(NOT OSC_NOTARIZATION_APPLE_ID)
98+
message(FATAL_ERROR "OSC_NOTARIZATION_APPLE_ID must be set if OSC_NOTARIZATION_ENABLED is on")
99+
endif()
100+
if(NOT OSC_NOTARIZATION_TEAM_ID)
101+
message(FATAL_ERROR "OSC_NOTARIZATION_TEAM_ID must be set if OSC_NOTARIZATION_ENABLED is on")
102+
endif()
103+
if(NOT OSC_NOTARIZATION_PASSWORD)
104+
message(FATAL_ERROR "OSC_NOTARIZATION_PASSWORD must be set if OSC_NOTARIZATION_ENABLE is on")
105+
endif()
106+
97107
# Specify a script that notarizes the DMG after CPack creates it and it's signed (above)
98108
configure_file(
99109
"${CMAKE_CURRENT_SOURCE_DIR}/MacOS/notarize_osc.dmg.cmake.in"

0 commit comments

Comments
 (0)