Add crossbuild scripts

This commit is contained in:
Laura Hausmann 2023-11-03 17:32:34 +01:00
parent 8ed20a09c2
commit 0365593990
Signed by untrusted user: zotan
GPG key ID: D044E84C5BE01605
2 changed files with 33 additions and 0 deletions

29
crossbuild.sh Executable file
View file

@ -0,0 +1,29 @@
#!/bin/bash
set -e
# Clean repo
cd ./mozilla-unified
git reset --hard
git clean -fd
# Prepare assets
mkdir -p snowleopard
cp ../assets/mozconfig mozconfig
cp ../assets/{local-settings.js,prefs.js,policies.json,moz.build,userChrome.css,userContent.css} snowleopard/
# Set up crossbuild
echo "" >> mozconfig
echo "ac_add_options --target=aarch64-apple-darwin" >> mozconfig
echo "ac_add_options --enable-bootstrap" >> mozconfig
# Prepare patches
for patch in ../patches/*.patch; do
echo "Applying $(basename "$patch")"
git apply "$patch"
done
# Build the thing
./mach build
# Package the thing
./mach package

4
package.sh Executable file
View file

@ -0,0 +1,4 @@
#!/bin/bash
set -e
cd mozilla-unified
./mach package