-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
app-emulation/fex-rootfs-gentoo: Add 20240909
Signed-off-by: Sasha Finkelstein <fnkl.kernel@gmail.com>
- Loading branch information
Sasha Finkelstein
committed
Sep 14, 2024
1 parent
4c3aeaa
commit b5e3f13
Showing
3 changed files
with
70 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
DIST fex-rootfs-gentoo-20240909-root.sqfs 1588703232 BLAKE2B 480b33bd92ac88471d09841372670abd2700261859414c88e66a684cdc0acb8b8da771310be1e501d724dd17fe961c4f0eb46cca8cdb7798f069c64a5ea61333 SHA512 63145041935f3bf95303209e18f20f0f631106a2d58ca97ee25277badc6ecdd3157a3731789e72c0ba1df94b6576529d90b37aa22300dcb43579a471589723cb | ||
DIST fex-rootfs-gentoo-20240909.tar.gz 7089 BLAKE2B 617bab6bc524ab427b7554824ab74cd7daf5ae4f18730ac0f1aa2937dd71781ba379e08bf54fedbfec17683999832b2d910682817babdb1be69f0d4c42fa4ae7 SHA512 37f2ed0ffffdeec9e807b836b87bad480c20e4d1d657b1a9ac0c8004da51d9f839f449eb4c0b2c5717492eb880a580522d2edadb7d403796bbe43232b434ed0d |
58 changes: 58 additions & 0 deletions
58
app-emulation/fex-rootfs-gentoo/fex-rootfs-gentoo-20240909.ebuild
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# Copyright 1999-2024 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=8 | ||
|
||
inherit systemd linux-info | ||
|
||
DESCRIPTION="A x86 system image used for FEX" | ||
HOMEPAGE="https://github.com/WhatAmISupposedToPutHere/fex-rootfs" | ||
|
||
SRC_URI=" | ||
https://github.com/WhatAmISupposedToPutHere/fex-rootfs/releases/download/${PV}/fex-rootfs.sqfs -> ${P}-root.sqfs | ||
https://github.com/WhatAmISupposedToPutHere/fex-rootfs/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz | ||
" | ||
|
||
S="${WORKDIR}/fex-rootfs-${PV}" | ||
|
||
LICENSE="metapackage MIT" | ||
SLOT="0" | ||
KEYWORDS="-* ~arm64" | ||
RDEPEND=" | ||
systemd? ( sys-apps/systemd ) | ||
" | ||
DEPEND="${RDEPEND}" | ||
IUSE="systemd" | ||
|
||
pkg_pretend() { | ||
CONFIG_CHECK="~SQUASHFS ~SQUASHFS_ZSTD" | ||
check_extra_config | ||
[[ "${MERGE_TYPE}" != "buildonly" && "$(systemd_is_booted)" == 0 ]] || return | ||
ewarn "This package depends on systemd being the init system for correct operation" | ||
ewarn "On non-systemd systems assembling all the mount points correctly is left" | ||
ewarn "as an excercise for the user." | ||
} | ||
|
||
src_install() { | ||
local base="/usr/share/fex-emu-rootfs-layers/gentoo" | ||
insinto "${base}/images/" | ||
newins "${DISTDIR}/${P}-root.sqfs" 00-base.sqfs | ||
keepdir "${base}/work/" | ||
keepdir "${base}/writable/" | ||
gen_dir="$(systemd_get_systemgeneratordir)" | ||
exeinto "${gen_dir#"${EPREFIX}"}" | ||
doexe systemd/fex-gentoo-rootfs-generator | ||
systemd_dounit 'systemd/usr-share-fex\x2demu\x2drootfs\x2dlayers-gentoo-layers-00\x2dbase.mount' | ||
} | ||
|
||
pkg_prerm() { | ||
[[ "${MERGE_TYPE}" == "buildonly" || "$(systemd_is_booted)" == 0 ]] && return | ||
systemctl daemon-reload | ||
systemctl stop 'usr-share-fex\x2demu\x2drootfs\x2dlayers-gentoo-layers-00\x2dbase.mount' | ||
} | ||
|
||
pkg_postinst() { | ||
[[ "${MERGE_TYPE}" == "buildonly" || "$(systemd_is_booted)" == 0 ]] && return | ||
systemctl daemon-reload | ||
systemctl start 'usr-share-fex\x2demu-RootFS-Gentoo.mount' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> | ||
<pkgmetadata> | ||
<maintainer type="project"> | ||
<email>asahi@gentoo.org</email> | ||
</maintainer> | ||
<upstream> | ||
<remote-id type="github">WhatAmISupposedToPutHere/fex-rootfs</remote-id> | ||
</upstream> | ||
</pkgmetadata> |