mirror of
https://github.com/Yubico/yubioath-flutter.git
synced 2024-11-23 00:57:26 +03:00
Merge PR #1196.
This commit is contained in:
commit
4ffda92872
@ -154,16 +154,6 @@ Future<Widget> initialize(List<String> argv) async {
|
||||
exe = Uri.file(Platform.resolvedExecutable)
|
||||
.resolve(relativePath)
|
||||
.toFilePath();
|
||||
|
||||
if (Platform.isMacOS && Platform.version.contains('arm64')) {
|
||||
// See if there is an arm64 specific helper on arm64 Mac.
|
||||
final arm64exe = Uri.file(exe)
|
||||
.resolve('../helper-arm64/authenticator-helper')
|
||||
.toFilePath();
|
||||
if (await File(arm64exe).exists()) {
|
||||
exe = arm64exe;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
final rpcFuture = _initHelper(exe!);
|
||||
|
@ -17,7 +17,6 @@ then
|
||||
echo
|
||||
echo "# Sign the main binaries, with the entitlements"
|
||||
codesign -f --timestamp --options runtime --entitlements helper.entitlements --sign 'Application' Yubico\ Authenticator.app/Contents/Resources/helper/authenticator-helper
|
||||
codesign -f --timestamp --options runtime --entitlements helper.entitlements --sign 'Application' Yubico\ Authenticator.app/Contents/Resources/helper-arm64/authenticator-helper
|
||||
else
|
||||
echo "#################"
|
||||
echo "# No parameters given, this will be app store"
|
||||
@ -25,18 +24,15 @@ else
|
||||
echo
|
||||
echo "# Sign the main binaries, with sandbox enabled, without hardened runtime"
|
||||
codesign -f --timestamp --entitlements helper-sandbox.entitlements --sign 'Application' Yubico\ Authenticator.app/Contents/Resources/helper/authenticator-helper
|
||||
codesign -f --timestamp --entitlements helper-sandbox.entitlements --sign 'Application' Yubico\ Authenticator.app/Contents/Resources/helper-arm64/authenticator-helper
|
||||
fi
|
||||
|
||||
echo "# Sign the dylib and so files, without entitlements"
|
||||
cd Yubico\ Authenticator.app/
|
||||
codesign -f --timestamp --options runtime --sign 'Application' $(find Contents/Resources/helper/ -name "*.dylib" -o -name "*.so")
|
||||
codesign -f --timestamp --options runtime --sign 'Application' $(find Contents/Resources/helper-arm64/ -name "*.dylib" -o -name "*.so")
|
||||
codesign -f --timestamp --options runtime --sign 'Application' $(find Contents/Resources/helper/_internal/ -name "*.dylib" -o -name "*.so")
|
||||
cd ..
|
||||
|
||||
echo "# Sign the Python binary (if it exists), without entitlements"
|
||||
codesign -f --timestamp --options runtime --sign 'Application' Yubico\ Authenticator.app/Contents/Resources/helper-arm64/Python
|
||||
codesign -f --timestamp --options runtime --sign 'Application' Yubico\ Authenticator.app/Contents/Resources/helper/Python
|
||||
codesign -f --timestamp --options runtime --sign 'Application' Yubico\ Authenticator.app/Contents/Resources/helper/_internal/Python
|
||||
|
||||
echo "# Sign the GUI"
|
||||
codesign -f --timestamp --options runtime --sign 'Application' --entitlements Release.entitlements --deep "Yubico Authenticator.app"
|
||||
@ -49,7 +45,7 @@ then
|
||||
echo ${STATUS}
|
||||
|
||||
if [[ "$STATUS" == *"Accepted"* ]]; then
|
||||
echo "Notarization successfull. Staple the .app"
|
||||
echo "# Notarization successfull. Staple the .app"
|
||||
xcrun stapler staple -v "Yubico Authenticator.app"
|
||||
|
||||
echo "# Create dmg"
|
||||
@ -57,11 +53,21 @@ then
|
||||
mkdir source_folder
|
||||
mv "Yubico Authenticator.app" source_folder
|
||||
sh create-dmg.sh
|
||||
echo "# .dmg created. Everything should be ready for release!"
|
||||
echo "# .dmg created."
|
||||
else
|
||||
echo "Error uploading for notarization"
|
||||
exit
|
||||
fi
|
||||
|
||||
echo "# Sign the .dmg"
|
||||
codesign -f --timestamp --options runtime --sign 'Application' yubioath-desktop.dmg
|
||||
echo "# Notarize the .dmg"
|
||||
STATUS=$(xcrun notarytool submit "yubioath-desktop.dmg" --apple-id $1 --team-id LQA3CS5MM7 --password $2 --wait)
|
||||
echo ${STATUS}
|
||||
echo "# Staple the .dmg"
|
||||
xcrun stapler staple -v yubioath-desktop.dmg
|
||||
|
||||
echo "# Everything should be ready for release!"
|
||||
else # App store
|
||||
echo "# Build the package for AppStore submission"
|
||||
productbuild --sign 'Installer' --component "Yubico Authenticator.app" /Applications/ output-appstore.pkg
|
||||
|
Loading…
Reference in New Issue
Block a user