Skip to content

Commit 1f34bb1

Browse files
committed
Actually fix builds script. Extended attributes were being contained in the zipped version making the code signature invalid.
This must have been fine in practice, but validating with codesign --deep -vvvv --verify <unzipped_app_path> was yielding: `rejected (unsealed contents present in the root directory of an embedded framework)`
1 parent 3fbf117 commit 1f34bb1

File tree

2 files changed

+21
-2
lines changed

2 files changed

+21
-2
lines changed

GitUp/GitUp.xcodeproj/project.pbxproj

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -335,6 +335,7 @@
335335
E2C338A919F8562F00063D95 /* Resources */,
336336
E2653D271A5B3298006A9871 /* Copy Frameworks */,
337337
E21DCAF21B2538FB006424E8 /* Copy Tool */,
338+
1D7D03E724528390002C1736 /* Sparkle Code Sign */,
338339
1DE5583E2B9D89BF006BA332 /* Xcode 15 Framework Patching */,
339340
);
340341
buildRules = (
@@ -443,6 +444,24 @@
443444
/* End PBXResourcesBuildPhase section */
444445

445446
/* Begin PBXShellScriptBuildPhase section */
447+
1D7D03E724528390002C1736 /* Sparkle Code Sign */ = {
448+
isa = PBXShellScriptBuildPhase;
449+
buildActionMask = 2147483647;
450+
files = (
451+
);
452+
inputFileListPaths = (
453+
);
454+
inputPaths = (
455+
);
456+
name = "Sparkle Code Sign";
457+
outputFileListPaths = (
458+
);
459+
outputPaths = (
460+
);
461+
runOnlyForDeploymentPostprocessing = 0;
462+
shellPath = /bin/sh;
463+
shellScript = "# Code sign sparkle app\nLOCATION=\"${BUILT_PRODUCTS_DIR}\"/\"${FRAMEWORKS_FOLDER_PATH}\"\n\n# By default, use the configured code signing identity for the project/target\nIDENTITY=\"${EXPANDED_CODE_SIGN_IDENTITY}\"\nif [ \"$IDENTITY\" == \"\" ]\nthen\n # If a code signing identity is not specified, use ad hoc signing\n IDENTITY=\"-\"\nfi\n\n# Sparkle Code Signing https://sparkle-project.org/documentation/sandboxing/#code-signing\ncodesign -f -s \"$IDENTITY\" -o runtime \"$LOCATION/Sparkle.framework/Versions/B/XPCServices/Installer.xpc\"\n\n# For Sparkle versions >= 2.6\ncodesign -f -s \"$IDENTITY\" -o runtime --preserve-metadata=entitlements \"$LOCATION/Sparkle.framework/Versions/B/XPCServices/Downloader.xpc\"\n\ncodesign -f -s \"$IDENTITY\" -o runtime \"$LOCATION/Sparkle.framework/Versions/B/Autoupdate\"\ncodesign -f -s \"$IDENTITY\" -o runtime \"$LOCATION/Sparkle.framework/Versions/B/Updater.app\"\n\ncodesign -f -s \"$IDENTITY\" -o runtime \"$LOCATION/Sparkle.framework\"\n";
464+
};
446465
1DE5583E2B9D89BF006BA332 /* Xcode 15 Framework Patching */ = {
447466
isa = PBXShellScriptBuildPhase;
448467
buildActionMask = 8;

continuous-build.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ ARCHIVE_PATH="build/$ARCHIVE_NAME"
2323

2424
##### Notarize zip file
2525

26-
ditto -c -k --keepParent "$PRODUCT_PATH" "$ARCHIVE_PATH"
26+
ditto -c -k --keepParent --norsrc --noextattr "$PRODUCT_PATH" "$ARCHIVE_PATH"
2727

2828
# "PersonalNotary" is the profile name assigned from `notarytool store-credentials`
2929
xcrun notarytool submit $ARCHIVE_PATH --keychain-profile "PersonalNotary" --wait
@@ -34,7 +34,7 @@ echo "Notarization has completed"
3434

3535
xcrun stapler staple "$PRODUCT_PATH"
3636

37-
ditto -c -k --keepParent "$PRODUCT_PATH" "$ARCHIVE_PATH"
37+
ditto -c -k --keepParent --norsrc --noextattr "$PRODUCT_PATH" "$ARCHIVE_PATH"
3838

3939
##### Tag build
4040

0 commit comments

Comments
 (0)