Compare commits
10 commits
0d2da01f72
...
428f2e4e2b
Author | SHA1 | Date | |
---|---|---|---|
James Calligeros | 428f2e4e2b | ||
James Calligeros | 02f24d3453 | ||
James Calligeros | b21726335e | ||
James Calligeros | a5e8de1eb2 | ||
James Calligeros | e421133300 | ||
James Calligeros | b2f7a4c346 | ||
James Calligeros | aa8fff35cf | ||
James Calligeros | 4d3c167a27 | ||
James Calligeros | b418dbf6db | ||
James Calligeros | 4cc18fa0a0 |
67
builder.sh
Normal file
67
builder.sh
Normal file
|
@ -0,0 +1,67 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# SPDX-License-Identifier: GPL-3.0-only
|
||||||
|
# Gentoo Asahi release builder
|
||||||
|
|
||||||
|
: ${BASEDIR:="/var/tmp/catalyst"}
|
||||||
|
: ${BUILDDIR:="${BASEDIR}/builds"}
|
||||||
|
: ${VER:=$(date +'%Y%m%d')}
|
||||||
|
: ${GENTOO_MIRROR:="https://mirror.aarnet.edu.au/pub/gentoo/"}
|
||||||
|
|
||||||
|
echo "Trying to enter ${BASEDIR}..."
|
||||||
|
cd "${BASEDIR}"
|
||||||
|
|
||||||
|
echo "Cleaning out ${BASEDIR}..."
|
||||||
|
#rm -rf "${BASEDIR}"/*
|
||||||
|
|
||||||
|
echo "Cloning Gentoo Asahi releng files..."
|
||||||
|
git clone https://github.com/chadmed/gentoo-asahi-releng \
|
||||||
|
--branch=asahi \
|
||||||
|
--depth=1 \
|
||||||
|
--quiet \
|
||||||
|
"${BASEDIR}/releng"
|
||||||
|
|
||||||
|
echo "Setting up ::gentoo repo"
|
||||||
|
mkdir "${BASEDIR}"/repos
|
||||||
|
git clone https://github.com/gentoo/gentoo.git \
|
||||||
|
--depth=1 \
|
||||||
|
--bare \
|
||||||
|
-c gc.reflogExpire=0 \
|
||||||
|
-c gc.reflogExpireUnreachable=0 \
|
||||||
|
-c gc.rerereresolved=0 \
|
||||||
|
-c gc.rerereunresolved=0 \
|
||||||
|
-c gc.pruneExpire=now \
|
||||||
|
--branch=master \
|
||||||
|
--quiet \
|
||||||
|
"${BASEDIR}/repos/gentoo.git"
|
||||||
|
catalyst --snapshot master
|
||||||
|
|
||||||
|
echo "Cloning ::asahi overlay"
|
||||||
|
git clone https://github.com/chadmed/asahi-overlay \
|
||||||
|
--quiet \
|
||||||
|
"${BASEDIR}/asahi-overlay"
|
||||||
|
|
||||||
|
echo "Getting latest stage3 from Gentoo Mirror..."
|
||||||
|
mkdir "${BASEDIR}"/builds
|
||||||
|
stage3_line=$(curl -L "${GENTOO_MIRROR}/releases/arm64/autobuilds/current-stage3-arm64-openrc/latest-stage3-arm64-openrc.txt" | grep "stage3")
|
||||||
|
stage3_path="${BASEDIR}/builds/${stage3_line% *}"
|
||||||
|
curl -L "${GENTOO_MIRROR}/releases/arm64/autobuilds/current-stage3-arm64-openrc/${stage3_line% *}" \
|
||||||
|
-o "${stage3_path}" -q
|
||||||
|
|
||||||
|
echo "Setting up spec files for build..."
|
||||||
|
cp "${BASEDIR}/releng/releases/specs/arm64/"*.spec "${BASEDIR}/."
|
||||||
|
echo " Setting version timestamp to ${VER}"
|
||||||
|
sed -i "s/@TIMESTAMP@/${VER}/g" "${BASEDIR}"/*.spec
|
||||||
|
echo " Setting ::gentoo snapshot to master"
|
||||||
|
sed -i "s/@TREEISH@/master/g" "${BASEDIR}"/*.spec
|
||||||
|
echo " Setting stage3 path"
|
||||||
|
sed -i "s+@STAGE3_PATH@+${stage3_line% *}+g" "${BASEDIR}"/*.spec
|
||||||
|
echo " Setting releng repo directory"
|
||||||
|
sed -i "s+@REPO_DIR@+${BASEDIR}/releng+g" "${BASEDIR}"/*.spec
|
||||||
|
echo " Setting asahi-overlay directory"
|
||||||
|
sed -i "s+@ASAHIOVERLAY@+${BASEDIR}/asahi-overlay+g" "${BASEDIR}"/*.spec
|
||||||
|
|
||||||
|
echo "Building stage1..."
|
||||||
|
catalyst -f installcd-stage1.spec
|
||||||
|
|
||||||
|
echo "Building stage2 ISO..."
|
||||||
|
catalyst -f installcd-stage2-minimal.spec
|
|
@ -1,2 +1,3 @@
|
||||||
dev-util/bindgen ~arm64
|
dev-util/bindgen ~arm64
|
||||||
sys-kernel/asahi-kernel ~arm64
|
sys-kernel/asahi-kernel ~arm64
|
||||||
|
virtual/dist-kernel ~arm64
|
||||||
|
|
|
@ -4,9 +4,10 @@ version_stamp: @TIMESTAMP@
|
||||||
rel_type: 23.0-default
|
rel_type: 23.0-default
|
||||||
profile: default/linux/arm64/23.0
|
profile: default/linux/arm64/23.0
|
||||||
snapshot_treeish: @TREEISH@
|
snapshot_treeish: @TREEISH@
|
||||||
source_subpath: 23.0-default/stage3-arm64-openrc-@TIMESTAMP@.tar.xz
|
source_subpath: @STAGE3_PATH@
|
||||||
compression_mode: pixz
|
compression_mode: pixz
|
||||||
portage_confdir: @REPO_DIR@/releases/portage/isos
|
portage_confdir: @REPO_DIR@/releases/portage/isos
|
||||||
|
repos: @ASAHIOVERLAY@ # Clone chadmed/asahi-overlay (GitHub) and point this to it
|
||||||
|
|
||||||
livecd/use:
|
livecd/use:
|
||||||
alsa
|
alsa
|
||||||
|
@ -102,3 +103,13 @@ livecd/packages:
|
||||||
sys-libs/gpm
|
sys-libs/gpm
|
||||||
sys-power/acpid
|
sys-power/acpid
|
||||||
www-client/links
|
www-client/links
|
||||||
|
# Asahi packages from ::gentoo
|
||||||
|
sys-fs/squashfs-tools
|
||||||
|
dev-util/bindgen
|
||||||
|
dev-lang/rust-bin
|
||||||
|
virtual/rust
|
||||||
|
app-portage/gentoolkit
|
||||||
|
# Asahi packages from ::asahi
|
||||||
|
sys-apps/asahi-configs
|
||||||
|
sys-apps/asahi-scripts
|
||||||
|
sys-firmware/asahi-firmware
|
||||||
|
|
|
@ -6,19 +6,19 @@ profile: default/linux/arm64/23.0
|
||||||
snapshot_treeish: @TREEISH@
|
snapshot_treeish: @TREEISH@
|
||||||
source_subpath: 23.0-default/livecd-stage1-arm64-@TIMESTAMP@.tar.xz
|
source_subpath: 23.0-default/livecd-stage1-arm64-@TIMESTAMP@.tar.xz
|
||||||
portage_confdir: @REPO_DIR@/releases/portage/isos
|
portage_confdir: @REPO_DIR@/releases/portage/isos
|
||||||
|
repos: @ASAHIOVERLAY@ # Clone chadmed/asahi-overlay (GitHub) and point this to it
|
||||||
|
|
||||||
livecd/bootargs: dokeymap
|
livecd/bootargs: dokeymap
|
||||||
livecd/fstype: squashfs
|
livecd/fstype: squashfs
|
||||||
livecd/gk_mainargs: --all-ramdisk-modules --firmware
|
livecd/iso: install-arm64-asahi-@TIMESTAMP@.iso
|
||||||
livecd/iso: install-arm64-minimal-@TIMESTAMP@.iso
|
|
||||||
livecd/type: gentoo-release-minimal
|
livecd/type: gentoo-release-minimal
|
||||||
livecd/volid: Gentoo arm64 @TIMESTAMP@
|
livecd/volid: Gentoo_Asahi_arm64_@TIMESTAMP@
|
||||||
|
|
||||||
boot/kernel: gentoo
|
boot/kernel: asahi
|
||||||
|
|
||||||
boot/kernel/gentoo/sources: sys-kernel/gentoo-sources
|
boot/kernel/asahi/distkernel: yes
|
||||||
boot/kernel/gentoo/config: @REPO_DIR@/releases/kconfig/arm64/arm64-5.15.12.config
|
boot/kernel/asahi/sources: sys-kernel/asahi-kernel
|
||||||
boot/kernel/gentoo/packages: --usepkg n zfs zfs-kmod
|
boot/kernel/asahi/dracut_args: --xz --no-hostonly -a dmsquash-live -o btrfs -o i18n -o usrmount -o lunmask -o multipath -i /lib/keymaps /lib/keymaps -I busybox
|
||||||
|
|
||||||
livecd/unmerge:
|
livecd/unmerge:
|
||||||
app-admin/eselect
|
app-admin/eselect
|
||||||
|
@ -63,6 +63,11 @@ livecd/unmerge:
|
||||||
sys-libs/gdbm
|
sys-libs/gdbm
|
||||||
sys-kernel/genkernel
|
sys-kernel/genkernel
|
||||||
sys-kernel/linux-headers
|
sys-kernel/linux-headers
|
||||||
|
dev-util/bindgen
|
||||||
|
dev-lang/rust-bin
|
||||||
|
virtual/rust
|
||||||
|
sys-devel/llvm
|
||||||
|
sys-devel/clang
|
||||||
|
|
||||||
livecd/empty:
|
livecd/empty:
|
||||||
/boot
|
/boot
|
||||||
|
|
Loading…
Reference in a new issue