From 9e8f1754bd0a625e164e665b3fb5f3ecb4165be5 Mon Sep 17 00:00:00 2001 From: Vladimir Makarov Date: Tue, 17 Jan 2023 10:35:50 +0300 Subject: [PATCH 1/3] Xcode 14 building flags added --- ios_build_settings_renderer/models.py | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/ios_build_settings_renderer/models.py b/ios_build_settings_renderer/models.py index c0b0b03..e803089 100644 --- a/ios_build_settings_renderer/models.py +++ b/ios_build_settings_renderer/models.py @@ -38,7 +38,10 @@ def from_selectors(selectors): XCConfigOption.swift_optimization_level, XCConfigOption.swift_compilation_mode, XCConfigOption.assetcatalog_compiler_optimization, - XCConfigOption.other_swift_flags + XCConfigOption.other_swift_flags, + XCConfigOption.deployment_postprocessing, + XCConfigOption.strip_installed_product, + XCConfigOption.stripflags ]) ) @@ -123,6 +126,18 @@ def assetcatalog_compiler_optimization(selectors_dict): def other_swift_flags(selectors_dict): return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("OTHER_SWIFT_FLAGS", "$(inherited) -Xfrontend -warn-long-expression-type-checking=500 -Xfrontend -warn-long-function-bodies=500 -Xfrontend -enable-actor-data-race-checks", "$(inherited)", selectors_dict) + @staticmethod + def deployment_postprocessing(selectors_dict): + return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("DEPLOYMENT_POSTPROCESSING", "YES", "NO", selectors_dict) + + @staticmethod + def strip_installed_product(selectors_dict): + return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIP_INSTALLED_PRODUCT", "YES", "NO", selectors_dict) + + @staticmethod + def stripflags(selectors_dict): + return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIPFLAGS", "-rSTx", "", selectors_dict) + @staticmethod def __from_key_and_value_based_on_value_in_selectors(key, value_if_contains, otherwise_value, selectors_dict, expected_value="Debug"): From 2368e23a9012cf7e2178c26f79c3df5f1078db86 Mon Sep 17 00:00:00 2001 From: Vladimir Makarov Date: Tue, 17 Jan 2023 10:53:46 +0300 Subject: [PATCH 2/3] `Release` build type directly set --- ios_build_settings_renderer/models.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ios_build_settings_renderer/models.py b/ios_build_settings_renderer/models.py index e803089..58e311f 100644 --- a/ios_build_settings_renderer/models.py +++ b/ios_build_settings_renderer/models.py @@ -128,15 +128,15 @@ def other_swift_flags(selectors_dict): @staticmethod def deployment_postprocessing(selectors_dict): - return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("DEPLOYMENT_POSTPROCESSING", "YES", "NO", selectors_dict) + return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("DEPLOYMENT_POSTPROCESSING", "YES", "NO", selectors_dict, "Release") @staticmethod def strip_installed_product(selectors_dict): - return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIP_INSTALLED_PRODUCT", "YES", "NO", selectors_dict) + return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIP_INSTALLED_PRODUCT", "YES", "NO", selectors_dict, "Release") @staticmethod def stripflags(selectors_dict): - return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIPFLAGS", "-rSTx", "", selectors_dict) + return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIPFLAGS", "-rSTx", "", selectors_dict, "Release") @staticmethod def __from_key_and_value_based_on_value_in_selectors(key, value_if_contains, otherwise_value, From 2556a862973f1a55ddd4a1ba2ea1a51530174e9f Mon Sep 17 00:00:00 2001 From: Vladimir Makarov Date: Tue, 17 Jan 2023 11:00:02 +0300 Subject: [PATCH 3/3] `INSTALLED` changed to `LINKED` in a flag --- ios_build_settings_renderer/models.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ios_build_settings_renderer/models.py b/ios_build_settings_renderer/models.py index 58e311f..25d2c49 100644 --- a/ios_build_settings_renderer/models.py +++ b/ios_build_settings_renderer/models.py @@ -40,7 +40,7 @@ def from_selectors(selectors): XCConfigOption.assetcatalog_compiler_optimization, XCConfigOption.other_swift_flags, XCConfigOption.deployment_postprocessing, - XCConfigOption.strip_installed_product, + XCConfigOption.strip_linked_product, XCConfigOption.stripflags ]) ) @@ -131,8 +131,8 @@ def deployment_postprocessing(selectors_dict): return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("DEPLOYMENT_POSTPROCESSING", "YES", "NO", selectors_dict, "Release") @staticmethod - def strip_installed_product(selectors_dict): - return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIP_INSTALLED_PRODUCT", "YES", "NO", selectors_dict, "Release") + def strip_linked_product(selectors_dict): + return XCConfigOption.__from_key_and_value_based_on_value_in_selectors("STRIP_LINKED_PRODUCT", "YES", "NO", selectors_dict, "Release") @staticmethod def stripflags(selectors_dict):