From 0e4ab56e12439dcceb4f7ba6384cc6404c1de11b Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Fri, 25 Oct 2019 23:04:48 +0200 Subject: [PATCH] MacOSX: Update build script and Makefile to correctly build Legacy version of VeraCrypt that targets OSX 10.7+. --- src/Main/Main.make | 10 +++ src/Setup/MacOSX/veracrypt_Legacy.pkgproj | 103 +++++++++++++++++----- 2 files changed, 91 insertions(+), 22 deletions(-) diff --git a/src/Main/Main.make b/src/Main/Main.make index 9bf5b025..a154a846 100755 --- a/src/Main/Main.make +++ b/src/Main/Main.make @@ -221,9 +221,15 @@ install: prepare cp -R $(APPNAME).app /Applications/. package: prepare +ifdef VC_LEGACY_BUILD + /usr/local/bin/packagesbuild $(BASE_DIR)/Setup/MacOSX/veracrypt_Legacy.pkgproj + productsign --sign "Developer ID Installer: IDRIX (Z933746L2S)" --timestamp "$(BASE_DIR)/Setup/MacOSX/VeraCrypt Legacy $(TC_VERSION).pkg" $(BASE_DIR)/Setup/MacOSX/VeraCrypt_$(TC_VERSION).pkg + rm -f $(APPNAME)_Legacy_$(TC_VERSION).dmg +else /usr/local/bin/packagesbuild $(BASE_DIR)/Setup/MacOSX/veracrypt.pkgproj productsign --sign "Developer ID Installer: IDRIX (Z933746L2S)" --timestamp "$(BASE_DIR)/Setup/MacOSX/VeraCrypt $(TC_VERSION).pkg" $(BASE_DIR)/Setup/MacOSX/VeraCrypt_$(TC_VERSION).pkg rm -f $(APPNAME)_$(TC_VERSION).dmg +endif rm -f "$(BASE_DIR)/Setup/MacOSX/template.dmg" rm -fr "$(BASE_DIR)/Setup/MacOSX/VeraCrypt_dmg" mkdir -p "$(BASE_DIR)/Setup/MacOSX/VeraCrypt_dmg" @@ -231,7 +237,11 @@ package: prepare hdiutil attach "$(BASE_DIR)/Setup/MacOSX/template.dmg" -noautoopen -quiet -mountpoint "$(BASE_DIR)/Setup/MacOSX/VeraCrypt_dmg" cp "$(BASE_DIR)/Setup/MacOSX/VeraCrypt_$(TC_VERSION).pkg" "$(BASE_DIR)/Setup/MacOSX/VeraCrypt_dmg/VeraCrypt_Installer.pkg" hdiutil detach "$(BASE_DIR)/Setup/MacOSX/VeraCrypt_dmg" -quiet -force +ifdef VC_LEGACY_BUILD + hdiutil convert "$(BASE_DIR)/Setup/MacOSX/template.dmg" -quiet -format UDZO -imagekey zlib-level=9 -o $(APPNAME)_Legacy_$(TC_VERSION).dmg +else hdiutil convert "$(BASE_DIR)/Setup/MacOSX/template.dmg" -quiet -format UDZO -imagekey zlib-level=9 -o $(APPNAME)_$(TC_VERSION).dmg +endif rm -f "$(BASE_DIR)/Setup/MacOSX/template.dmg" rm -fr "$(BASE_DIR)/Setup/MacOSX/VeraCrypt_dmg" endif diff --git a/src/Setup/MacOSX/veracrypt_Legacy.pkgproj b/src/Setup/MacOSX/veracrypt_Legacy.pkgproj index 3de38f56..bbfa7ce7 100755 --- a/src/Setup/MacOSX/veracrypt_Legacy.pkgproj +++ b/src/Setup/MacOSX/veracrypt_Legacy.pkgproj @@ -5,6 +5,10 @@ PACKAGES + MUST-CLOSE-APPLICATION-ITEMS + + MUST-CLOSE-APPLICATIONS + PACKAGE_FILES DEFAULT_INSTALL_LOCATION @@ -253,7 +257,7 @@ PATH_TYPE 0 PERMISSIONS - 493 + 1005 TYPE 1 UID @@ -355,6 +359,38 @@ UID 0 + + CHILDREN + + GID + 0 + PATH + Automator + PATH_TYPE + 0 + PERMISSIONS + 493 + TYPE + 1 + UID + 0 + + + CHILDREN + + GID + 0 + PATH + Extensions + PATH_TYPE + 0 + PERMISSIONS + 493 + TYPE + 1 + UID + 0 + GID 0 @@ -468,15 +504,29 @@ PAYLOAD_TYPE 0 + PRESERVE_EXTENDED_ATTRIBUTES + + SHOW_INVISIBLE + + SPLIT_FORKS + + TREAT_MISSING_FILES_AS_WARNING + VERSION - 2 + 5 PACKAGE_SCRIPTS POSTINSTALL_PATH - + + PATH_TYPE + 0 + PREINSTALL_PATH - + + PATH_TYPE + 0 + RESOURCES @@ -486,6 +536,8 @@ 1 CONCLUSION_ACTION 0 + FOLLOW_SYMBOLIC_LINKS + IDENTIFIER com.idrix.pkg.veracrypt LOCATION @@ -494,9 +546,19 @@ veracrypt OVERWRITE_PERMISSIONS + PAYLOAD_SIZE + -1 + REFERENCE_PATH + + RELOCATABLE + + USE_HFS+_COMPRESSION + VERSION 1.24.7 + TYPE + 0 UUID B14381D9-EC5F-43E4-B971-82AB3D132A64 @@ -524,14 +586,15 @@ BACKGROUND - ALIGNMENT - 4 - BACKGROUND_PATH - - CUSTOM - - SCALING - 0 + APPAREANCES + + DARK_AQUA + + LIGHT_AQUA + + + SHARED_SETTINGS_FOR_ALL_APPAREANCES + INSTALLATION TYPE @@ -567,7 +630,7 @@ - INSTALLATION TYPE + MODE 0 INSTALLATION_STEPS @@ -636,8 +699,6 @@ LICENSE - KEYWORDS - LOCALIZATIONS @@ -813,10 +874,6 @@ https://osxfuse.github.io/ - POSTINSTALL_PATH - - PREINSTALL_PATH - RESOURCES ROOT_VOLUME_ONLY @@ -824,8 +881,6 @@ https://osxfuse.github.io/ PROJECT_SETTINGS - ADVANCED_OPTIONS - BUILD_FORMAT 0 BUILD_PATH @@ -1004,7 +1059,11 @@ https://osxfuse.github.io/ NAME - VeraCrypt 1.24-Hotfix1 + VeraCrypt Legacy 1.24-Hotfix1 + PAYLOAD_ONLY + + TREAT_MISSING_PRESENTATION_DOCUMENTS_AS_WARNING + SHARED_GLOBAL_DATA