diff --git a/.gitattributes b/.gitattributes index a21ce3334f..3754bf3595 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,2 +1,3 @@ -*.sql text eol=lf -app/win/zotero.exe.tar.xz filter=lfs diff=lfs merge=lfs -text +*.sql text eol=lf +app/win/zotero.exe.tar.xz filter=lfs diff=lfs merge=lfs -text +app/mac/updater.tar.xz filter=lfs diff=lfs merge=lfs -text diff --git a/app/build.sh b/app/build.sh index 88d3162a0f..bb8bb3b862 100755 --- a/app/build.sh +++ b/app/build.sh @@ -480,7 +480,7 @@ if [ $BUILD_MAC == 1 ]; then # Use our own updater, because Mozilla's requires updates signed by Mozilla cd "$CONTENTSDIR/MacOS" - tar -xjf "$CALLDIR/mac/updater.tar.bz2" + tar xf "$CALLDIR/mac/updater.tar.xz" # Modify Info.plist perl -pi -e "s/\{\{VERSION\}\}/$VERSION/" "$CONTENTSDIR/Info.plist" diff --git a/app/mac/build-and-unify b/app/mac/build-and-unify index 6601d88b0d..4f4bc9435a 100755 --- a/app/mac/build-and-unify +++ b/app/mac/build-and-unify @@ -55,3 +55,9 @@ $mach python "$GECKO_PATH/toolkit/mozapps/installer/unify.py" x64/*.app aarch64/ cp x64/$fx_app_name/Contents/MacOS/firefox zotero xz zotero mv zotero.xz "$APP_ROOT_DIR/mac/zotero.xz" + +# Uncomment to build updater +#cd x64/$fx_app_name/Contents/MacOS/ +#"$APP_ROOT_DIR/mac/updater_renamer" +#cat updater.app/Contents/Resources/English.lproj/InfoPlist.strings +#tar cfvJ "$APP_ROOT_DIR/mac/updater.tar.xz" updater.app/ diff --git a/app/mac/mozconfig b/app/mac/mozconfig index 96b45de79e..b78bb5dec5 100644 --- a/app/mac/mozconfig +++ b/app/mac/mozconfig @@ -25,3 +25,6 @@ export RELEASE_OR_BETA=1 MOZ_REQUIRE_SIGNING= ac_add_options --enable-official-branding + +# Build updater without MAR signature verification +ac_add_options --disable-verify-mar diff --git a/app/mac/updater.tar.bz2 b/app/mac/updater.tar.bz2 deleted file mode 100644 index 60a8289579..0000000000 Binary files a/app/mac/updater.tar.bz2 and /dev/null differ diff --git a/app/mac/updater.tar.xz b/app/mac/updater.tar.xz new file mode 100644 index 0000000000..1451d049cc --- /dev/null +++ b/app/mac/updater.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:53642619a815ae1c848dfb6f33e1e528db74edc39b3a692b6f312cace640c437 +size 92884 diff --git a/app/mac/updater_renamer b/app/mac/updater_renamer new file mode 100755 index 0000000000..52d5b42eae --- /dev/null +++ b/app/mac/updater_renamer @@ -0,0 +1,10 @@ +#!/usr/bin/env python3 + +# Convert localized app name from "Firefox Software Update" to "Zotero Software Update" +# +# plist is UTF-16 +f='updater.app/Contents/Resources/English.lproj/InfoPlist.strings' +with open(f, 'r', encoding='utf-16') as inputfile: + newText = inputfile.read().replace('Firefox', 'Zotero') +with open(f, 'w', encoding='utf-16') as outputfile: + outputfile.write(newText)