macOS requires embedding plist files in order to enable modern security features such
as enabling the hardened runtime and notarizing executables and disk images containing them. This change provides a plist file to be embedded, and modifies the linker flags for macOS targets in order to include the plist in the binary. This is done to the Mach O executable in a backwards-compatible way, and has been tested as far back as macOS 10.12 High Sierra. Note: expect to carry this forward to 'next' branch; however this is being applied to current official release master version 5.6.0 so that release disk images can be notarized.
This commit is contained in:
parent
73689a443b
commit
a6e5c9ec1b
|
@ -439,6 +439,9 @@ if (SUPPORT_CONSOLE_APP)
|
|||
if (MSVC)
|
||||
set_target_properties( ${name} PROPERTIES DEBUG_POSTFIX d )
|
||||
endif ()
|
||||
if (APPLE)
|
||||
target_link_options(${name} PRIVATE LINKER:-sectcreate,__TEXT,__info_plist,${CMAKE_CURRENT_SOURCE_DIR}/console/Info.plist)
|
||||
endif ()
|
||||
if (NOT TIDY_CONSOLE_SHARED)
|
||||
set_target_properties( ${name} PROPERTIES
|
||||
COMPILE_FLAGS "-DTIDY_STATIC" )
|
||||
|
|
14
console/Info.plist
Normal file
14
console/Info.plist
Normal file
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>org.htacg.html-tidy.tidy5</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>5.6.0</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>5.6.0</string>
|
||||
</dict>
|
||||
</plist>
|
Loading…
Reference in a new issue