From 15ff752737c53a1727cbc011068afa15683509be Mon Sep 17 00:00:00 2001 From: bruvzg <7645683+bruvzg@users.noreply.github.com> Date: Thu, 18 Mar 2021 23:00:05 +0200 Subject: [PATCH] Add "Replace existing signature" to the macOS export (enabled by default). (cherry picked from commit 9e18fce9431b25825742e13d03c2839a5060d4ec) --- platform/osx/export/export.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/platform/osx/export/export.cpp b/platform/osx/export/export.cpp index 5fd7d40040c2..135f064a5227 100644 --- a/platform/osx/export/export.cpp +++ b/platform/osx/export/export.cpp @@ -139,6 +139,7 @@ void EditorExportPlatformOSX::get_export_options(List *r_options) r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "codesign/identity", PROPERTY_HINT_PLACEHOLDER_TEXT, "Type: Name (ID)"), "")); r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "codesign/timestamp"), true)); r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "codesign/hardened_runtime"), true)); + r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "codesign/replace_existing_signature"), true)); r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "codesign/entitlements/custom_file", PROPERTY_HINT_GLOBAL_FILE, "*.plist"), "")); r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "codesign/entitlements/allow_jit_code_execution"), false)); @@ -423,6 +424,10 @@ Error EditorExportPlatformOSX::_code_sign(const Ref &p_prese args.push_back("-v"); /* provide some more feedback */ + if (p_preset->get("codesign/replace_existing_signature")) { + args.push_back("-f"); + } + args.push_back(p_path); String str;