# Contributor: Milan P. Stanić # Maintainer: Milan P. Stanić pkgname=m1n1 pkgver=0_git20220118 _commitid=2bd7bf40201427de8517b8e1fdc0f90357c1b0d9 _artwork_commitid=35626c31f5c5a8a884aaff93f864795026495742 pkgrel=0 pkgdesc="bootloader and experimentation playground for Apple Silicon" url="https://github.com/AsahiLinux/m1n1" arch="aarch64" license="MIT" options="!check" # no tests makedepends="rustup bash imagemagick dtc" source="m1n1-$pkgver.tar.gz::https://dev.alpinelinux.org/~mps/m1/m1n1-df53f16f763ef83c22d1453f799ba075dd7bf368.tar.gz artwork-$pkgver.tar.gz::https://github.com/AsahiLinux/artwork/archive/$_artwork_commitid.tar.gz https://dev.alpinelinux.org/~mps/m1/m1n1-rust.tar.gz" builddir="$srcdir/"m1n1-$_commitid prepare() { rmdir artwork cd $builddir default_prepare tar xf "$srcdir/"artwork-$pkgver.tar.gz tar xf "$srcdir/"m1n1-rust.tar.gz mv artwork-$_artwork_commitid artwork export RUSTUP_TOOLCHAIN=nightly rustup-init -y --default-toolchain nightly --profile minimal -t aarch64-unknown-none-softfloat } build() { source $HOME/.cargo/env make CHAINLOADING=1 ARCH= } package() { mkdir -p "$pkgdir"/usr/share/m1n1 install -p -Dm644 "$builddir"/build/m1n1.bin $pkgdir/usr/share/m1n1/ install -p -Dm644 "$builddir"/build/m1n1.macho $pkgdir/usr/share/m1n1/ } sha512sums=" ffedbadde3015edf3da12e5dcbcdbc327edf4e698634ca51c8c42b54268ded849682f6dc056be694ddb55020936b210836df781a53fb74e42c0874304772ccd3 m1n1-0_git20220118.tar.gz db83c018636d5148a2d7753fc6d5b7343684bc255b93cc3a6f08cf416ddab1d6ce4290b4a5692c30d1f8258db43d261598e45ebfef0066c632a00d7b53ea7881 artwork-0_git20220118.tar.gz 1b68cce27df8a7b99682daf3150a27b9c59c0e8224f3e75269378010cb6f17c065bf89822408cae49995681c348c05ea809670af011d9a819d55eec5d7929173 m1n1-rust.tar.gz "