From 73137627751cdd40652fc2868c66f0a7af0e3555 Mon Sep 17 00:00:00 2001 From: cranci1 <100066266+cranci1@users.noreply.github.com> Date: Mon, 9 Jun 2025 20:34:47 +0200 Subject: [PATCH] test --- Sulfur.xcodeproj/project.pbxproj | 8 ++------ macbuild.sh | 25 +++++++++++++++++++++---- 2 files changed, 23 insertions(+), 10 deletions(-) diff --git a/Sulfur.xcodeproj/project.pbxproj b/Sulfur.xcodeproj/project.pbxproj index eda7012..db766f1 100644 --- a/Sulfur.xcodeproj/project.pbxproj +++ b/Sulfur.xcodeproj/project.pbxproj @@ -914,9 +914,7 @@ INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UILaunchScreen_Generation = YES; - INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown"; INFOPLIST_KEY_UISupportsDocumentBrowser = YES; IPHONEOS_DEPLOYMENT_TARGET = 15.0; LD_RUNPATH_SEARCH_PATHS = ( @@ -956,9 +954,7 @@ INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UILaunchScreen_Generation = YES; - INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown"; INFOPLIST_KEY_UISupportsDocumentBrowser = YES; IPHONEOS_DEPLOYMENT_TARGET = 15.0; LD_RUNPATH_SEARCH_PATHS = ( diff --git a/macbuild.sh b/macbuild.sh index c0c5950..cf6cebc 100755 --- a/macbuild.sh +++ b/macbuild.sh @@ -16,19 +16,36 @@ cd build xcodebuild -project "$WORKING_LOCATION/$APPLICATION_NAME.xcodeproj" \ -scheme "$APPLICATION_NAME" \ -configuration Release \ - -derivedDataPath "$WORKING_LOCATION/build/DerivedDataApp" \ + -derivedDataPath "$WORKING_LOCATION/build/DerivedDataApp_arm64" \ -destination 'platform=macOS,variant=Mac Catalyst' \ + -arch arm64 \ clean build \ CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGN_ENTITLEMENTS="" CODE_SIGNING_ALLOWED="NO" -DD_APP_PATH="$WORKING_LOCATION/build/DerivedDataApp/Build/Products/Release-maccatalyst/$APPLICATION_NAME.app" +xcodebuild -project "$WORKING_LOCATION/$APPLICATION_NAME.xcodeproj" \ + -scheme "$APPLICATION_NAME" \ + -configuration Release \ + -derivedDataPath "$WORKING_LOCATION/build/DerivedDataApp_x86_64" \ + -destination 'platform=macOS,variant=Mac Catalyst' \ + -arch x86_64 \ + clean build \ + CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGN_ENTITLEMENTS="" CODE_SIGNING_ALLOWED="NO" + +ARM64_APP_PATH="$WORKING_LOCATION/build/DerivedDataApp_arm64/Build/Products/Release-maccatalyst/$APPLICATION_NAME.app" +X86_64_APP_PATH="$WORKING_LOCATION/build/DerivedDataApp_x86_64/Build/Products/Release-maccatalyst/$APPLICATION_NAME.app" TARGET_APP="$WORKING_LOCATION/build/$APPLICATION_NAME.app" -cp -r "$DD_APP_PATH" "$TARGET_APP" +cp -r "$ARM64_APP_PATH" "$TARGET_APP" + +lipo -create \ + "$ARM64_APP_PATH/Contents/MacOS/$APPLICATION_NAME" \ + "$X86_64_APP_PATH/Contents/MacOS/$APPLICATION_NAME" \ + -output "$TARGET_APP/Contents/MacOS/$APPLICATION_NAME" codesign --remove "$TARGET_APP" if [ -e "$TARGET_APP/_CodeSignature" ]; then rm -rf "$TARGET_APP/_CodeSignature" fi -echo "Mac Catalyst build completed: $TARGET_APP" +echo "Mac Catalyst universal binary build completed: $TARGET_APP" +lipo -info "$TARGET_APP/Contents/MacOS/$APPLICATION_NAME"