diff options
author | PA4WDH | 2021-12-17 11:40:48 +0100 |
---|---|---|
committer | PA4WDH | 2021-12-17 11:40:48 +0100 |
commit | 5322830a7a26abaa2dfec0959638bc9591559a38 (patch) | |
tree | 2e80e048dfeb97f10ddb82a8cb165cdcdf617a74 /sys-apps | |
parent | Add sys-kernel/sifive-sources-5.13.19 and sys-kernel/sifive-sources-5.14.15 (diff) | |
download | unmatched-patchwork-5322830a7a26abaa2dfec0959638bc9591559a38.tar.gz unmatched-patchwork-5322830a7a26abaa2dfec0959638bc9591559a38.tar.bz2 unmatched-patchwork-5322830a7a26abaa2dfec0959638bc9591559a38.zip |
Add sys-apps/sysvinit-3.01
Diffstat (limited to 'sys-apps')
-rw-r--r-- | sys-apps/sysvinit/Manifest | 5 | ||||
-rw-r--r-- | sys-apps/sysvinit/files/bootlogd.confd | 2 | ||||
-rw-r--r-- | sys-apps/sysvinit/files/bootlogd.initd | 4 | ||||
-rw-r--r-- | sys-apps/sysvinit/sysvinit-3.01.ebuild | 147 |
4 files changed, 155 insertions, 3 deletions
diff --git a/sys-apps/sysvinit/Manifest b/sys-apps/sysvinit/Manifest index 11af2a7..145e83a 100644 --- a/sys-apps/sysvinit/Manifest +++ b/sys-apps/sysvinit/Manifest @@ -1,4 +1,5 @@ -AUX bootlogd.initd 259 BLAKE2B 78c1a1fe8583685656edb85e29f8dbed40bdd7272590bbdaccb52fe6e54cce0a077a28501c7c87bec55f046172545d940c52345551cd3c01cff0895d12b32a15 SHA512 05a3c2542ceaff85c02c5c30a52be8f1bb95741fffef306777ad1b248b527cdd921f009571e1f43d7a6ede0cc61cf490a1dbbbfe0a50b234c258ad7688a37ad9 +AUX bootlogd.confd 71 BLAKE2B 5ead856ebc0af512d47b410dc4197b3287594943e535dd29c9de1b654de6dabde0a98ec8da21175d055795b7693ae52b399a246ed8c2a0a37336c541acbef071 SHA512 ecce46e1d538855c81a5c814b29240b9891b0367b45db98c1b8e9eccd724f360ca7b95da948e25d14d881eb84391dab9fd2aeef132345157d8bf7867658d98f5 +AUX bootlogd.initd 276 BLAKE2B afc0ce0406b38d9d29398f054668f78f0d90994421b3a8a1be97ea7d2f909a6675ddfbbe8aa21918acf1147bbb147c0d2465825ec13d86c82c85320f6a5d97e9 SHA512 e2e7edcd896900eb5860310af29233b29f438a5d5c07a5ab459da2ff9117cbb21c2f9b8f17f6817068c5444b4cd5d255a2197912907c1af39bdd23d1d6e10641 AUX halt.sh 101 BLAKE2B f3b8a24b6efce0ccffeb76f401af9f9bce752a541ea646dd6d357eaaa834be2049411148ec18b591283d85f42b0c3c1e41f442ba95c5f5b4cd9e87b39a83d51e SHA512 aaf46f9c74ae58027e59f32e5e929ff6529206d07fdf4e3f17962ccbc46c68d34e4e2839019708a763dead93b83ca8f457379491830ab43d6407247fd7ac2a77 AUX inittab-2.98-r1 2124 BLAKE2B 57e40e8410a31ec73f581e2feb142c600e2ce687745a6135961c0f1ea31e77f1acf9b9be1cf4c1d55685802a913304056cf1f137686f14d89caa9ec973d751c2 SHA512 6ce22ba933158d1a0fc7d0eaa9536b1cdcd8baa90cddfe8b1bf7a1f7292ba7fc14b6b46968848301a2e573939b4e21ce8d64bf3a9eaeb4d038de7d113fd3b9fb AUX sysvinit-2.86-kexec.patch 3910 BLAKE2B fb62326925c78960142123da82ffd1de6319153cce234b0d1dc7546beecf67296f8b7d6e3eb0f633d8a4ebc83fc4cc586c4f92cdb48df1f766aa4af72b0fa0e1 SHA512 6ce3adf698554d15394edbe6dbfc62822859854d503b201c9f96bd81c2a8cd249ed44229a85dd8b97f454f9311abc5792e349f5cc512ff6d5570500d88044bee @@ -7,7 +8,9 @@ AUX sysvinit-2.99-force-poweroff.patch 470 BLAKE2B 9d7ec8d81641b57a3ffac35a8fe53 AUX sysvinit-2.99-shutdown-h.patch 2684 BLAKE2B 57c27b8646a0b47f66eb103450e645fa45220a1bf79da86207ffa1393c311cb4c4a2ad9b8b7bf81cc4ae2ccb2acb19b66fd575935d8a0b0a2a9b3899c0088c9f SHA512 ef33da0d5673180275c8120c6904a4214cf1308827a626d8d6a2aab67d7d25b5407f9efcaf6a7a4a09a8c409899242943f6a95881cc8c8898b780224f991f2f7 DIST sysvinit-2.99.tar.xz 126908 BLAKE2B b82c745d5b695f918d4a163e7b9eaceccc07a46f73c3782c7771cc29a8600be13de4ff30891086df5773d60f37fa3b0f58566ccaf72cd70af68083b51152a38b SHA512 34f328d7d2e6ceddcddfebab49eb9c34e90dc96decf2caeb89dffd2ade54322fa4a3cb9fa1e1a4bc687e07fcb0a13e5aebe6186582a9f5c9153e1513baa87ddd DIST sysvinit-3.00.tar.xz 127072 BLAKE2B d1c4e509d7c13cf0fb9da290f875e7c0ab0666d843d75d4dd6885112248a859dd077bdf9cc926c4af58473da99a5229bb879c7094afd648d5ebe72597a3ba6a7 SHA512 ba834ac6c48528304373018bfb05dcdd3573d8081dd7dc95a44808804404d77ee4832fedb3f34e67d87f22f201f9526c54910a51c6ed2a42ac55b756843cd825 +DIST sysvinit-3.01.tar.xz 126616 BLAKE2B b991c6d2a09b02003cc587379b148f8ca3817c27fcaf81f184f679cfd5325e0b551484bba47bb554a34c7eeba60538f4943de49b1d59bd4bef73d7d086fefdb2 SHA512 66da3830aa32b70f0beea994213145a550e5b5d58a5b54afb17109243d5efface6aba8c296b76dbfb22ce6f86c9c58f237ff71ee04ec7d5b316ad412bf7acbcf EBUILD sysvinit-2.99-r1.ebuild 4148 BLAKE2B 199a03887551884ca4b1452c205943c45616c8101aeb7ecb5f1ffb094bb5200394deef2df158c9f357d57eeec25ba8d714f6db297e9a071bdb96d72e8625698e SHA512 bc7a6e7e287c61ddd3dc25bc83eedb4084d75b4da32a2244992a8edfa5fdb12e2fb4b5d0a2bc2fd6b9a0914825a4a8cce6b3dea9c7673c520b7e4ac21e61621d EBUILD sysvinit-2.99.ebuild 4089 BLAKE2B a9893ec8278e5f53528e15dab927b4f14e083861ef6017302ea6c5023bf108544c457c4d1a75c83801db10f3784694150828432e8986bdaf114aeb4d85ea876e SHA512 c53a1713ca68fccab0ad9e5483ecc0281546a14f7b04f59cb2bb949ad42a4b645ba2c31b4fc1a1a75b0431110bd22fb6e6dcb9ed5e8a12cd876f8c4e1db134f7 EBUILD sysvinit-3.00.ebuild 4099 BLAKE2B c282a062ebae85195d75c2b6b41185387410d63c8b9ac77bb2e53e70d25f20c3af8c472b100a295ef693117d56b24ab3f23519f1072938e31c283d7135e9e0c6 SHA512 3c883bc0bede52a10d195ca0a139a058cd158c4c124dee629bb1ed154543c6eab7af6ae8029ec674ef0fe2154755afc2a7e01553cf27fcccb845849524453b77 +EBUILD sysvinit-3.01.ebuild 4145 BLAKE2B 7f519d04687d6612640fe8d7909c1e4424dbd6e6983a6fc8be6fbeacf20959b84d944b70a2da30013aae0234357da613e94b9bc80ab0b464eb0591051706cadd SHA512 70932ab014de50c9a9abba7096e82c187d16e21fe9b862c79a5760564082a43b81caa0ae3b9773f9056afb5aa338167f2b59fee2d7c2f6f40e3ffac0b975ef16 MISC metadata.xml 451 BLAKE2B fef956bfea362642015d5f53f4d988967545ac34f38bc0d307940cc7d990c7bb640869b2613a878b2911322f2dd511ac03b4794807da246961d38662bdc894e3 SHA512 afa37929bb1610e47bb83adfac61df5d3fe25f6e5f23e8e81ef19729abf51ae97168a1b81d877dfe2a682d7889e14e8e8cc419cca7e5950e516d93853cbd6616 diff --git a/sys-apps/sysvinit/files/bootlogd.confd b/sys-apps/sysvinit/files/bootlogd.confd new file mode 100644 index 0000000..ac456db --- /dev/null +++ b/sys-apps/sysvinit/files/bootlogd.confd @@ -0,0 +1,2 @@ +# Put your bootlog options into this +#BOOTLOGD_ARGS="-l /var/log/boot" diff --git a/sys-apps/sysvinit/files/bootlogd.initd b/sys-apps/sysvinit/files/bootlogd.initd index a422192..ef238c1 100644 --- a/sys-apps/sysvinit/files/bootlogd.initd +++ b/sys-apps/sysvinit/files/bootlogd.initd @@ -1,8 +1,8 @@ #!/sbin/openrc-run -# Copyright 1999-2018 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 description="bootlogd - record boot messages (sysvinit)" pidfile="/run/bootlogd" command="/sbin/bootlogd" -command_args="-p ${pidfile}" +command_args="-p ${pidfile} ${BOOTLOGD_ARGS}" diff --git a/sys-apps/sysvinit/sysvinit-3.01.ebuild b/sys-apps/sysvinit/sysvinit-3.01.ebuild new file mode 100644 index 0000000..b8825f6 --- /dev/null +++ b/sys-apps/sysvinit/sysvinit-3.01.ebuild @@ -0,0 +1,147 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit toolchain-funcs flag-o-matic + +DESCRIPTION="/sbin/init - parent of all processes" +HOMEPAGE="https://savannah.nongnu.org/projects/sysvinit" +SRC_URI="mirror://nongnu/${PN}/${P/_/-}.tar.xz" + +LICENSE="GPL-2" +SLOT="0" +[[ "${PV}" == *beta* ]] || \ +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +IUSE="selinux ibm static kernel_FreeBSD" + +CDEPEND=" + selinux? ( + >=sys-libs/libselinux-1.28 + )" +DEPEND="${CDEPEND} + virtual/os-headers" +RDEPEND="${CDEPEND} + selinux? ( sec-policy/selinux-shutdown ) + !<sys-apps/openrc-0.13 +" + +S="${WORKDIR}/${P/_*}" + +PATCHES=( + "${FILESDIR}/${PN}-2.86-kexec.patch" #80220 + "${FILESDIR}/${PN}-2.94_beta-shutdown-single.patch" #158615 + "${FILESDIR}/${PN}-2.99-shutdown-h.patch" #449354 + "${FILESDIR}/${PN}-2.99-force-poweroff.patch" +) + +src_prepare() { + default + + sed -i \ + -e '/^CPPFLAGS =$/d' \ + -e '/^override CFLAGS +=/s/ -fstack-protector-strong//' \ + src/Makefile || die + + # last/lastb/mesg/mountpoint/sulogin/utmpdump/wall have moved to util-linux + sed -i -r \ + -e '/^(USR)?S?BIN/s:\<(last|lastb|mesg|mountpoint|sulogin|utmpdump|wall)\>::g' \ + -e '/^MAN[18]/s:\<(last|lastb|mesg|mountpoint|sulogin|utmpdump|wall)[.][18]\>::g' \ + src/Makefile || die + + # pidof has moved to >=procps-3.3.9 + sed -i -r \ + -e '/\/bin\/pidof/d' \ + -e '/^MAN8/s:\<pidof.8\>::g' \ + src/Makefile || die + + # logsave is already in e2fsprogs + sed -i -r \ + -e '/^(USR)?S?BIN/s:\<logsave\>::g' \ + -e '/^MAN8/s:\<logsave.8\>::g' \ + src/Makefile || die + + # Mung inittab for specific architectures + cd "${WORKDIR}" || die + cp "${FILESDIR}"/inittab-2.98-r1 inittab || die "cp inittab" + local insert=() + use ppc && insert=( '#psc0:12345:respawn:/sbin/agetty 115200 ttyPSC0 linux' ) + use arm && insert=( '#f0:12345:respawn:/sbin/agetty 9600 ttyFB0 vt100' ) + use arm64 && insert=( 'f0:12345:respawn:/sbin/agetty 9600 ttyAMA0 vt100' ) + use hppa && insert=( 'b0:12345:respawn:/sbin/agetty 9600 ttyB0 vt100' ) + use s390 && insert=( 's0:12345:respawn:/sbin/agetty 38400 console dumb' ) + use riscv && insert=( 'sif0:12345:respawn:/sbin/agetty -L 115200 ttySIF0 vt100' ) + if use ibm ; then + insert+=( + '#hvc0:2345:respawn:/sbin/agetty -L 9600 hvc0' + '#hvsi:2345:respawn:/sbin/agetty -L 19200 hvsi0' + ) + fi + (use arm || use mips || use sparc) && sed -i '/ttyS0/s:#::' inittab + if use kernel_FreeBSD ; then + sed -i \ + -e 's/linux/cons25/g' \ + -e 's/ttyS0/cuaa0/g' \ + -e 's/ttyS1/cuaa1/g' \ + inittab #121786 + fi + if use x86 || use amd64 ; then + sed -i \ + -e '/ttyS[01]/s:9600:115200:' \ + inittab + fi + if [[ ${#insert[@]} -gt 0 ]] ; then + printf '%s\n' '' '# Architecture specific features' "${insert[@]}" >> inittab + fi +} + +src_compile() { + tc-export CC + append-lfs-flags + export DISTRO= #381311 + export VERSION="${PV}" + use static && append-ldflags -static + emake -C src $(usex selinux 'WITH_SELINUX=yes' '') +} + +src_install() { + emake -C src install ROOT="${D}" + dodoc README doc/* + + insinto /etc + doins "${WORKDIR}"/inittab + + newinitd "${FILESDIR}"/bootlogd.initd bootlogd + newconfd "${FILESDIR}"/bootlogd.confd bootlogd + into / + dosbin "${FILESDIR}"/halt.sh + + keepdir /etc/inittab.d + + # dead symlink + find "${ED}" -xtype l -delete || die + + find "${ED}" -type d -empty -delete || die +} + +pkg_postinst() { + # Reload init to fix unmounting problems of / on next reboot. + # This is really needed, as without the new version of init cause init + # not to quit properly on reboot, and causes a fsck of / on next reboot. + if [[ -z ${ROOT} ]] ; then + if [[ -e /dev/initctl ]] && [[ ! -e /run/initctl ]] ; then + ln -s /dev/initctl /run/initctl \ + || ewarn "Failed to set /run/initctl symlink!" + fi + # Do not return an error if this fails + /sbin/telinit U &>/dev/null + fi + + elog "The last/lastb/mesg/mountpoint/sulogin/utmpdump/wall tools have been moved to" + elog "sys-apps/util-linux. The pidof tool has been moved to sys-process/procps." + + # Required for new bootlogd service + if [[ ! -e "${EROOT}/var/log/boot" ]] ; then + touch "${EROOT}/var/log/boot" + fi +} |