# Template file for 'm1n1' pkgname=m1n1 version=1.4.21 revision=1 archs="aarch64*" hostmakedepends="ImageMagick void-artwork" short_desc="Asahi Linux bootloader" maintainer="Will Springer , dkwo " license="MIT" homepage="https://asahilinux.org" distfiles="https://github.com/AsahiLinux/m1n1/archive/refs/tags/v${version}.tar.gz" checksum=5e0239ff497a8694eaf650d292254aba7d45611f37393053558ee36886db4111 conf_files="/etc/m1n1.conf /etc/default/m1n1-kernel-hook" post_extract() { for size in 128 256; do magick /usr/share/icons/hicolor/${size}x${size}/apps/void-logo.png \ -background black \ -flatten \ -depth 8 \ rgba:data/bootlogo_${size}.bin done } do_build() { unset CFLAGS CXXFLAGS CPPFLAGS LDFLAGS make RELEASE=1 ARCH=${CROSS_BUILD:+${XBPS_CROSS_TRIPLET}-} build/m1n1.bin } do_install() { vinstall build/m1n1.bin 644 usr/lib/asahi-boot } post_install() { vlicense LICENSE vinstall m1n1.conf.example 644 etc m1n1.conf vinstall ${FILESDIR}/m1n1-kernel-hook.confd 644 etc/default m1n1-kernel-hook vinstall ${FILESDIR}/kernel.d/m1n1.post-install 744 etc/kernel.d/post-install 50-m1n1 }