Jenkins: Attempt to fix macOS signing
This commit is contained in:
15
.ci/build.sh
15
.ci/build.sh
@@ -381,7 +381,7 @@ then
|
|||||||
(cd "archive_tmp_universal/$merge_src.app" && find . -type d && cd "../../archive_tmp_universal/$arch_universal.app" && find . -type d && cd ../..) | sort > universal_listing.txt
|
(cd "archive_tmp_universal/$merge_src.app" && find . -type d && cd "../../archive_tmp_universal/$arch_universal.app" && find . -type d && cd ../..) | sort > universal_listing.txt
|
||||||
cat universal_listing.txt | uniq | while IFS= read line
|
cat universal_listing.txt | uniq | while IFS= read line
|
||||||
do
|
do
|
||||||
echo '> Directory:' "$line"
|
echo "> Directory: $line"
|
||||||
mkdir -p "archive_tmp_universal/$merge_dest.app/$line"
|
mkdir -p "archive_tmp_universal/$merge_dest.app/$line"
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -397,7 +397,7 @@ then
|
|||||||
else
|
else
|
||||||
file_src="$arch_universal"
|
file_src="$arch_universal"
|
||||||
fi
|
fi
|
||||||
echo '> Only on' "[$file_src]:" "$line"
|
echo "> Only on [$file_src]: $line"
|
||||||
cp -p "archive_tmp_universal/$file_src.app/$line" "archive_tmp_universal/$merge_dest.app/$line"
|
cp -p "archive_tmp_universal/$file_src.app/$line" "archive_tmp_universal/$merge_dest.app/$line"
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -407,13 +407,13 @@ then
|
|||||||
# Merge identical files.
|
# Merge identical files.
|
||||||
if cmp -s "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$arch_universal.app/$line"
|
if cmp -s "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$arch_universal.app/$line"
|
||||||
then
|
then
|
||||||
echo '> Identical:' "$line"
|
echo "> Identical: $line"
|
||||||
cp -p "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$merge_dest.app/$line"
|
cp -p "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$merge_dest.app/$line"
|
||||||
elif lipo -create -output "archive_tmp_universal/$merge_dest.app/$line" "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$arch_universal.app/$line" 2> /dev/null
|
elif lipo -create -output "archive_tmp_universal/$merge_dest.app/$line" "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$arch_universal.app/$line" 2> /dev/null
|
||||||
then
|
then
|
||||||
echo '> Merged:' "$line"
|
echo "> Merged: $line"
|
||||||
else
|
else
|
||||||
echo '> Copied from' "[$merge_src]:" "$line"
|
echo "> Copied from [$merge_src]: $line"
|
||||||
cp -p "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$merge_dest.app/$line"
|
cp -p "archive_tmp_universal/$merge_src.app/$line" "archive_tmp_universal/$merge_dest.app/$line"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@@ -429,7 +429,7 @@ then
|
|||||||
file_src="$arch_universal"
|
file_src="$arch_universal"
|
||||||
fi
|
fi
|
||||||
link_dest="$(readlink "archive_tmp_universal/$file_src.app/$line")"
|
link_dest="$(readlink "archive_tmp_universal/$file_src.app/$line")"
|
||||||
echo '> Symlink:' "$line" '=>' "$link_dest"
|
echo "> Symlink: $line => $link_dest"
|
||||||
ln -s "$link_dest" "archive_tmp_universal/$merge_dest.app/$line"
|
ln -s "$link_dest" "archive_tmp_universal/$merge_dest.app/$line"
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -451,9 +451,10 @@ then
|
|||||||
mv "archive_tmp_universal/$merge_src.app" "$app_bundle_name"
|
mv "archive_tmp_universal/$merge_src.app" "$app_bundle_name"
|
||||||
|
|
||||||
# Sign final app bundle.
|
# Sign final app bundle.
|
||||||
codesign --force --deep -s - "$app_bundle_name"
|
arch -"$(uname -m)" codesign --force --deep -s - "$app_bundle_name"
|
||||||
|
|
||||||
# Create zip.
|
# Create zip.
|
||||||
|
echo [-] Creating artifact archive
|
||||||
cd archive_tmp
|
cd archive_tmp
|
||||||
zip -r "$cwd/$package_name.zip" .
|
zip -r "$cwd/$package_name.zip" .
|
||||||
status=$?
|
status=$?
|
||||||
|
Reference in New Issue
Block a user