Merge pull request #822 from flatcar/sayan/weekly-update-04052023

Automate updates of system packages: sys-apps/*
This commit is contained in:
Sayan Chowdhury 2023-06-15 14:41:54 +05:30 committed by GitHub
commit 87d6a33fde
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
151 changed files with 6941 additions and 1581 deletions

View File

@ -350,20 +350,46 @@ profiles
sys-apps/acl
sys-apps/attr
sys-apps/coreutils
sys-apps/debianutils
sys-apps/diffutils
sys-apps/dtc
sys-apps/ethtool
sys-apps/file
sys-apps/findutils
sys-apps/gawk
sys-apps/gentoo-functions
sys-apps/gptfdisk
sys-apps/grep
sys-apps/groff
sys-apps/help2man
sys-apps/hwdata
sys-apps/i2c-tools
sys-apps/iproute2
sys-apps/iucode_tool
sys-apps/kbd
sys-apps/kexec-tools
sys-apps/kmod
sys-apps/less
sys-apps/lshw
sys-apps/makedev
sys-apps/man-db
sys-apps/man-pages
sys-apps/man-pages-posix
sys-apps/miscfiles
sys-apps/net-tools
sys-apps/nvme-cli
sys-apps/pciutils
sys-apps/portage
sys-apps/pv
sys-apps/sandbox
sys-apps/sed
sys-apps/semodule-utils
sys-apps/smartmontools
sys-apps/texinfo
sys-apps/usbutils
sys-apps/util-linux
sys-apps/which
sys-devel/autoconf
sys-devel/autoconf-archive

View File

@ -0,0 +1,17 @@
- coreutils ([9.1](https://git.savannah.gnu.org/cgit/coreutils.git/tree/NEWS?h=v9.1))
- debianutils ([5.7](https://metadata.ftp-master.debian.org/changelogs//main/d/debianutils/debianutils_5.7-0.4_changelog))
- ethtool ([6.2](https://git.kernel.org/pub/scm/network/ethtool/ethtool.git/tree/NEWS?h=v6.2))
- grep ([3.8](http://savannah.gnu.org/forum/forum.php?forum_id=10227))
- hwdata ([0.367](https://github.com/vcrhonek/hwdata/releases/tag/v0.367))
- iproute ([6.2](https://lwn.net/Articles/923952/))
- kbd ([2.5.1](https://github.com/legionus/kbd/releases/tag/v2.5.1))
- kexec-tools ([2.0.24](https://github.com/horms/kexec-tools/releases/tag/v2.0.24))
- kmod ([30](https://lwn.net/Articles/899526/))
- nvme-cli ([2.3](https://github.com/linux-nvme/nvme-cli/releases/tag/v2.3))
- pciutils ([3.9.0](https://github.com/pciutils/pciutils/releases/tag/v3.9.0))
- sed ([4.9](https://lists.gnu.org/archive/html/info-gnu/2022-11/msg00001.html))
- smartmontools ([7.3](https://github.com/smartmontools/smartmontools/releases/tag/RELEASE_7_3))
- usbutils ([015](https://github.com/gregkh/usbutils/blob/79b796f945ea7d5c2b0e2a74f9b8819cb7948680/NEWS))
- util-linux ([2.38.1](https://github.com/util-linux/util-linux/releases/tag/v2.38.1))
- SDK: man-db ([2.11.2](https://gitlab.com/man-db/man-db/-/tags/2.11.2))
- SDK: man-pages ([6.03](https://lore.kernel.org/lkml/d56662b2-538c-7252-9052-8afbf325f843@gmail.com/T/))

View File

@ -25,7 +25,7 @@
=sys-apps/checkpolicy-3.1 ~arm64
=sys-apps/policycoreutils-3.1-r3 ~arm64
=sys-apps/kexec-tools-2.0.22 ~arm64
=sys-apps/kexec-tools-2.0.24 ~arm64
=sys-apps/semodule-utils-3.1 ~arm64

View File

@ -29,9 +29,6 @@
# To keep the same version on both arches
=sys-fs/multipath-tools-0.9.4-r1 ~amd64
# Keep iproute in sync with kernel version.
=sys-apps/iproute2-5.15.0 ~amd64 ~arm64
# FIPS support is still being tested
=sys-fs/cryptsetup-2.4.3-r1 ~amd64 ~arm64
@ -48,3 +45,4 @@
=sys-libs/liburing-2.1-r2 ~amd64 ~arm64
=app-crypt/adcli-0.9.2 ~amd64 ~arm64
=sys-apps/nvme-cli-2.4-r2 ~amd64 ~arm64

View File

@ -1,3 +1,9 @@
DIST coreutils-8.30-patches-01.tar.xz 5788 BLAKE2B a41511ce39ac570cb14b7f12d125eebef92217469a9490808719fa0665f5e5c0adb96fbd02c4bac4d280d1502295669575790a81dbc01afe2ca3a9d384cbefb0 SHA512 b1e1933637de4581d5f8c6ede4e80a012435d13f0cf5550a76ab5bbe9441e3c15ce19ef3f78a7ea3b8368d5e9a3bb17c1207c471d26171b59786f38adeba0454
DIST coreutils-8.32.tar.xz 5547836 BLAKE2B 0ad99c176c19ec214fcfd0845523e5362f0151827707c759bd46c0fe8d2501c6ad1c29c5b71266f6525857bc0d56c472db0d7fe29953b6c65e2e6c76bdf3c515 SHA512 1c8f3584efd61b4b02e7ac5db8e103b63cfb2063432caaf1e64cb2dcc56d8c657d1133bbf10bd41468d6a1f31142e6caa81d16ae68fa3e6e84075c253613a145
DIST coreutils-9.0.tar.xz 5612752 BLAKE2B 59617cd25fd4c70f51bfbef851bd83e73f9c9ba5c11eb539f7f75c0184d55832e004b28e9268fb8064db145cb071ead2b9c0c3346bc35a11934ffe1b15bf17ac SHA512 9be08212891dbf48e5b22e7689dc27dac50df4631ebf29313470b72b7921f0b2aa5242917d05587785358495ca56e3b21f5b3ca81043d53cab92354da6c53a03
DIST coreutils-9.0_p20220409-patches-01.tar.xz 6244 BLAKE2B 8ca9855680719660782931467ec70095c826e66b9850890b8cf456963f8114f63940707386b97c766172d01e55e17b7db2aa1c329208a873a76e2293b29f565f SHA512 4b43c25832122d241f33e6b4eff24bc1fa045b9ca5af45a49d22ecb1fa282986c4e4a045ef24c34b3d94fd9a2247247c42c344261e3f464d881969e6f3351d3f
DIST coreutils-9.1.tar.xz 5712104 BLAKE2B f5654e4935535275615d44a56c071d1c0746af36cf4615fcc0a5a0d387af9c9023adac31f31a52e16b3d1105b9d4c0fb7ebff9b2862498849f867a866049dd6e SHA512 a6ee2c549140b189e8c1b35e119d4289ec27244ec0ed9da0ac55202f365a7e33778b1dc7c4e64d1669599ff81a8297fe4f5adbcc8a3a2f75c919a43cd4b9bdfa
DIST coreutils-9.1.tar.xz.sig 833 BLAKE2B e9627a066f3c67596feaa8d43d5785076230f440bacea84d8b5736e51a22787c2d5df1f3e2cd8523d01fb7b468933d3c17fce3cb1fbefef322a0e0d820b81842 SHA512 9f0766531afd4faa3e2c337730f61db55605cf06729e9c61f644594883732c2e0b1ddb0005b492be309c53e6f45b8ff875398163a48699d52517ea49e9bdbc91
DIST coreutils-9.2.tar.xz 5773008 BLAKE2B 026e01718d79dd95bf645088d395584cbd422bb318f414a6ad325aea5deeec7aecb63217c1ce8231e81dd3b6fee1c85c60616c57ef8e2e1d0b9d764fa5a68908 SHA512 7e3108fefba4ef995cc73c64ac5f4e09827a44649a97ddd624eb61d67ce82da5ed6dc8c0f79d3e269f5cdb7d43877a61ef5b93194dd905bec432a7e31f9f479c
DIST coreutils-9.2.tar.xz.sig 833 BLAKE2B 225f6ea9d6c2a2b0e47093b6c10d648b8d847daf0733eeb779eb01cffde47f67b3328bdfb214298d669689f5de76f3c64384a6471dfc4ccc3a238bfc1943e654 SHA512 4219f3103d829841a11bf1fe42ae277a44347e555fbbaf48e5e87cce48deb96753cb6d25f2571b88685a164acb9f016ff7ea02346b799ce954599fa0124ef070
DIST coreutils-9.3.tar.xz 5808696 BLAKE2B 11502cd2dbeef150d0d4cece2546bf6b835941b94456c258f6058338f0477f22e68e88934d075b08fe51ee4d1c0c50cb23d8084ac06a457d6e8975f01643b1cd SHA512 242271f212a6860bdc6c8d7e5c4f85ce66c1b48ef781aca9daa56e0fe7c2b7809ef72b4392120219fe5b687637c83ce89ceef8bb35f6274f43f8f968a6901694
DIST coreutils-9.3.tar.xz.sig 833 BLAKE2B c45ae10ff706907ae65d31228e432f7d6f34acbdb733bf521437d9e2fc75828a59da9d432d894a1ed8b7341f7e15d0e8d4e816e209c799b75c14d0ec055bfdf2 SHA512 522a2072f8ef940228ccdd856a4041c3c16b98e309168ccf2066fe7c1013685ba6cdea8a7317dfa1f4507b37ca016ecedaf54438d4a5007927b0e1a8fd223eb5

View File

@ -1,9 +1,9 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python3_{7..10} )
PYTHON_COMPAT=( python3_{9..10} )
inherit flag-o-matic python-any-r1 toolchain-funcs
@ -17,7 +17,7 @@ SRC_URI="mirror://gnu/${PN}/${P}.tar.xz
)
"
LICENSE="GPL-3"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x86-linux"
IUSE="acl caps gmp hostname kill multicall nls selinux +split-usr static test vanilla xattr"

View File

@ -1,30 +1,45 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python3_{8..10} )
# Try to keep an eye on Fedora's packaging: https://src.fedoraproject.org/rpms/coreutils
# The upstream coreutils maintianers also maintain the package in Fedora and may
# backport fixes which we want to pick up.
inherit flag-o-matic python-any-r1 toolchain-funcs
PYTHON_COMPAT=( python3_{9..11} )
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/coreutils.asc
inherit flag-o-matic python-any-r1 toolchain-funcs verify-sig
PATCH="${PN}-8.30-patches-01"
MY_PATCH="${PN}-9.0_p20220409-patches-01"
DESCRIPTION="Standard GNU utilities (chmod, cp, dd, ls, sort, tr, head, wc, who,...)"
HOMEPAGE="https://www.gnu.org/software/coreutils/"
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz
!vanilla? (
mirror://gentoo/${PATCH}.tar.xz
https://dev.gentoo.org/~polynomial-c/dist/${PATCH}.tar.xz
)"
LICENSE="GPL-3"
if [[ ${PV} == *_p* ]] ; then
# Note: could put this in devspace, but if it's gone, we don't want
# it in tree anyway. It's just for testing.
MY_SNAPSHOT="$(ver_cut 1-2).193-54bec"
SRC_URI="https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz -> ${P}.tar.xz"
SRC_URI+=" verify-sig? ( https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz.sig -> ${P}.tar.xz.sig )"
S="${WORKDIR}"/${PN}-${MY_SNAPSHOT}
else
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz
verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x86-linux"
fi
SRC_URI+=" !vanilla? ( https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${MY_PATCH}.tar.xz )"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x86-linux"
IUSE="acl caps gmp hostname kill multicall nls selinux +split-usr static test vanilla xattr"
IUSE="acl caps gmp hostname kill multicall nls +openssl selinux +split-usr static test vanilla xattr"
RESTRICT="!test? ( test )"
LIB_DEPEND="acl? ( sys-apps/acl[static-libs] )
caps? ( sys-libs/libcap )
gmp? ( dev-libs/gmp:=[static-libs] )
openssl? ( dev-libs/openssl:=[static-libs] )
xattr? ( sys-apps/attr[static-libs] )"
RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs]} )
selinux? ( sys-libs/libselinux )
@ -42,6 +57,7 @@ BDEPEND="
dev-util/strace
${PYTHON_DEPS}
)
verify-sig? ( sec-keys/openpgp-keys-coreutils )
"
RDEPEND+="
hostname? ( !sys-apps/net-tools[hostname] )
@ -58,61 +74,29 @@ RDEPEND+="
!<app-forensics/tct-1.18-r1
!<net-fs/netatalk-2.0.3-r4"
pkg_pretend() {
if has_version "<sys-fs/zfs-9999" ; then
einfo "Checking for running ZFS module version"
local kmodv minver
kmodv="$(grep kmod <(zfs -V 2>/dev/null))"
# Convert zfs-kmod-2.1.1-r3-gentoo -> 2.1.1-r3
kmodv="${kmodv//zfs-kmod-}"
kmodv="${kmodv%%-gentoo}"
minver="$(ver_cut 2 ${kmodv})"
local diemsg=$(cat <<-EOF
Attempted installation of ${P} on unsupported version of zfs-kmod!
Please reboot to a newer version of zfs-kmod first:
zfs-kmod >=2.0.7 or zfs-kmod >=2.1.1-r3
Using ${P} with running version of zfs-kmod of can
lead to data loss while using cp command on some configurations.
See https://github.com/openzfs/zfs/issues/11900 for details.
EOF
)
case "${minver}" in
# 2.0.x
0)
ver_test "${kmodv}" -lt 2.0.7 && die "${diemsg}"
;;
# 2.1.x
1)
ver_test "${kmodv}" -lt 2.1.1-r3 && die "${diemsg}"
;;
# 0.8.x/9999
*)
# We can't really cover this case realistically
# 9999 is too hard to check and 0.8.x isn't being supported anymore.
;;
esac
fi
}
pkg_setup() {
if use test ; then
python-any-r1_pkg_setup
fi
}
src_unpack() {
if use verify-sig ; then
# Needed for downloaded patch (which is unsigned, which is fine)
verify-sig_verify_detached "${DISTDIR}"/${P}.tar.xz{,.sig}
fi
default
}
src_prepare() {
local PATCHES=(
# Upstream patches
"${FILESDIR}"/${P}-fix-chmod-symlink-exit.patch
"${FILESDIR}"/${P}-fix-rename-simple-backups.patch
)
if ! use vanilla ; then
PATCHES+=( "${WORKDIR}"/patch )
PATCHES+=( "${FILESDIR}"/${PN}-8.32-sandbox-env-test.patch )
fi
default
@ -150,6 +134,7 @@ src_configure() {
$(use_enable multicall single-binary)
$(use_enable xattr)
$(use_with gmp libgmp)
$(use_with openssl)
)
if use gmp ; then
@ -216,8 +201,7 @@ src_test() {
addwrite /dev/full
#export RUN_EXPENSIVE_TESTS="yes"
#export FETISH_GROUPS="portage wheel"
env PATH="${T}/mount-wrappers:${PATH}" \
emake -j1 -k check
env PATH="${T}/mount-wrappers:${PATH}" emake -k check VERBOSE=yes
}
src_install() {

View File

@ -0,0 +1,269 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Try to keep an eye on Fedora's packaging: https://src.fedoraproject.org/rpms/coreutils
# The upstream coreutils maintianers also maintain the package in Fedora and may
# backport fixes which we want to pick up.
PYTHON_COMPAT=( python3_{9..11} )
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/coreutils.asc
inherit flag-o-matic python-any-r1 toolchain-funcs verify-sig
MY_PATCH="${PN}-9.0_p20220409-patches-01"
DESCRIPTION="Standard GNU utilities (chmod, cp, dd, ls, sort, tr, head, wc, who,...)"
HOMEPAGE="https://www.gnu.org/software/coreutils/"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.savannah.gnu.org/git/coreutils.git"
inherit git-r3
elif [[ ${PV} == *_p* ]] ; then
# Note: could put this in devspace, but if it's gone, we don't want
# it in tree anyway. It's just for testing.
MY_SNAPSHOT="$(ver_cut 1-2).198-e68b1"
SRC_URI="https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz -> ${P}.tar.xz"
SRC_URI+=" verify-sig? ( https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz.sig -> ${P}.tar.xz.sig )"
S="${WORKDIR}"/${PN}-${MY_SNAPSHOT}
else
SRC_URI="
mirror://gnu/${PN}/${P}.tar.xz
verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )
"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x86-linux"
fi
SRC_URI+=" !vanilla? ( https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${MY_PATCH}.tar.xz )"
LICENSE="GPL-3+"
SLOT="0"
IUSE="acl caps gmp hostname kill multicall nls +openssl selinux +split-usr static test vanilla xattr"
RESTRICT="!test? ( test )"
LIB_DEPEND="
acl? ( sys-apps/acl[static-libs] )
caps? ( sys-libs/libcap )
gmp? ( dev-libs/gmp:=[static-libs] )
openssl? ( dev-libs/openssl:=[static-libs] )
xattr? ( sys-apps/attr[static-libs] )
"
RDEPEND="
!static? ( ${LIB_DEPEND//\[static-libs]} )
selinux? ( sys-libs/libselinux )
nls? ( virtual/libintl )
"
DEPEND="
${RDEPEND}
static? ( ${LIB_DEPEND} )
"
BDEPEND="
app-arch/xz-utils
dev-lang/perl
test? (
dev-lang/perl
dev-perl/Expect
dev-util/strace
${PYTHON_DEPS}
)
verify-sig? ( sec-keys/openpgp-keys-coreutils )
"
RDEPEND+="
hostname? ( !sys-apps/net-tools[hostname] )
kill? (
!sys-apps/util-linux[kill]
!sys-process/procps[kill]
)
!app-misc/realpath
!<sys-apps/util-linux-2.13
!<sys-apps/sandbox-2.10-r4
!sys-apps/stat
!net-mail/base64
!sys-apps/mktemp
!<app-forensics/tct-1.18-r1
!<net-fs/netatalk-2.0.3-r4"
pkg_setup() {
if use test ; then
python-any-r1_pkg_setup
fi
}
src_unpack() {
if [[ ${PV} == 9999 ]] ; then
git-r3_src_unpack
cd "${S}" || die
./bootstrap || die
sed -i -e "s:submodule-checks ?= no-submodule-changes public-submodule-commit:submodule-checks ?= no-submodule-changes:" gnulib/top/maint.mk || die
elif use verify-sig ; then
# Needed for downloaded patch (which is unsigned, which is fine)
verify-sig_verify_detached "${DISTDIR}"/${P}.tar.xz{,.sig}
fi
default
}
src_prepare() {
local PATCHES=(
# Upstream patches
"${FILESDIR}"/${P}-cksum-result-reporting.patch
"${FILESDIR}"/${P}-cp-reflink-auto-fallback.patch
)
if ! use vanilla && [[ -d "${WORKDIR}"/patch ]] ; then
PATCHES+=( "${WORKDIR}"/patch )
fi
default
# Since we've patched many .c files, the make process will try to
# re-build the manpages by running `./bin --help`. When doing a
# cross-compile, we can't do that since 'bin' isn't a native bin.
#
# Also, it's not like we changed the usage on any of these things,
# so let's just update the timestamps and skip the help2man step.
set -- man/*.x
touch ${@/%x/1} || die
# Avoid perl dep for compiled in dircolors default (bug #348642)
if ! has_version dev-lang/perl ; then
touch src/dircolors.h || die
touch ${@/%x/1} || die
fi
}
src_configure() {
local myconf=(
--with-packager="Gentoo"
--with-packager-version="${PVR} (p${PATCH_VER:-0})"
--with-packager-bug-reports="https://bugs.gentoo.org/"
# kill/uptime - procps
# groups/su - shadow
# hostname - net-tools
--enable-install-program="arch,$(usev hostname),$(usev kill)"
--enable-no-install-program="groups,$(usev !hostname),$(usev !kill),su,uptime"
--enable-largefile
$(usex caps '' --disable-libcap)
$(use_enable nls)
$(use_enable acl)
$(use_enable multicall single-binary)
$(use_enable xattr)
$(use_with gmp libgmp)
$(use_with openssl)
)
if use gmp ; then
myconf+=( --with-libgmp-prefix="${ESYSROOT}"/usr )
fi
if tc-is-cross-compiler && [[ ${CHOST} == *linux* ]] ; then
# bug #311569
export fu_cv_sys_stat_statfs2_bsize=yes
# bug #416629
export gl_cv_func_realpath_works=yes
fi
# bug #409919
export gl_cv_func_mknod_works=yes
if use static ; then
append-ldflags -static
# bug #321821
sed -i '/elf_sys=yes/s:yes:no:' configure || die
fi
if ! use selinux ; then
# bug #301782
export ac_cv_{header_selinux_{context,flash,selinux}_h,search_setfilecon}=no
fi
econf "${myconf[@]}"
}
src_test() {
# Known to fail with FEATURES=usersandbox (bug #439574):
# - tests/du/long-from-unreadable.sh} (bug #413621)
# - tests/rm/deep-2.sh (bug #413621)
# - tests/dd/no-allocate.sh (bug #629660)
if has usersandbox ${FEATURES} ; then
ewarn "You are emerging ${P} with 'usersandbox' enabled." \
"Expect some test failures or emerge with 'FEATURES=-usersandbox'!"
fi
# Non-root tests will fail if the full path isn't
# accessible to non-root users
chmod -R go-w "${WORKDIR}" || die
chmod a+rx "${WORKDIR}" || die
# coreutils tests like to do `mount` and such with temp dirs,
# so make sure:
# - /etc/mtab is writable (bug #265725)
# - /dev/loop* can be mounted (bug #269758)
mkdir -p "${T}"/mount-wrappers || die
mkwrap() {
local w ww
for w in "${@}" ; do
ww="${T}/mount-wrappers/${w}"
cat <<-EOF > "${ww}"
#!${EPREFIX}/bin/sh
exec env SANDBOX_WRITE="\${SANDBOX_WRITE}:/etc/mtab:/dev/loop" $(type -P ${w}) "\$@"
EOF
chmod a+rx "${ww}" || die
done
}
mkwrap mount umount
addwrite /dev/full
#export RUN_EXPENSIVE_TESTS="yes"
#export FETISH_GROUPS="portage wheel"
env PATH="${T}/mount-wrappers:${PATH}" gl_public_submodule_commit= \
emake -k check VERBOSE=yes
}
src_install() {
default
insinto /etc
newins src/dircolors.hin DIR_COLORS
if use split-usr ; then
cd "${ED}"/usr/bin || die
dodir /bin
# Move critical binaries into /bin (required by FHS)
local fhs="cat chgrp chmod chown cp date dd df echo false ln ls
mkdir mknod mv pwd rm rmdir stty sync true uname"
mv ${fhs} ../../bin/ || die "Could not move FHS bins!"
if use hostname ; then
mv hostname ../../bin/ || die
fi
if use kill ; then
mv kill ../../bin/ || die
fi
# Move critical binaries into /bin (common scripts)
# (Why are these required for booting?)
local com="basename chroot cut dir dirname du env expr head mkfifo
mktemp readlink seq sleep sort tail touch tr tty vdir wc yes"
mv ${com} ../../bin/ || die "Could not move common bins!"
# Create a symlink for uname in /usr/bin/ since autotools require it.
# (Other than uname, we need to figure out why we are
# creating symlinks for these in /usr/bin instead of leaving
# the files there in the first place...)
local x
for x in ${com} uname ; do
dosym ../../bin/${x} /usr/bin/${x}
done
fi
}
pkg_postinst() {
ewarn "Make sure you run 'hash -r' in your active shells."
ewarn "You should also re-source your shell settings for LS_COLORS"
ewarn " changes, such as: source /etc/profile"
}

View File

@ -1,34 +1,58 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
PYTHON_COMPAT=( python3_{8..10} )
# Try to keep an eye on Fedora's packaging: https://src.fedoraproject.org/rpms/coreutils
# The upstream coreutils maintianers also maintain the package in Fedora and may
# backport fixes which we want to pick up.
inherit flag-o-matic python-any-r1 toolchain-funcs
PYTHON_COMPAT=( python3_{9..11} )
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/coreutils.asc
inherit flag-o-matic python-any-r1 toolchain-funcs verify-sig
PATCH="${PN}-8.30-patches-01"
MY_PATCH="${PN}-9.0_p20220409-patches-01"
DESCRIPTION="Standard GNU utilities (chmod, cp, dd, ls, sort, tr, head, wc, who,...)"
HOMEPAGE="https://www.gnu.org/software/coreutils/"
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz
!vanilla? (
mirror://gentoo/${PATCH}.tar.xz
https://dev.gentoo.org/~polynomial-c/dist/${PATCH}.tar.xz
)"
LICENSE="GPL-3"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.savannah.gnu.org/git/coreutils.git"
inherit git-r3
elif [[ ${PV} == *_p* ]] ; then
# Note: could put this in devspace, but if it's gone, we don't want
# it in tree anyway. It's just for testing.
MY_SNAPSHOT="$(ver_cut 1-2).18-ffd62"
SRC_URI="https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz -> ${P}.tar.xz"
SRC_URI+=" verify-sig? ( https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz.sig -> ${P}.tar.xz.sig )"
S="${WORKDIR}"/${PN}-${MY_SNAPSHOT}
else
SRC_URI="
mirror://gnu/${PN}/${P}.tar.xz
verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )
"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x86-linux"
fi
SRC_URI+=" !vanilla? ( https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${MY_PATCH}.tar.xz )"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x86-linux"
IUSE="acl caps gmp hostname kill multicall nls selinux +split-usr static test vanilla xattr"
IUSE="acl caps gmp hostname kill multicall nls +openssl selinux +split-usr static test vanilla xattr"
RESTRICT="!test? ( test )"
LIB_DEPEND="acl? ( sys-apps/acl[static-libs] )
LIB_DEPEND="
acl? ( sys-apps/acl[static-libs] )
caps? ( sys-libs/libcap )
gmp? ( dev-libs/gmp:=[static-libs] )
xattr? ( sys-apps/attr[static-libs] )"
RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs]} )
openssl? ( dev-libs/openssl:=[static-libs] )
xattr? ( sys-apps/attr[static-libs] )
"
RDEPEND="
!static? ( ${LIB_DEPEND//\[static-libs]} )
selinux? ( sys-libs/libselinux )
nls? ( virtual/libintl )"
nls? ( virtual/libintl )
"
DEPEND="
${RDEPEND}
static? ( ${LIB_DEPEND} )
@ -42,6 +66,7 @@ BDEPEND="
dev-util/strace
${PYTHON_DEPS}
)
verify-sig? ( sec-keys/openpgp-keys-coreutils )
"
RDEPEND+="
hostname? ( !sys-apps/net-tools[hostname] )
@ -58,59 +83,35 @@ RDEPEND+="
!<app-forensics/tct-1.18-r1
!<net-fs/netatalk-2.0.3-r4"
pkg_pretend() {
if has_version "<sys-fs/zfs-9999" ; then
einfo "Checking for running ZFS module version"
local kmodv minver
kmodv="$(grep kmod <(zfs -V 2>/dev/null))"
# Convert zfs-kmod-2.1.1-r3-gentoo -> 2.1.1-r3
kmodv="${kmodv//zfs-kmod-}"
kmodv="${kmodv%%-gentoo}"
minver="$(ver_cut 2 ${kmodv})"
local diemsg=$(cat <<-EOF
Attempted installation of ${P} on unsupported version of zfs-kmod!
Please reboot to a newer version of zfs-kmod first:
zfs-kmod >=2.0.7 or zfs-kmod >=2.1.1-r3
Using ${P} with running version of zfs-kmod of can
lead to data loss while using cp command on some configurations.
See https://github.com/openzfs/zfs/issues/11900 for details.
EOF
)
case "${minver}" in
# 2.0.x
0)
ver_test "${kmodv}" -lt 2.0.7 && die "${diemsg}"
;;
# 2.1.x
1)
ver_test "${kmodv}" -lt 2.1.1-r3 && die "${diemsg}"
;;
# 0.8.x/9999
*)
# We can't really cover this case realistically
# 9999 is too hard to check and 0.8.x isn't being supported anymore.
;;
esac
fi
}
pkg_setup() {
if use test ; then
python-any-r1_pkg_setup
fi
}
src_unpack() {
if [[ ${PV} == 9999 ]] ; then
git-r3_src_unpack
cd "${S}" || die
./bootstrap || die
sed -i -e "s:submodule-checks ?= no-submodule-changes public-submodule-commit:submodule-checks ?= no-submodule-changes:" gnulib/top/maint.mk || die
elif use verify-sig ; then
# Needed for downloaded patch (which is unsigned, which is fine)
verify-sig_verify_detached "${DISTDIR}"/${P}.tar.xz{,.sig}
fi
default
}
src_prepare() {
local PATCHES=(
# Upstream patches
)
if ! use vanilla ; then
if ! use vanilla && [[ -d "${WORKDIR}"/patch ]] ; then
PATCHES+=( "${WORKDIR}"/patch )
PATCHES+=( "${FILESDIR}"/${PN}-8.32-sandbox-env-test.patch )
fi
default
@ -141,15 +142,19 @@ src_configure() {
# hostname - net-tools
--enable-install-program="arch,$(usev hostname),$(usev kill)"
--enable-no-install-program="groups,$(usev !hostname),$(usev !kill),su,uptime"
--enable-largefile
$(usex caps '' --disable-libcap)
$(use_enable nls)
$(use_enable acl)
$(use_enable multicall single-binary)
$(use_enable xattr)
$(use_with gmp libgmp)
$(use_with openssl)
)
if use gmp ; then
myconf+=( --with-libgmp-prefix="${ESYSROOT}"/usr )
fi
if tc-is-cross-compiler && [[ ${CHOST} == *linux* ]] ; then
# bug #311569
export fu_cv_sys_stat_statfs2_bsize=yes
@ -210,8 +215,8 @@ src_test() {
addwrite /dev/full
#export RUN_EXPENSIVE_TESTS="yes"
#export FETISH_GROUPS="portage wheel"
env PATH="${T}/mount-wrappers:${PATH}" \
emake -j1 -k check
env PATH="${T}/mount-wrappers:${PATH}" gl_public_submodule_commit= \
emake -k check VERBOSE=yes
}
src_install() {

View File

@ -0,0 +1,266 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Try to keep an eye on Fedora's packaging: https://src.fedoraproject.org/rpms/coreutils
# The upstream coreutils maintianers also maintain the package in Fedora and may
# backport fixes which we want to pick up.
PYTHON_COMPAT=( python3_{9..11} )
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/coreutils.asc
inherit flag-o-matic python-any-r1 toolchain-funcs verify-sig
MY_PATCH="${PN}-9.0_p20220409-patches-01"
DESCRIPTION="Standard GNU utilities (chmod, cp, dd, ls, sort, tr, head, wc, who,...)"
HOMEPAGE="https://www.gnu.org/software/coreutils/"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.savannah.gnu.org/git/coreutils.git"
inherit git-r3
elif [[ ${PV} == *_p* ]] ; then
# Note: could put this in devspace, but if it's gone, we don't want
# it in tree anyway. It's just for testing.
MY_SNAPSHOT="$(ver_cut 1-2).198-e68b1"
SRC_URI="https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz -> ${P}.tar.xz"
SRC_URI+=" verify-sig? ( https://www.pixelbeat.org/cu/coreutils-${MY_SNAPSHOT}.tar.xz.sig -> ${P}.tar.xz.sig )"
S="${WORKDIR}"/${PN}-${MY_SNAPSHOT}
else
SRC_URI="
mirror://gnu/${PN}/${P}.tar.xz
verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )
"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x86-linux"
fi
SRC_URI+=" !vanilla? ( https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${MY_PATCH}.tar.xz )"
LICENSE="GPL-3+"
SLOT="0"
IUSE="acl caps gmp hostname kill multicall nls +openssl selinux +split-usr static test vanilla xattr"
RESTRICT="!test? ( test )"
LIB_DEPEND="
acl? ( sys-apps/acl[static-libs] )
caps? ( sys-libs/libcap )
gmp? ( dev-libs/gmp:=[static-libs] )
openssl? ( dev-libs/openssl:=[static-libs] )
xattr? ( sys-apps/attr[static-libs] )
"
RDEPEND="
!static? ( ${LIB_DEPEND//\[static-libs]} )
selinux? ( sys-libs/libselinux )
nls? ( virtual/libintl )
"
DEPEND="
${RDEPEND}
static? ( ${LIB_DEPEND} )
"
BDEPEND="
app-arch/xz-utils
dev-lang/perl
test? (
dev-lang/perl
dev-perl/Expect
dev-util/strace
${PYTHON_DEPS}
)
verify-sig? ( sec-keys/openpgp-keys-coreutils )
"
RDEPEND+="
hostname? ( !sys-apps/net-tools[hostname] )
kill? (
!sys-apps/util-linux[kill]
!sys-process/procps[kill]
)
!app-misc/realpath
!<sys-apps/util-linux-2.13
!<sys-apps/sandbox-2.10-r4
!sys-apps/stat
!net-mail/base64
!sys-apps/mktemp
!<app-forensics/tct-1.18-r1
!<net-fs/netatalk-2.0.3-r4"
pkg_setup() {
if use test ; then
python-any-r1_pkg_setup
fi
}
src_unpack() {
if [[ ${PV} == 9999 ]] ; then
git-r3_src_unpack
cd "${S}" || die
./bootstrap || die
sed -i -e "s:submodule-checks ?= no-submodule-changes public-submodule-commit:submodule-checks ?= no-submodule-changes:" gnulib/top/maint.mk || die
elif use verify-sig ; then
# Needed for downloaded patch (which is unsigned, which is fine)
verify-sig_verify_detached "${DISTDIR}"/${P}.tar.xz{,.sig}
fi
default
}
src_prepare() {
local PATCHES=(
# Upstream patches
)
if ! use vanilla && [[ -d "${WORKDIR}"/patch ]] ; then
PATCHES+=( "${WORKDIR}"/patch )
fi
default
# Since we've patched many .c files, the make process will try to
# re-build the manpages by running `./bin --help`. When doing a
# cross-compile, we can't do that since 'bin' isn't a native bin.
#
# Also, it's not like we changed the usage on any of these things,
# so let's just update the timestamps and skip the help2man step.
set -- man/*.x
touch ${@/%x/1} || die
# Avoid perl dep for compiled in dircolors default (bug #348642)
if ! has_version dev-lang/perl ; then
touch src/dircolors.h || die
touch ${@/%x/1} || die
fi
}
src_configure() {
local myconf=(
--with-packager="Gentoo"
--with-packager-version="${PVR} (p${PATCH_VER:-0})"
--with-packager-bug-reports="https://bugs.gentoo.org/"
# kill/uptime - procps
# groups/su - shadow
# hostname - net-tools
--enable-install-program="arch,$(usev hostname),$(usev kill)"
--enable-no-install-program="groups,$(usev !hostname),$(usev !kill),su,uptime"
$(usex caps '' --disable-libcap)
$(use_enable nls)
$(use_enable acl)
$(use_enable multicall single-binary)
$(use_enable xattr)
$(use_with gmp libgmp)
$(use_with openssl)
)
if use gmp ; then
myconf+=( --with-libgmp-prefix="${ESYSROOT}"/usr )
fi
if tc-is-cross-compiler && [[ ${CHOST} == *linux* ]] ; then
# bug #311569
export fu_cv_sys_stat_statfs2_bsize=yes
# bug #416629
export gl_cv_func_realpath_works=yes
fi
# bug #409919
export gl_cv_func_mknod_works=yes
if use static ; then
append-ldflags -static
# bug #321821
sed -i '/elf_sys=yes/s:yes:no:' configure || die
fi
if ! use selinux ; then
# bug #301782
export ac_cv_{header_selinux_{context,flash,selinux}_h,search_setfilecon}=no
fi
econf "${myconf[@]}"
}
src_test() {
# Known to fail with FEATURES=usersandbox (bug #439574):
# - tests/du/long-from-unreadable.sh} (bug #413621)
# - tests/rm/deep-2.sh (bug #413621)
# - tests/dd/no-allocate.sh (bug #629660)
if has usersandbox ${FEATURES} ; then
ewarn "You are emerging ${P} with 'usersandbox' enabled." \
"Expect some test failures or emerge with 'FEATURES=-usersandbox'!"
fi
# Non-root tests will fail if the full path isn't
# accessible to non-root users
chmod -R go-w "${WORKDIR}" || die
chmod a+rx "${WORKDIR}" || die
# coreutils tests like to do `mount` and such with temp dirs,
# so make sure:
# - /etc/mtab is writable (bug #265725)
# - /dev/loop* can be mounted (bug #269758)
mkdir -p "${T}"/mount-wrappers || die
mkwrap() {
local w ww
for w in "${@}" ; do
ww="${T}/mount-wrappers/${w}"
cat <<-EOF > "${ww}"
#!${EPREFIX}/bin/sh
exec env SANDBOX_WRITE="\${SANDBOX_WRITE}:/etc/mtab:/dev/loop" $(type -P ${w}) "\$@"
EOF
chmod a+rx "${ww}" || die
done
}
mkwrap mount umount
addwrite /dev/full
#export RUN_EXPENSIVE_TESTS="yes"
#export FETISH_GROUPS="portage wheel"
env PATH="${T}/mount-wrappers:${PATH}" gl_public_submodule_commit= \
emake -k check VERBOSE=yes
}
src_install() {
default
insinto /etc
newins src/dircolors.hin DIR_COLORS
if use split-usr ; then
cd "${ED}"/usr/bin || die
dodir /bin
# Move critical binaries into /bin (required by FHS)
local fhs="cat chgrp chmod chown cp date dd df echo false ln ls
mkdir mknod mv pwd rm rmdir stty sync true uname"
mv ${fhs} ../../bin/ || die "Could not move FHS bins!"
if use hostname ; then
mv hostname ../../bin/ || die
fi
if use kill ; then
mv kill ../../bin/ || die
fi
# Move critical binaries into /bin (common scripts)
# (Why are these required for booting?)
local com="basename chroot cut dir dirname du env expr head mkfifo
mktemp readlink seq sleep sort tail touch tr tty vdir wc yes"
mv ${com} ../../bin/ || die "Could not move common bins!"
# Create a symlink for uname in /usr/bin/ since autotools require it.
# (Other than uname, we need to figure out why we are
# creating symlinks for these in /usr/bin instead of leaving
# the files there in the first place...)
local x
for x in ${com} uname ; do
dosym ../../bin/${x} /usr/bin/${x}
done
fi
}
pkg_postinst() {
ewarn "Make sure you run 'hash -r' in your active shells."
ewarn "You should also re-source your shell settings for LS_COLORS"
ewarn " changes, such as: source /etc/profile"
}

View File

@ -1,35 +0,0 @@
https://git.savannah.gnu.org/cgit/coreutils.git/patch/?id=e8b56ebd536e82b15542a00c888109471936bfda
https://lists.gnu.org/archive/html/bug-coreutils/2021-09/msg00031.html
(and https://lists.gnu.org/archive/html/bug-coreutils/2021-09/msg00035.html)
From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P@draigBrady.com>
Date: Fri, 24 Sep 2021 20:57:41 +0100
Subject: chmod: fix exit status when ignoring symlinks
* src/chmod.c: Reorder enum so CH_NOT_APPLIED
can be treated as a non error.
* tests/chmod/ignore-symlink.sh: A new test.
* tests/local.mk: Reference the new test.
* NEWS: Mention the bug fix.
Fixes https://bugs.gnu.org/50784
--- a/src/chmod.c
+++ b/src/chmod.c
@@ -44,8 +44,8 @@ struct change_status
enum
{
CH_NO_STAT,
- CH_NOT_APPLIED,
CH_FAILED,
+ CH_NOT_APPLIED,
CH_NO_CHANGE_REQUESTED,
CH_SUCCEEDED
}
@@ -322,7 +322,7 @@ process_file (FTS *fts, FTSENT *ent)
if ( ! recurse)
fts_set (fts, ent, FTS_SKIP);
- return CH_NO_CHANGE_REQUESTED <= ch.status;
+ return CH_NOT_APPLIED <= ch.status;
}
/* Recursively change the modes of the specified FILES (the last entry

View File

@ -0,0 +1,38 @@
https://src.fedoraproject.org/rpms/coreutils/raw/f672fec4364e71c6e5a30d4026d6bdb7cf332eed/f/gnulib-simple-backup-fix.patch
https://bugs.gnu.org/55029
commit 7347caeb9d902d3fca2c11f69a55a3e578d93bfe
Author: Paul Eggert <eggert@cs.ucla.edu>
Date: Wed Apr 20 19:34:57 2022 -0700
backupfile: fix bug when renaming simple backups
* lib/backupfile.c (backupfile_internal): Fix bug when RENAME
and when doing simple backups. Problem reported by Steve Ward in:
https://bugs.gnu.org/55029
--- a/lib/backupfile.c
+++ b/lib/backupfile.c
@@ -332,7 +332,7 @@ backupfile_internal (int dir_fd, char const *file,
return s;
DIR *dirp = NULL;
- int sdir = AT_FDCWD;
+ int sdir = dir_fd;
idx_t base_max = 0;
while (true)
{
@@ -371,10 +371,9 @@ backupfile_internal (int dir_fd, char const *file,
if (! rename)
break;
- int olddirfd = sdir < 0 ? dir_fd : sdir;
- idx_t offset = sdir < 0 ? 0 : base_offset;
+ idx_t offset = backup_type == simple_backups ? 0 : base_offset;
unsigned flags = backup_type == simple_backups ? 0 : RENAME_NOREPLACE;
- if (renameatu (olddirfd, file + offset, sdir, s + offset, flags) == 0)
+ if (renameatu (sdir, file + offset, sdir, s + offset, flags) == 0)
break;
int e = errno;
if (! (e == EEXIST && extended))

View File

@ -0,0 +1,59 @@
https://www.reddit.com/r/archlinux/comments/11zdecf/sha256sum_c_prints_ok_for_a_failed_checksum_when/
https://bugs.archlinux.org/task/77969
https://bugs.gnu.org/62403
https://github.com/coreutils/coreutils/commit/76f2fb627118a26c25003dbd98c22c153b7ee1d2
From 76f2fb627118a26c25003dbd98c22c153b7ee1d2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P@draigBrady.com>
Date: Thu, 23 Mar 2023 12:31:24 +0000
Subject: [PATCH] cksum: fix reporting of failed checks
This applies to all checksumming utilities,
where we incorrectly report all subsequent files as checking 'OK'
once any file has passed a digest check.
The exit status was not impacted, only the printed status.
* src/digest.c (digest_check): Use the correct state variable
to determine if the _current_ file has passed or not.
* tests/misc/md5sum.pl: Add a test case.
Fixes https://bugs.gnu.org/62403
--- a/src/digest.c
+++ b/src/digest.c
@@ -1254,14 +1254,14 @@ digest_check (char const *checkfile_name)
if (!status_only)
{
- if ( ! matched_checksums || ! quiet)
+ if (! match || ! quiet)
{
if (needs_escape)
putchar ('\\');
print_filename (filename, needs_escape);
}
- if ( ! matched_checksums)
+ if (! match)
printf (": %s\n", _("FAILED"));
else if (!quiet)
printf (": %s\n", _("OK"));
--- a/tests/misc/md5sum.pl
+++ b/tests/misc/md5sum.pl
@@ -101,6 +101,16 @@
. "md5sum: WARNING: 1 line is improperly formatted\n"
. "md5sum: WARNING: 2 computed checksums did NOT match\n"},
{EXIT=> 1}],
+ # Ensure we use appropriate state to track failures (broken in 9.2)
+ ['check-multifail-state', '--check', '--warn',
+ {IN=>{'f.md5' =>
+ "$degenerate f\n"
+ . "$degenerate g\n"
+ . "$degenerate f\n" }},
+ {AUX=> {f=> ''}}, {AUX=> {g=> 'a'}},
+ {OUT=>"f: OK\ng: FAILED\nf: OK\n"},
+ {ERR=>"md5sum: WARNING: 1 computed checksum did NOT match\n"},
+ {EXIT=> 1}],
# The sha1sum and md5sum drivers share a lot of code.
# Ensure that md5sum does *not* share the part that makes
# sha1sum accept BSD format.

View File

@ -0,0 +1,130 @@
https://git.savannah.gnu.org/cgit/coreutils.git/commit/?id=093a8b4bfaba60005f14493ce7ef11ed665a0176
From 093a8b4bfaba60005f14493ce7ef11ed665a0176 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P@draigBrady.com>
Date: Thu, 23 Mar 2023 13:19:04 +0000
Subject: copy: fix --reflink=auto to fallback in more cases
On restricted systems like android or some containers,
FICLONE could return EPERM, EACCES, or ENOTTY,
which would have induced the command to fail to copy
rather than falling back to a more standard copy.
* src/copy.c (is_terminal_failure): A new function refactored
from handle_clone_fail().
(is_CLONENOTSUP): Merge in the handling of EACCES, ENOTTY, EPERM
as they also pertain to determination of whether cloning is supported
if we ever use this function in that context.
(handle_clone_fail): Use is_terminal_failure() in all cases,
so that we assume a terminal failure in less errno cases.
* NEWS: Mention the bug fix.
Addresses https://bugs.gnu.org/62404
--- a/src/copy.c
+++ b/src/copy.c
@@ -278,15 +278,27 @@ create_hole (int fd, char const *name, bool punch_holes, off_t size)
}
-/* Whether the errno from FICLONE, or copy_file_range
- indicates operation is not supported for this file or file system. */
+/* Whether the errno indicates the operation is a transient failure.
+ I.e., a failure that would indicate the operation _is_ supported,
+ but has failed in a terminal way. */
+
+static bool
+is_terminal_error (int err)
+{
+ return err == EIO || err == ENOMEM || err == ENOSPC || err == EDQUOT;
+}
+
+
+/* Whether the errno from FICLONE, or copy_file_range indicates
+ the operation is not supported/allowed for this file or process. */
static bool
is_CLONENOTSUP (int err)
{
- return err == ENOSYS || is_ENOTSUP (err)
+ return err == ENOSYS || err == ENOTTY || is_ENOTSUP (err)
|| err == EINVAL || err == EBADF
- || err == EXDEV || err == ETXTBSY;
+ || err == EXDEV || err == ETXTBSY
+ || err == EPERM || err == EACCES;
}
@@ -339,20 +351,18 @@ sparse_copy (int src_fd, int dest_fd, char **abuf, size_t buf_size,
{
copy_debug.offload = COPY_DEBUG_UNSUPPORTED;
- if (is_CLONENOTSUP (errno))
- break;
-
- /* copy_file_range might not be enabled in seccomp filters,
- so retry with a standard copy. EPERM can also occur
- for immutable files, but that would only be in the edge case
- where the file is made immutable after creating/truncating,
+ /* Consider operation unsupported only if no data copied.
+ For example, EPERM could occur if copy_file_range not enabled
+ in seccomp filters, so retry with a standard copy. EPERM can
+ also occur for immutable files, but that would only be in the
+ edge case where the file is made immutable after creating,
in which case the (more accurate) error is still shown. */
- if (errno == EPERM && *total_n_read == 0)
+ if (*total_n_read == 0 && is_CLONENOTSUP (errno))
break;
/* ENOENT was seen sometimes across CIFS shares, resulting in
no data being copied, but subsequent standard copies succeed. */
- if (errno == ENOENT && *total_n_read == 0)
+ if (*total_n_read == 0 && errno == ENOENT)
break;
if (errno == EINTR)
@@ -1172,17 +1182,15 @@ handle_clone_fail (int dst_dirfd, char const* dst_relname,
char const* src_name, char const* dst_name,
int dest_desc, bool new_dst, enum Reflink_type reflink_mode)
{
- /* If the clone operation is creating the destination,
- then don't try and cater for all non transient file system errors,
- and instead only cater for specific transient errors. */
- bool transient_failure;
- if (dest_desc < 0) /* currently for fclonefileat(). */
- transient_failure = errno == EIO || errno == ENOMEM
- || errno == ENOSPC || errno == EDQUOT;
- else /* currently for FICLONE. */
- transient_failure = ! is_CLONENOTSUP (errno);
-
- if (reflink_mode == REFLINK_ALWAYS || transient_failure)
+ /* When the clone operation fails, report failure only with errno values
+ known to mean trouble when the clone is supported and called properly.
+ Do not report failure merely because !is_CLONENOTSUP (errno),
+ as systems may yield oddball errno values here with FICLONE.
+ Also is_CLONENOTSUP() is not appropriate for the range of errnos
+ possible from fclonefileat(), so it's more consistent to avoid. */
+ bool report_failure = is_terminal_error (errno);
+
+ if (reflink_mode == REFLINK_ALWAYS || report_failure)
error (0, errno, _("failed to clone %s from %s"),
quoteaf_n (0, dst_name), quoteaf_n (1, src_name));
@@ -1190,14 +1198,14 @@ handle_clone_fail (int dst_dirfd, char const* dst_relname,
but cloned no data. */
if (new_dst /* currently not for fclonefileat(). */
&& reflink_mode == REFLINK_ALWAYS
- && ((! transient_failure) || lseek (dest_desc, 0, SEEK_END) == 0)
+ && ((! report_failure) || lseek (dest_desc, 0, SEEK_END) == 0)
&& unlinkat (dst_dirfd, dst_relname, 0) != 0 && errno != ENOENT)
error (0, errno, _("cannot remove %s"), quoteaf (dst_name));
- if (! transient_failure)
+ if (! report_failure)
copy_debug.reflink = COPY_DEBUG_UNSUPPORTED;
- if (reflink_mode == REFLINK_ALWAYS || transient_failure)
+ if (reflink_mode == REFLINK_ALWAYS || report_failure)
return false;
return true;
--
cgit v1.1

View File

@ -12,6 +12,7 @@
<flag name="hostname">Build the hostname program</flag>
<flag name="kill">Build the kill program</flag>
<flag name="multicall">Build all tools into a single `coreutils` program akin to busybox to save space</flag>
<flag name="openssl">Use openssl libcrypto hash routines for hash functions</flag>
<flag name="split-usr">Enable this if /bin and /usr/bin are separate directories</flag>
</use>
<upstream>

View File

@ -1,3 +1 @@
DIST debianutils_4.11.2.tar.xz 158132 BLAKE2B c2a95c90b4267e3b1d61c21db562f960b4666982c488e69a757fb0a7a42e8e739d44f553edd8cf532df30c492e999920ab63ec3580479de7de5d901d75de76fc SHA512 0bd9098beee78b3c8dae839f0c29e9f142cbb22f2ced473cf7ae47a14d9493ba882c1829eba213780392a87a3223b3689729754c8ded80a091efaef3f6f903fd
DIST debianutils_5.4.orig.tar.xz 103640 BLAKE2B ac59ffcf7ef9523a67127e5565cb87eb694a0297eb81acba53a5ca00a2f16d024e21ba1ef6eff5079194c2cc751712fe9ad5814603deeeaa05d28343ff79a409 SHA512 a5501bdc46e203bd0cf357e5c83bb556ea7294ee603498399427dd49536848e006b21967f6239c3d808c8b9653d65f28536cf388dd18b749e54a235cc9326850
DIST debianutils_5.5.orig.tar.xz 104448 BLAKE2B 707c9072ddf1fa0c61fc66f84aea26bac7bf6f31948880ad4711e89f8f4a665ae4104e998f27e53e288b3453a71876ef44038f8e954f19055ed1049eb9b9981c SHA512 230310428ee7c145c74bb666ae729754352295230f38ef4e22f7566970c5186d607cd827a5603a678815bd48d4a1eb2716f55c32494ec75eb665651da6a56e6a
DIST debianutils_5.7.orig.tar.gz 257231 BLAKE2B 61d2e7abcd359c5dc87b7f91e510e91e1926183c15a572c7d87cf4a590dded2e2ee8c9b4e06f7f478353139870c808927575de233200ad69e084a6f971c4bd24 SHA512 79acd8885abca93842d696167171a359011c49a40f38deeb25bc94d62905f95afa3a7b2540d3bd4b0ffd363c5c48a439a1a68139a29d6c033980b019cea75d92

View File

@ -0,0 +1,51 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit autotools flag-o-matic
DESCRIPTION="A selection of tools from Debian"
HOMEPAGE="https://packages.qa.debian.org/d/debianutils.html"
SRC_URI="mirror://debian/pool/main/d/${PN}/${PN}_${PV}.orig.tar.gz"
LICENSE="BSD GPL-2 SMAIL"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x86-linux"
IUSE="+installkernel static"
PDEPEND="
installkernel? (
|| (
sys-kernel/installkernel-gentoo
sys-kernel/installkernel-systemd-boot
)
)"
PATCHES=( "${FILESDIR}"/${PN}-3.4.2-no-bs-namespace.patch )
src_prepare() {
# Avoid adding po4a dependency, upstream refreshes manpages.
sed -i -e '/SUBDIRS/s|po4a||' Makefile.am || die
default
eautoreconf
}
src_configure() {
use static && append-ldflags -static
default
}
src_install() {
into /
dobin run-parts
into /usr
dobin ischroot
dosbin savelog
doman ischroot.1 run-parts.8 savelog.8
dodoc CHANGELOG
}

View File

@ -1,3 +1,4 @@
DIST ethtool-5.10.tar.xz 310536 BLAKE2B acc91ff2f7cf233a5a7bc85e32fbcf78e3923b240ab3e3300fa11d42769b664b1b5740ad6577daf4ef1b1054432e2323429ee63774af5e0210c1ec1c7d6aa4ac SHA512 128ecc0445ec44e231d95158a71cea2c03f059314f1a844cfb2f424970bd68608fb73b8dc5e8905b88ad0da2b65a8884a626be78d6d25f770ce043c6c87580a6
DIST ethtool-5.13.tar.xz 318204 BLAKE2B 5e693368ce56fa155c5d371bc650e5fb7e8e1c8fd30982b45a674da63119e54f005484bea68c7b85e8d070efbf7aa15e92637e7a3b8b2010b4022851154a6809 SHA512 44426653aabd20707d2e597707113f4d30d12696b4f32c0ab0450af0dccece1b6a11e529a22d1299204f63c9e71ae41a1495d3d36b8f630f1734a72694d779be
DIST ethtool-5.14.tar.xz 318536 BLAKE2B 09b5c9c8103635e33b22e55caff3b0f3751bf14d48de63e025587814c6b0d7e80962cd8ed27b6be7ae35a5a9d5decd0a9127a69a7cbbd52e2218bb3fc9e9b176 SHA512 880c4b6d5f83c25cabc6101222a5abf5f7e5e6501165ba5cdb420da242c351d7c32c1cffacfa1bcf0c4655434d89c64d39f0809af0d38f626a0a78f92ec68f87
DIST ethtool-5.15.tar.xz 318864 BLAKE2B 855c07e388bfabf37637f20e2714c6ca27717f38d7f658be96e0e9ec9d4514e61f4ee29361fc0279510869606ad18126ccd2a47160f1097ab52b1e35216e9721 SHA512 28147468a92c179217b459907a3257ee4f2d2ed028cb87b074f1c7ca6eb91aca81c8a9f5c7fe74e81d16a516e6e7eb20137bf7a15b5479fd82a327c64954da12
DIST ethtool-5.19.tar.xz 324472 BLAKE2B 44cc292db04f411a57a0a5ae0cdfbef733c7ee739fc252523c713489a13ae33de3927b500db796bc584fef3c83d7238dca2af4e6b6a5c594bbf21e87ed2380a7 SHA512 71103c6856a889161ef2bf81eadec69b2f3a84c94aa776d545f889dc1c55b91d566d3b7394dbd2cb70ed92ac19d5f26967b1f829c204f23831d1fb81a0464972
DIST ethtool-6.1.tar.xz 327644 BLAKE2B 002a4edffda42520d77e8f0c27adf909090823f1a08689b67fc7c75de3048bdc9c94d7d32973bd17562d7dbf295479e796c2529b5db66b5fce42a2ede5851cd6 SHA512 6ca478ec75dae7cc347b859802e1965e6c78310ec4b276dec29bdf76d3464e4186c6e5ed0cb8f013171d6c0562c1156cb0442419f5b947c314e8b91ad9fd2d93
DIST ethtool-6.2.tar.xz 332708 BLAKE2B b3fa2571b1efef3b686eb4f20b33e6cc32bdb8cff5f2e642454ca3d41c427b1953df7b07e5ac8ef149f8b4be614210e05e593233655e5fe317c48630b20b68e8 SHA512 ff1f14c7876163bef93ca48e22a3429f09b4bcb3e1d101ef297d9f226e3fc2d3c3f19faf5b85f54cb558479e4a408ef5356a2d12e7ba132cc4cadaf92effccaf

View File

@ -0,0 +1,21 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
DESCRIPTION="Utility for examining and tuning ethernet-based network interfaces"
HOMEPAGE="https://www.kernel.org/pub/software/network/ethtool/"
SRC_URI="https://www.kernel.org/pub/software/network/ethtool/${P}.tar.xz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~mips ppc ppc64 ~riscv sparc x86"
IUSE="+netlink"
BDEPEND="app-arch/xz-utils"
RDEPEND="netlink? ( net-libs/libmnl )"
DEPEND="${RDEPEND}"
src_configure() {
econf $(use_enable netlink)
}

View File

@ -0,0 +1,21 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Utility for examining and tuning ethernet-based network interfaces"
HOMEPAGE="https://www.kernel.org/pub/software/network/ethtool/"
SRC_URI="https://www.kernel.org/pub/software/network/ethtool/${P}.tar.xz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
IUSE="+netlink"
RDEPEND="netlink? ( net-libs/libmnl )"
DEPEND="${RDEPEND}"
BDEPEND="app-arch/xz-utils"
src_configure() {
econf $(use_enable netlink)
}

View File

@ -0,0 +1,25 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Utility for examining and tuning ethernet-based network interfaces"
HOMEPAGE="https://www.kernel.org/pub/software/network/ethtool/"
SRC_URI="https://www.kernel.org/pub/software/network/ethtool/${P}.tar.xz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv sparc x86"
IUSE="+netlink"
RDEPEND="netlink? ( net-libs/libmnl )"
DEPEND="${RDEPEND}"
BDEPEND="app-arch/xz-utils"
PATCHES=(
"${FILESDIR}"/${P}-musl.patch
)
src_configure() {
econf $(use_enable netlink)
}

View File

@ -0,0 +1,21 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DESCRIPTION="Utility for examining and tuning ethernet-based network interfaces"
HOMEPAGE="https://www.kernel.org/pub/software/network/ethtool/"
SRC_URI="https://www.kernel.org/pub/software/network/ethtool/${P}.tar.xz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv sparc x86"
IUSE="+netlink"
RDEPEND="netlink? ( net-libs/libmnl )"
DEPEND="${RDEPEND}"
BDEPEND="app-arch/xz-utils"
src_configure() {
econf $(use_enable netlink)
}

View File

@ -0,0 +1,64 @@
https://bugs.gentoo.org/889402
https://git.kernel.org/pub/scm/network/ethtool/ethtool.git/commit/?id=41be533331fc3c6b711dbe532405782d3b8be5d1
From 41be533331fc3c6b711dbe532405782d3b8be5d1 Mon Sep 17 00:00:00 2001
From: Florian Fainelli <f.fainelli@gmail.com>
Date: Sat, 14 Jan 2023 08:34:11 -0800
Subject: marvell.c: Fix build with musl-libc
After commit 1fa60003a8b8 ("misc: header includes cleanup") we stopped
including net/if.h which resolved the proper defines to pull in
sys/types.h and provide a definition for u_int32_t. With musl-libc we
would need to define _GNU_SOURCE to ensure that sys/types.h does provide a
definition for u_int32_t.
Rather, just replace u_uint{16,32}_t with the more standard
uint{16,32}_t types from stdint.h
Fixes: 1fa60003a8b8 ("misc: header includes cleanup")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
--- a/marvell.c
+++ b/marvell.c
@@ -31,23 +31,23 @@ static void dump_timer(const char *name, const void *p)
static void dump_queue(const char *name, const void *a, int rx)
{
struct desc {
- u_int32_t ctl;
- u_int32_t next;
- u_int32_t data_lo;
- u_int32_t data_hi;
- u_int32_t status;
- u_int32_t timestamp;
- u_int16_t csum2;
- u_int16_t csum1;
- u_int16_t csum2_start;
- u_int16_t csum1_start;
- u_int32_t addr_lo;
- u_int32_t addr_hi;
- u_int32_t count_lo;
- u_int32_t count_hi;
- u_int32_t byte_count;
- u_int32_t csr;
- u_int32_t flag;
+ uint32_t ctl;
+ uint32_t next;
+ uint32_t data_lo;
+ uint32_t data_hi;
+ uint32_t status;
+ uint32_t timestamp;
+ uint16_t csum2;
+ uint16_t csum1;
+ uint16_t csum2_start;
+ uint16_t csum1_start;
+ uint32_t addr_lo;
+ uint32_t addr_hi;
+ uint32_t count_lo;
+ uint32_t count_hi;
+ uint32_t byte_count;
+ uint32_t csr;
+ uint32_t flag;
};
const struct desc *d = a;
--
cgit

View File

@ -1 +1,10 @@
DIST grep-3.10.19-2ea9.tar.xz 1702712 BLAKE2B 93b6d07703039d6ace2a989498eb760d58bb57e01658d371ac4d010af7c6831f3e2908d38c8deaa300ff0d30b69449e975f08863a327acd71f18c5a0cf01b16b SHA512 4048b151a8c9004fc5d4a21f5b40cb5703945ba5635fcf262f847ba95dfa5022c1dae51b8efcb7ab288910623761d3daaa6f2c9352f2db667f288c86e8ee8791
DIST grep-3.10.19-2ea9.tar.xz.sig 833 BLAKE2B 867c954910e160e271e048aa0476ab552640a8c52b3e018d0482734f79cb3ae20dc5259077fe09e0bb93284c88b8fbfdea19756d966c5df230bfe5df9f6a77f8 SHA512 e37ce1fcd36aafcf9e89c7603ce23b7cde207fc6ab5291140048091dea47c47505a282b4b2c666472ddfcc1fc0212112311f2ab88cff592ed4db31e51db67d83
DIST grep-3.10.tar.xz 1687464 BLAKE2B 5ff169a4ed39e8af1e6729fd2e1bafd39036a4f56cf831f990d58bf9e76bc7d8b055254ae7f60509be4e8bf2f3737edb15431a8ecfc7fc058578d2abea3d73b9 SHA512 865e8f3fd7afc68f1a52f5e1e1ee05fb9c6d6182201efb0dbdf6075347b0b1d2bf0784537a8f8dd4fb050d523f7a1d2fb5b9c3e3245087d0e6cc12d6e9d3961b
DIST grep-3.10.tar.xz.sig 833 BLAKE2B 0b13c8c8955b4e38889cf79b426618e006b05bc3b224e0705b2cb592b1520a7fc751d5cc386371707a53c8b6888c4e1f9dd31c3ea2ef5cbf4c97ddef3ba7d037 SHA512 02224ff2d6b3a9a50d0e15f7a9b3c264aa717602d133ac32b36a7315bf29ec3b94ef7ec31ee979b199264d10003dc502e20f9bf932bb32b4abe4426ea564d4be
DIST grep-3.7.tar.xz 1641196 BLAKE2B acf03b1fe8065dac48d686de070bab9ecddae65c97f3b0e2be484e8abdd06d1fbdbb396f3d73dadadf9618aad2f02cf6416094bad64d5f2f15eab6b6b3adfeda SHA512 e9e45dcd40af8367f819f2b93c5e1b4e98a251a9aa251841fa67a875380fae52cfa27c68c6dbdd6a4dde1b1017ee0f6b9833ef6dd6e419d32d71b6df5e972b82
DIST grep-3.7.tar.xz.sig 833 BLAKE2B 02a2850e22e8054dcfd02b6f08747a97d43dae9adb908516bdaed35750aa7f773832ad1b0b4c53d7b0ebc8f1fe2979e7938bbbeeb09ea00c11b4a0d5846c7b9c SHA512 9db28883b696fbbb0fad32f4ecd168954dc475d5f0a8f2b4f960ff615ef7dd8348a7caaee85a96287824472a29485ff921af121c582083ca5ad5c30960f99cf4
DIST grep-3.8.tar.xz 1709536 BLAKE2B 24cf6f7aa35c85f59f508969ee9731c5be1e5c613e64e636f464bbdde917bb99ba739e4b82abf08da127ad0400d62e27d139f85142035745121d381982ec6c36 SHA512 2014519a80c6dcd799837e1bd7d9d5ebe8729ec54b0dc76981dac4755a9a8a9f200470cdcc911e2825bed8162e61da39e3dd60289f7393b48bf67314077d0c79
DIST grep-3.8.tar.xz.sig 833 BLAKE2B 40f472389705375611015ba0eb85eb32643304b1a324877a75821d086a128a20d00df3d7cd960ec45709f40f21488bbcf993c6fe667ef23663688b33296e650b SHA512 8266b58485f225c2189814e3898c72e59d251b729e0c302d31f57abdb7ac2e6e28dde2c5c8095673b6f007b2a3ebc26db1dca910a7771aba80dad4b3c6761ee4
DIST grep-3.9.tar.xz 1680380 BLAKE2B 33fefce2a831ad6f00f2eb1d8a063cf280635f2d9c481c98981f7a2ff143c846ab570a448c9c02c3ba08cf2c98612cb364d2d033baf92d62c4515315453cc6f9 SHA512 38aaa28bded9f6d1d527356e9e63bb1dafb4ec8f09e83f2d3bc86c1d6af1a5a8cb9895067375b5b8929ec2cba6ab71c369ed4c6e2a0f7a01dec3c11a6f4c1836
DIST grep-3.9.tar.xz.sig 833 BLAKE2B bbb8a07986368755276c6648378afdbec44da2873574ebb0dce634b0e90da2cb6fd0eaf64969843e2fe65ae5e83aba6b1fea9fde9b246fbedf982393cf54b715 SHA512 d50e11d0d333c09a6afcae511c93cfb54d9dd0a6600f271abf5e103cbf8bdcf9b8606924d7c71770e20c35df5d5468dc339cea1f05d257776734e17f8378d891

View File

@ -0,0 +1,30 @@
[xen0n: this is https://github.com/sunhaiyong1978/CLFS-for-LoongArch/blob/1.0/patches/stack-direction-add-loongarch.patch with change to generated file added as well.]
From: Sun Haiyong <youbest@sina.com>
Date: Tue, 31 Aug 2021 11:11:52 +0800
Subject: [PATCH] stack-direction: Add support for loongarch CPU
* m4/stack-direction.m4 (SV_STACK_DIRECTION): When the CPU is loongarch,
set "sv_cv_stack_direction" to "-1" .
--- a/m4/stack-direction.m4
+++ b/m4/stack-direction.m4
@@ -32,6 +32,7 @@ AC_DEFUN([SV_STACK_DIRECTION],
i?86 | x86_64 | \
i860 | \
ia64 | \
+ loongarch* | \
m32r | \
m68* | \
m88k | \
--- a/configure
+++ b/configure
@@ -35668,6 +35668,7 @@ else $as_nop
i?86 | x86_64 | \
i860 | \
ia64 | \
+ loongarch* | \
m32r | \
m68* | \
m88k | \
--
2.17.2

View File

@ -1,7 +1,8 @@
Needed to fix build on ppc + musl. Doesn't seem to yet be in upstream gnulib.
Needed to fix build on ppc + musl. Should pop up in next gnulib sync in release (different patch).
https://www.openwall.com/lists/musl/2017/11/05/2
https://github.com/void-linux/void-packages/blob/master/srcpkgs/grep/patches/ppc-musl.patch
https://git.savannah.gnu.org/cgit/gnulib.git/commit/?id=2d830e4a792fcd9f614ed08a7f18584b8b21d23b
--- a/lib/sigsegv.c
+++ b/lib/sigsegv.c
@@ -221,8 +221,10 @@ int libsigsegv_version = LIBSIGSEGV_VERSION;

View File

@ -0,0 +1,115 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/grep.asc
inherit flag-o-matic verify-sig
DESCRIPTION="GNU regular expression matcher"
HOMEPAGE="https://www.gnu.org/software/grep/"
if [[ ${PV} == *_p* ]] ; then
# Subscribe to the 'platform-testers' ML to find these.
# Useful to test on our especially more niche arches and report issues upstream.
MY_COMMIT="8-026c"
MY_P=${PN}-$(ver_cut 1-2).${MY_COMMIT}
SRC_URI="https://meyering.net/${PN}/${MY_P}.tar.xz"
SRC_URI+=" verify-sig? ( https://meyering.net/${PN}/${MY_P}.tar.xz.sig )"
S="${WORKDIR}"/${MY_P}
else
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-3+"
SLOT="0"
IUSE="+egrep-fgrep nls pcre static"
# We lack dev-libs/libsigsegv[static-libs] for now
REQUIRED_USE="static? ( !sparc )"
LIB_DEPEND="
pcre? ( >=dev-libs/libpcre2-7.8-r1[static-libs(+)] )
sparc? ( dev-libs/libsigsegv )
"
RDEPEND="
!static? ( ${LIB_DEPEND//\[static-libs(+)]} )
nls? ( virtual/libintl )
virtual/libiconv
"
DEPEND="
${RDEPEND}
static? ( ${LIB_DEPEND} )
"
BDEPEND="
virtual/pkgconfig
nls? ( sys-devel/gettext )
verify-sig? ( sec-keys/openpgp-keys-grep )
"
DOCS=( AUTHORS ChangeLog NEWS README THANKS TODO )
QA_CONFIG_IMPL_DECL_SKIP=(
# Either gnulib FPs or fixed in newer autoconf, not worth autoreconf here for now?
MIN
alignof
static_assert
)
src_prepare() {
default
# bug #523898
sed -i \
-e "s:@SHELL@:${EPREFIX}/bin/sh:g" \
-e "s:@grep@:${EPREFIX}/bin/grep:" \
src/egrep.sh || die
}
src_configure() {
use static && append-ldflags -static
# We used to turn this off unconditionally (bug #673524) but we now
# allow it for cases where libsigsegv is better for userspace handling
# of stack overflows.
# In particular, it's necessary for sparc: bug #768135
export ac_cv_libsigsegv=$(usex sparc)
local myeconfargs=(
--bindir="${EPREFIX}"/bin
$(use_enable nls)
$(use_enable pcre perl-regexp)
)
econf "${myeconfargs[@]}"
}
src_install() {
default
if use egrep-fgrep ; then
# Delete the upstream wrapper variants which warn on egrep+fgrep use
rm "${ED}"/bin/{egrep,fgrep} || die
into /
# Install egrep, fgrep which don't warn.
#
# We do this by default to avoid breakage in old scripts
# and such which don't expect unexpected output on stderr,
# we've had examples of builds failing because foo-config
# starts returning a warning.
#
# https://lists.gnu.org/archive/html/bug-grep/2022-10/msg00000.html
newbin - egrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -E "\$@"
EOF
newbin - fgrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -F "\$@"
EOF
fi
}

View File

@ -0,0 +1,115 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/grep.asc
inherit flag-o-matic verify-sig
DESCRIPTION="GNU regular expression matcher"
HOMEPAGE="https://www.gnu.org/software/grep/"
if [[ ${PV} == *_p* ]] ; then
# Subscribe to the 'platform-testers' ML to find these.
# Useful to test on our especially more niche arches and report issues upstream.
MY_COMMIT="19-2ea9"
MY_P=${PN}-$(ver_cut 1-2).${MY_COMMIT}
SRC_URI="https://meyering.net/${PN}/${MY_P}.tar.xz"
SRC_URI+=" verify-sig? ( https://meyering.net/${PN}/${MY_P}.tar.xz.sig )"
S="${WORKDIR}"/${MY_P}
else
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-3+"
SLOT="0"
IUSE="+egrep-fgrep nls pcre static"
# We lack dev-libs/libsigsegv[static-libs] for now
REQUIRED_USE="static? ( !sparc )"
LIB_DEPEND="
pcre? ( >=dev-libs/libpcre2-10.42-r1[static-libs(+)] )
sparc? ( dev-libs/libsigsegv )
"
RDEPEND="
!static? ( ${LIB_DEPEND//\[static-libs(+)]} )
nls? ( virtual/libintl )
virtual/libiconv
"
DEPEND="
${RDEPEND}
static? ( ${LIB_DEPEND} )
"
BDEPEND="
virtual/pkgconfig
nls? ( sys-devel/gettext )
verify-sig? ( sec-keys/openpgp-keys-grep )
"
DOCS=( AUTHORS ChangeLog NEWS README THANKS TODO )
QA_CONFIG_IMPL_DECL_SKIP=(
# Either gnulib FPs or fixed in newer autoconf, not worth autoreconf here for now?
MIN
alignof
static_assert
)
src_prepare() {
default
# bug #523898
sed -i \
-e "s:@SHELL@:${EPREFIX}/bin/sh:g" \
-e "s:@grep@:${EPREFIX}/bin/grep:" \
src/egrep.sh || die
}
src_configure() {
use static && append-ldflags -static
# We used to turn this off unconditionally (bug #673524) but we now
# allow it for cases where libsigsegv is better for userspace handling
# of stack overflows.
# In particular, it's necessary for sparc: bug #768135
export ac_cv_libsigsegv=$(usex sparc)
local myeconfargs=(
--bindir="${EPREFIX}"/bin
$(use_enable nls)
$(use_enable pcre perl-regexp)
)
econf "${myeconfargs[@]}"
}
src_install() {
default
if use egrep-fgrep ; then
# Delete the upstream wrapper variants which warn on egrep+fgrep use
rm "${ED}"/bin/{egrep,fgrep} || die
into /
# Install egrep, fgrep which don't warn.
#
# We do this by default to avoid breakage in old scripts
# and such which don't expect unexpected output on stderr,
# we've had examples of builds failing because foo-config
# starts returning a warning.
#
# https://lists.gnu.org/archive/html/bug-grep/2022-10/msg00000.html
newbin - egrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -E "\$@"
EOF
newbin - fgrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -F "\$@"
EOF
fi
}

View File

@ -1,17 +1,19 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit flag-o-matic toolchain-funcs
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/grep.asc
inherit flag-o-matic toolchain-funcs verify-sig
DESCRIPTION="GNU regular expression matcher"
HOMEPAGE="https://www.gnu.org/software/grep/"
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE="nls pcre static"
# We lack dev-libs/libsigsegv[static-libs] for now
@ -27,9 +29,12 @@ DEPEND="${RDEPEND}
BDEPEND="
virtual/pkgconfig
nls? ( sys-devel/gettext )
"
verify-sig? ( sec-keys/openpgp-keys-grep )"
PATCHES=( "${FILESDIR}/ppc-musl.patch" )
PATCHES=(
"${FILESDIR}/ppc-musl.patch"
"${FILESDIR}/loong-fix-build.patch"
)
DOCS=( AUTHORS ChangeLog NEWS README THANKS TODO )
@ -40,6 +45,12 @@ src_prepare() {
src/egrep.sh || die #523898
default
# touch generated files after patching m4, to avoid activating maintainer
# mode
# remove when loong-fix-build.patch is no longer necessary
touch ./aclocal.m4 ./config.hin ./configure || die
find . -name Makefile.in -exec touch {} + || die
}
src_configure() {

View File

@ -0,0 +1,100 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/grep.asc
inherit flag-o-matic verify-sig
DESCRIPTION="GNU regular expression matcher"
HOMEPAGE="https://www.gnu.org/software/grep/"
if [[ ${PV} == *_p* ]] ; then
# Subscribe to the 'platform-testers' ML to find these.
# Useful to test on our especially more niche arches and report issues upstream.
MY_COMMIT="98-c9ac"
MY_P=${PN}-$(ver_cut 1-2).${MY_COMMIT}
SRC_URI="https://meyering.net/${PN}/${MY_P}.tar.xz"
SRC_URI+=" verify-sig? ( https://meyering.net/${PN}/${MY_P}.tar.xz.sig )"
S="${WORKDIR}"/${MY_P}
else
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~x64-cygwin ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-3+"
SLOT="0"
IUSE="+egrep-fgrep nls pcre static"
# We lack dev-libs/libsigsegv[static-libs] for now
REQUIRED_USE="static? ( !sparc )"
LIB_DEPEND="pcre? ( >=dev-libs/libpcre2-7.8-r1[static-libs(+)] )
sparc? ( dev-libs/libsigsegv )"
RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs(+)]} )
nls? ( virtual/libintl )
virtual/libiconv"
DEPEND="${RDEPEND}
static? ( ${LIB_DEPEND} )"
BDEPEND="virtual/pkgconfig
nls? ( sys-devel/gettext )
verify-sig? ( sec-keys/openpgp-keys-grep )"
DOCS=( AUTHORS ChangeLog NEWS README THANKS TODO )
src_prepare() {
default
# bug #523898
sed -i \
-e "s:@SHELL@:${EPREFIX}/bin/sh:g" \
-e "s:@grep@:${EPREFIX}/bin/grep:" \
src/egrep.sh || die
}
src_configure() {
use static && append-ldflags -static
# We used to turn this off unconditionally (bug #673524) but we now
# allow it for cases where libsigsegv is better for userspace handling
# of stack overflows.
# In particular, it's necessary for sparc: bug #768135
export ac_cv_libsigsegv=$(usex sparc)
local myeconfargs=(
--bindir="${EPREFIX}"/bin
$(use_enable nls)
$(use_enable pcre perl-regexp)
)
econf "${myeconfargs[@]}"
}
src_install() {
default
if use egrep-fgrep ; then
# Delete the upstream wrapper variants which warn on egrep+fgrep use
rm "${ED}"/bin/{egrep,fgrep} || die
into /
# Install egrep, fgrep which don't warn.
#
# We do this by default to avoid breakage in old scripts
# and such which don't expect unexpected output on stderr,
# we've had examples of builds failing because foo-config
# starts returning a warning.
#
# https://lists.gnu.org/archive/html/bug-grep/2022-10/msg00000.html
newbin - egrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -E "\$@"
EOF
newbin - fgrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -F "\$@"
EOF
fi
}

View File

@ -0,0 +1,115 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/grep.asc
inherit flag-o-matic verify-sig
DESCRIPTION="GNU regular expression matcher"
HOMEPAGE="https://www.gnu.org/software/grep/"
if [[ ${PV} == *_p* ]] ; then
# Subscribe to the 'platform-testers' ML to find these.
# Useful to test on our especially more niche arches and report issues upstream.
MY_COMMIT="35-c860"
MY_P=${PN}-$(ver_cut 1-2).${MY_COMMIT}
SRC_URI="https://meyering.net/${PN}/${MY_P}.tar.xz"
SRC_URI+=" verify-sig? ( https://meyering.net/${PN}/${MY_P}.tar.xz.sig )"
S="${WORKDIR}"/${MY_P}
else
SRC_URI="mirror://gnu/${PN}/${P}.tar.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-3+"
SLOT="0"
IUSE="+egrep-fgrep nls pcre static"
# We lack dev-libs/libsigsegv[static-libs] for now
REQUIRED_USE="static? ( !sparc )"
LIB_DEPEND="
pcre? ( >=dev-libs/libpcre2-7.8-r1[static-libs(+)] )
sparc? ( dev-libs/libsigsegv )
"
RDEPEND="
!static? ( ${LIB_DEPEND//\[static-libs(+)]} )
nls? ( virtual/libintl )
virtual/libiconv
"
DEPEND="
${RDEPEND}
static? ( ${LIB_DEPEND} )
"
BDEPEND="
virtual/pkgconfig
nls? ( sys-devel/gettext )
verify-sig? ( sec-keys/openpgp-keys-grep )
"
DOCS=( AUTHORS ChangeLog NEWS README THANKS TODO )
QA_CONFIG_IMPL_DECL_SKIP=(
# Either gnulib FPs or fixed in newer autoconf, not worth autoreconf here for now?
MIN
alignof
static_assert
)
src_prepare() {
default
# bug #523898
sed -i \
-e "s:@SHELL@:${EPREFIX}/bin/sh:g" \
-e "s:@grep@:${EPREFIX}/bin/grep:" \
src/egrep.sh || die
}
src_configure() {
use static && append-ldflags -static
# We used to turn this off unconditionally (bug #673524) but we now
# allow it for cases where libsigsegv is better for userspace handling
# of stack overflows.
# In particular, it's necessary for sparc: bug #768135
export ac_cv_libsigsegv=$(usex sparc)
local myeconfargs=(
--bindir="${EPREFIX}"/bin
$(use_enable nls)
$(use_enable pcre perl-regexp)
)
econf "${myeconfargs[@]}"
}
src_install() {
default
if use egrep-fgrep ; then
# Delete the upstream wrapper variants which warn on egrep+fgrep use
rm "${ED}"/bin/{egrep,fgrep} || die
into /
# Install egrep, fgrep which don't warn.
#
# We do this by default to avoid breakage in old scripts
# and such which don't expect unexpected output on stderr,
# we've had examples of builds failing because foo-config
# starts returning a warning.
#
# https://lists.gnu.org/archive/html/bug-grep/2022-10/msg00000.html
newbin - egrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -E "\$@"
EOF
newbin - fgrep <<-EOF
#!/usr/bin/env sh
exec "${EPREFIX}/bin/grep" -F "\$@"
EOF
fi
}

View File

@ -5,6 +5,18 @@
<email>base-system@gentoo.org</email>
<name>Gentoo Base System</name>
</maintainer>
<use>
<flag name="egrep-fgrep">
Install deprecated 'egrep' and 'fgrep' wrappers
for 'grep -E' and 'grep -F' respectively.
GNU grep 3.8 onwards warns about their usage by
default, but the versions installed by this flag do not.
No deprecation warnings are emitted when this
flag is enabled.
</flag>
</use>
<upstream>
<remote-id type="cpe">cpe:/a:gnu:grep</remote-id>
</upstream>

View File

@ -1 +1,3 @@
DIST groff-1.22.4.tar.gz 4137480 BLAKE2B cdda8a7e8e42b8d8991656ecfbffe0cd0ed5d8932467cab2f3c1eecb3365f4a5c03321b6ed929d451c3dfb00a46046a781303a1c55c4aa65eb7d178fb36b1cbc SHA512 1c42d3cd71efaf067b5850945d9097fa1f0fadd5e2b6ba7446bd9d4f439fe1ad058e4ddb0d4e0f503682137dfc7c822944ce1e3e5cf981673f8ba197ea77126d
DIST groff-1.23.0.rc3.tar.gz 7347387 BLAKE2B d61ccf18450816abb2436799c3ffac0ce0bc827ad4f262c94e172b0dbaae18593b7562576067e0380ff96cbc40b4fe63382082867659fbc6971cadc81e8dc36d SHA512 bfdc6761e02b698b7d7dac059c14c1f3de94057cda4952aca2fa41da3bd9657daef86bdddc46a392397ccb761f627d1652ce5f4a38890c480fbdb89f9926b662
DIST groff-1.23.0.rc4.tar.gz 7363288 BLAKE2B 3873cecf16f0ec474a1272396da95fd59437d3886b46e4dce8975f608251a8b23035a059650c0f05f7debbf13922a862be4c5168c25536111448e6c54b7ae987 SHA512 a65cae5d383fdbd7ac72f9bf6087cc290f2f8133b7040c5749d4dfee4427369643065ba4c6eedda1402cd3b9861440fcd6cb954cf3061beae140b18426162428

View File

@ -0,0 +1,38 @@
https://savannah.gnu.org/bugs/?63726
https://git.savannah.gnu.org/cgit/groff.git/commit/?id=10274fb69e517b2c4b10fcd0ba3347e5bd0eefd7
--- a/Makefile.in
+++ b/Makefile.in
@@ -4195,8 +4195,7 @@ SUFFIXES = .roff .in .ps .mom .pdf .me .ms .ps .html .txt .texi .dvi \
# tests launched by make check
check_SCRIPTS =
-TESTS = contrib/gdiffmk/tests/gdiffmk_tests.sh $(am__append_5) \
- $(am__append_8)
+TESTS = $(am__append_5) $(am__append_8)
AM_TESTS_ENVIRONMENT = \
abs_top_srcdir=$(abs_top_srcdir) \
abs_top_builddir=$(abs_top_builddir) \
@@ -9570,13 +9569,6 @@ recheck: all $(check_PROGRAMS) $(check_SCRIPTS)
am__force_recheck=am--force-recheck \
TEST_LOGS="$$log_list"; \
exit $$?
-contrib/gdiffmk/tests/gdiffmk_tests.sh.log: contrib/gdiffmk/tests/gdiffmk_tests.sh
- @p='contrib/gdiffmk/tests/gdiffmk_tests.sh'; \
- b='contrib/gdiffmk/tests/gdiffmk_tests.sh'; \
- $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
- --log-file $$b.log --trs-file $$b.trs \
- $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
- "$$tst" $(AM_TESTS_FD_REDIRECT)
contrib/hdtbl/examples/test-hdtbl.sh.log: contrib/hdtbl/examples/test-hdtbl.sh
@p='contrib/hdtbl/examples/test-hdtbl.sh'; \
b='contrib/hdtbl/examples/test-hdtbl.sh'; \
--- a/contrib/gdiffmk/gdiffmk.am
+++ b/contrib/gdiffmk/gdiffmk.am
@@ -26,7 +26,6 @@
########################################################################
gdiffmk_srcdir = $(top_srcdir)/contrib/gdiffmk
bin_SCRIPTS += gdiffmk
-TESTS += contrib/gdiffmk/tests/gdiffmk_tests.sh
man1_MANS += contrib/gdiffmk/gdiffmk.1
EXTRA_DIST += \
contrib/gdiffmk/gdiffmk.1.man \

View File

@ -1,9 +1,9 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit toolchain-funcs
inherit flag-o-matic toolchain-funcs
MY_P="${P/_/.}"
@ -15,7 +15,7 @@ SRC_URI="mirror://gnu/groff/${MY_P}.tar.gz
LICENSE="GPL-2"
SLOT="0"
[[ "${PV}" == *_rc* ]] || \
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE="examples uchardet X"
RDEPEND="
@ -39,6 +39,7 @@ S="${WORKDIR}/${MY_P}"
PATCHES=(
"${FILESDIR}"/${PN}-1.19.2-man-unicode-dashes.patch #16108 #17580 #121502
"${FILESDIR}"/${PN}-1.22.4-skip-broken-diffutils-test.patch
)
src_prepare() {
@ -70,6 +71,9 @@ src_configure() {
export gl_cv_func_signbit_gcc=yes
fi
# Drop in release after 1.22.4! bug #894154
append-cxxflags -std=gnu++11
local myeconfargs=(
--with-appresdir="${EPREFIX}"/usr/share/X11/app-defaults
$(use_with uchardet)

View File

@ -0,0 +1,108 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
MY_P="${P/_/.}"
DESCRIPTION="Text formatter used for man pages"
HOMEPAGE="https://www.gnu.org/software/groff/groff.html"
if [[ ${PV} == *_rc* ]] ; then
SRC_URI="https://alpha.gnu.org/gnu/groff/${MY_P}.tar.gz"
else
SRC_URI="mirror://gnu/groff/${MY_P}.tar.gz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
S="${WORKDIR}/${MY_P}"
LICENSE="GPL-2"
SLOT="0"
IUSE="examples uchardet X"
RDEPEND="
uchardet? ( app-i18n/uchardet )
X? (
x11-libs/libICE
x11-libs/libSM
x11-libs/libX11
x11-libs/libXaw
x11-libs/libXmu
x11-libs/libXt
)
"
DEPEND="${RDEPEND}"
BDEPEND="
dev-lang/perl
sys-apps/texinfo
"
DOCS=( BUG-REPORT ChangeLog MORE.STUFF NEWS PROBLEMS PROJECTS README TODO )
PATCHES=(
# bug #16108, bug #17580, bug #121502
"${FILESDIR}"/${PN}-1.19.2-man-unicode-dashes.patch
)
src_prepare() {
default
# Honor Gentoo's docdir
sed -i -e "s|^docdir =.*|docdir = \"${EPREFIX}/usr/share/doc/${PF}\"|g" \
Makefile.in \
|| die "failed to modify Makefile.in"
local pfx=$(usex prefix ' Prefix' '')
cat <<-EOF >> tmac/mdoc.local || die
.ds volume-operating-system Gentoo${pfx}
.ds operating-system Gentoo${pfx}/${KERNEL}
.ds default-operating-system Gentoo${pfx}/${KERNEL}
EOF
# make sure we don't get a crappy `g' nameprefix on UNIX systems with real
# troff (GROFF_G macro runs some test to see, its own troff doesn't satisfy)
sed -i -e 's/^[ \t]\+g=g$/g=/' configure || die
}
src_configure() {
local myeconfargs=(
--with-appdefdir="${EPREFIX}"/usr/share/X11/app-defaults
$(use_with uchardet)
$(use_with X x)
)
econf "${myeconfargs[@]}"
}
src_compile() {
local -a CROSS_ARGS
tc-is-cross-compiler && CROSS_ARGS+=(
GROFFBIN="$(type -P groff)"
TROFFBIN="$(type -P troff)"
GROFF_BIN_DIR=
GROFF_BIN_PATH=
)
emake AR="$(tc-getAR)" "${CROSS_ARGS[@]}"
}
src_install() {
default
# The following links are required for man, bug #123674
dosym eqn /usr/bin/geqn
dosym tbl /usr/bin/gtbl
if ! use examples ; then
# The pdf files might not be generated if ghostscript is unavailable, bug #602020
local pdf="${ED}/usr/share/doc/${PF}/examples/mom/mom-pdf.pdf"
if [[ -e ${pdf} ]] ; then
# Keep mom-pdf.pdf since it's more of a manual than an example
# bug #454196 and bug #516732
mv "${pdf}" "${ED}/usr/share/doc/${PF}/pdf/" || die
fi
rm -rf "${ED}/usr/share/doc/${PF}/examples"
fi
}

View File

@ -0,0 +1,108 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
MY_P="${P/_/.}"
DESCRIPTION="Text formatter used for man pages"
HOMEPAGE="https://www.gnu.org/software/groff/groff.html"
if [[ ${PV} == *_rc* ]] ; then
SRC_URI="https://alpha.gnu.org/gnu/groff/${MY_P}.tar.gz"
else
SRC_URI="mirror://gnu/groff/${MY_P}.tar.gz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
S="${WORKDIR}/${MY_P}"
LICENSE="GPL-2"
SLOT="0"
IUSE="examples uchardet X"
RDEPEND="
uchardet? ( app-i18n/uchardet )
X? (
x11-libs/libICE
x11-libs/libSM
x11-libs/libX11
x11-libs/libXaw
x11-libs/libXmu
x11-libs/libXt
)
"
DEPEND="${RDEPEND}"
BDEPEND="
dev-lang/perl
sys-apps/texinfo
"
DOCS=( BUG-REPORT ChangeLog MORE.STUFF NEWS PROBLEMS PROJECTS README TODO )
PATCHES=(
# bug #16108, bug #17580, bug #121502
"${FILESDIR}"/${PN}-1.19.2-man-unicode-dashes.patch
)
src_prepare() {
default
# Honor Gentoo's docdir
sed -i -e "s|^docdir =.*|docdir = \"${EPREFIX}/usr/share/doc/${PF}\"|g" \
Makefile.in \
|| die "failed to modify Makefile.in"
local pfx=$(usex prefix ' Prefix' '')
cat <<-EOF >> tmac/mdoc.local || die
.ds volume-operating-system Gentoo${pfx}
.ds operating-system Gentoo${pfx}/${KERNEL}
.ds default-operating-system Gentoo${pfx}/${KERNEL}
EOF
# make sure we don't get a crappy `g' nameprefix on UNIX systems with real
# troff (GROFF_G macro runs some test to see, its own troff doesn't satisfy)
sed -i -e 's/^[ \t]\+g=g$/g=/' configure || die
}
src_configure() {
local myeconfargs=(
--with-appdefdir="${EPREFIX}"/usr/share/X11/app-defaults
$(use_with uchardet)
$(use_with X x)
)
econf "${myeconfargs[@]}"
}
src_compile() {
local -a CROSS_ARGS
tc-is-cross-compiler && CROSS_ARGS+=(
GROFFBIN="$(type -P groff)"
TROFFBIN="$(type -P troff)"
GROFF_BIN_DIR=
GROFF_BIN_PATH=
)
emake AR="$(tc-getAR)" "${CROSS_ARGS[@]}"
}
src_install() {
default
# The following links are required for man, bug #123674
dosym eqn /usr/bin/geqn
dosym tbl /usr/bin/gtbl
if ! use examples ; then
# The pdf files might not be generated if ghostscript is unavailable, bug #602020
local pdf="${ED}/usr/share/doc/${PF}/examples/mom/mom-pdf.pdf"
if [[ -e ${pdf} ]] ; then
# Keep mom-pdf.pdf since it's more of a manual than an example
# bug #454196 and bug #516732
mv "${pdf}" "${ED}/usr/share/doc/${PF}/pdf/" || die
fi
rm -rf "${ED}/usr/share/doc/${PF}/examples"
fi
}

View File

@ -8,4 +8,8 @@
<use>
<flag name="uchardet">Enable automatic encoding detection via <pkg>app-i18n/uchardet</pkg></flag>
</use>
<upstream>
<remote-id type="cpe">cpe:/a:gnu:groff</remote-id>
<remote-id type="savannah">groff</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1,2 +1,3 @@
DIST hwdata-0.353.tar.gz 2206215 BLAKE2B e1c30d7d486a2f03eb8b59dfc12544a5e5a988295d5dc220e2d6a344991c62d8ded0e8e71a8b0907fb9fb7fe0bac8528386cc4665c903362db6ed6f0a6985b94 SHA512 f4bdea533a1cdf406d065da6a684b131b30f6a0b8fb791418d54b756c9297da981a8e25e128ef97af50ae88553e1473dba17a29c11a15490065faf9bf2dcd0d4
DIST hwdata-0.354.tar.gz 2212834 BLAKE2B 5df04fd6069e131be7195b515f4f7273e28030d46823fa3054371f9afde4eb9976df2663bc7d31d056cb718a479630676f05459064decd59914f3a69bcfb03f1 SHA512 07bbe5137f35c0402029e066e90a29da1ca95faa6996a192b1f9ac00568e5020cc540b642ad2b22b25c2cfa0d7e4c2d7b80c9978ca0cd091691d8f1cf2933915
DIST hwdata-0.367.tar.gz 2313810 BLAKE2B 7f4be3f0b3c8ec6d90860031677b1e1bc6fac9159291ee772501e5f5aee0d43855e27fb6f9c4b0c65b04353fee1222f5e6c0f0a40fa743a32fdcb9509ebc772d SHA512 ed04282c4046193debb02b325b57cd0ef78d5ceb485d104f10d8aa1fe3ba42aeee8071ac806db95c03b40e6fc1d7c8c5f036adca7744a9d9376b0a146f6ec5a8
DIST hwdata-0.369.tar.gz 2328002 BLAKE2B b2b580bdb225ed0cf6d694b2e1d9e184f3ca7caa4cf93929df2c45866d7433256213afd489ffc816fa3509154b66c02d9d44a8070a2852d4688c9d01c38d2acd SHA512 a451ac7da77bdd26b0e37b64859c79e2dbe3359a3ba0490d49e6edae08b0abb4199598dea2f9b53f775825210da7e0d3263bfefe4e5c34fe65842522c328bc99
DIST hwdata-0.370.tar.gz 2332791 BLAKE2B 92c68ce6ff05a9cae24e77794eb665672df9ad635cb2830b246f042ea2e8418eca132e6dc7ccda647fcaecbe888477c9f7a1f7e0fdd94de962c61c2bd3a68779 SHA512 a7a3e7685dd6beecf19cd177082b36b2f799f580f1b5b3838495948a686b81f1a981d9335faae9a52a3d5845eed950357e0a6ac5a178564ce54ddef00448bce4

View File

@ -0,0 +1,28 @@
# Copyright 2022-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit edo
DESCRIPTION="Hardware identification and configuration data"
HOMEPAGE="https://github.com/vcrhonek/hwdata"
SRC_URI="https://github.com/vcrhonek/hwdata/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux"
RESTRICT="test"
src_configure() {
# configure is not compatible with econf
local conf=(
./configure
--prefix="${EPREFIX}/usr"
--libdir="${EPREFIX}/lib"
--datadir="${EPREFIX}/usr/share"
)
edo "${conf[@]}"
}

View File

@ -0,0 +1,28 @@
# Copyright 2022-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit edo
DESCRIPTION="Hardware identification and configuration data"
HOMEPAGE="https://github.com/vcrhonek/hwdata"
SRC_URI="https://github.com/vcrhonek/hwdata/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
RESTRICT="test"
src_configure() {
# configure is not compatible with econf
local conf=(
./configure
--prefix="${EPREFIX}/usr"
--libdir="${EPREFIX}/lib"
--datadir="${EPREFIX}/usr/share"
)
edo "${conf[@]}"
}

View File

@ -0,0 +1,28 @@
# Copyright 2022-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit edo
DESCRIPTION="Hardware identification and configuration data"
HOMEPAGE="https://github.com/vcrhonek/hwdata"
SRC_URI="https://github.com/vcrhonek/hwdata/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
RESTRICT="test"
src_configure() {
# configure is not compatible with econf
local conf=(
./configure
--prefix="${EPREFIX}/usr"
--libdir="${EPREFIX}/lib"
--datadir="${EPREFIX}/usr/share"
)
edo "${conf[@]}"
}

View File

@ -5,4 +5,7 @@
<email>base-system@gentoo.org</email>
</maintainer>
<stabilize-allarches/>
<upstream>
<remote-id type="github">vcrhonek/hwdata</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1,3 +1,5 @@
DIST iproute2-5.13.0.tar.xz 845236 BLAKE2B e1c148e2a720236163e7f4d46aa38d244a02ae36ad86571c5606d54c9ccfd8d0363e2fb793d48cf39aae322b3c36b9f8a43eaf570dbdb8243092926cef3d2786 SHA512 a3286639fb303a7c3c553cb5df0a7336c4c67e53eb05e872d2776b771dbfa36ffdf2df140f570275db6785c882992f469f8eb34a5b506aac876216df7dde245d
DIST iproute2-5.14.0.tar.xz 853572 BLAKE2B 52544021798f2cb716a57998d98dadc2441142b02d38c7e274bc17a6e5f994bdb5bd3ebf0b896bfd7e327a44f00f92c2af8e67367cdc0aac70769d563082f543 SHA512 e2b9b0a2c3e6fc4c67cb50b0a9bf710e749648b83369a49bf905edd7e519d76c50c2cc818bb63cc605c409c66075d4d371f2371796e5f7a8f9d04101b80ef75c
DIST iproute2-5.15.0.tar.xz 858068 BLAKE2B bca20ac53e1b2b3ae06186f655ad5073a0e691ed7b3aab25c4fbc118847b72a8a522175732cd22d8ec27480d1ab142319e80a5c3628434bec21260e585e1591d SHA512 e94918fa10e523224b965c7cb5303a101745e89c90d149d2d9876a002b2a894b1c689c519dc22168f3d334c3ee0810c59ec43223baab3d5f4c56f017d6281f22
DIST iproute2-6.0.0.tar.xz 900312 BLAKE2B 1cfb9b5a7892dec2b35e0eadbd957083e95fdc5077a1aa193329801ff25f9ed90a1fc4152756547be1fab8fe18d9a399001a4c3a61e951f64946156af6a90bae SHA512 be30362b0df6906aa786f935d5f555b8b86c747fe05314066f4180ab2f7c952ae227b7cf04c15e75d8f99ca17bafb7c8dc0fb1c18f3a9e3222d98716bb449f7a
DIST iproute2-6.1.0.tar.xz 905512 BLAKE2B 38249703e0a9ba74405aebdb97560b286deefa959a9c3f0e0893962b6966f5da2da46199dda6a0f9584bb473f8ba529440643d97f66e9b7619df029e3091d163 SHA512 4e4d3b5e1e1a5444f42671c1e6caee072e80063e34e37386695f76f85a1ab662f4513050814006e5154426cbaadfba1d86b0be14e65978d5e670a16446047b28
DIST iproute2-6.2.0.tar.xz 911588 BLAKE2B d3bfaecf33ffc7861e983e8db0d6a63f4767b6c01b5346e88f51c65ed6279c4be29412ed18b8f98ed54d60a84455b73fe7745142fd0fc0f3e327a29e8bcce986 SHA512 b24e0fdd0f51b8b78bc3bb681e3829af47d3011e93f3892289eb070b336709a6883728ecc7627ca37f6449720f8ed1349af321c0d04454894a7175b82f7de151
DIST iproute2-6.3.0.tar.xz 914700 BLAKE2B a7b48c59c8a30f56ca810136f4d9f681fe38359999c260227a6229b972ce70b233d2865a6543cf3f70ed586825f9191c22d459a9fc5cc8c7dbf3ab417064c8a7 SHA512 aec1d8ceb54c8849a075ec1ce079678638e05ccaec093e8b3cbc7243b5fafea2a8c11f10930fced3df82f52d6750aa325178e44f9058e37a556ab108d4a968bf

View File

@ -0,0 +1,39 @@
fix UB in strncpy (e.g. truncated ip route output)
Fix overlapping buffers passed to strncpy which is UB. format_host_rta_r writes
to the buffer passed to it, so hostname (derived from b1) & b1 partly overlap.
This gets worse with sys-libs/glibc-2.37 where the ip route output can be truncated,
but it was UB anyway and you can see it occurring w/ glibc-2.36.
Bug: https://lore.kernel.org/netdev/0011AC38-4823-4D0A-8580-B108D08959C2@gentoo.org/T/#u
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=30112
Thanks-to: Doug Freed <dwfreed@mtu.edu>
--- a/ip/iproute.c
+++ b/ip/iproute.c
@@ -753,6 +753,7 @@ int print_route(struct nlmsghdr *n, void *arg)
int ret;
SPRINT_BUF(b1);
+ SPRINT_BUF(b2);
if (n->nlmsg_type != RTM_NEWROUTE && n->nlmsg_type != RTM_DELROUTE) {
fprintf(stderr, "Not a route: %08x %08x %08x\n",
@@ -814,7 +815,7 @@ int print_route(struct nlmsghdr *n, void *arg)
r->rtm_dst_len);
} else {
const char *hostname = format_host_rta_r(family, tb[RTA_DST],
- b1, sizeof(b1));
+ b2, sizeof(b2));
if (hostname)
strncpy(b1, hostname, sizeof(b1) - 1);
}
@@ -837,7 +838,7 @@ int print_route(struct nlmsghdr *n, void *arg)
r->rtm_src_len);
} else {
const char *hostname = format_host_rta_r(family, tb[RTA_SRC],
- b1, sizeof(b1));
+ b2, sizeof(b2));
if (hostname)
strncpy(b1, hostname, sizeof(b1) - 1);
}

View File

@ -0,0 +1,7 @@
diff --git a/ip/ip.c b/ip/ip.c
index 40d2998a..454da1a3 100644
--- a/ip/ip.c
+++ b/ip/ip.c
@@ -169 +169 @@ int main(int argc, char **argv)
- int color = 0;
+ int color = COLOR_OPT_AUTO;

View File

@ -10,7 +10,7 @@ if [[ ${PV} == "9999" ]] ; then
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/net/${PN}/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
fi
DESCRIPTION="kernel routing and traffic control utilities"

View File

@ -0,0 +1,215 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit edo toolchain-funcs
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/net/${PN}/${P}.tar.xz"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
fi
DESCRIPTION="kernel routing and traffic control utilities"
HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2"
LICENSE="GPL-2"
SLOT="0"
IUSE="atm berkdb bpf caps elf +iptables libbsd minimal nfs selinux split-usr"
# We could make libmnl optional, but it's tiny, so eh
RDEPEND="
!net-misc/arpd
!minimal? ( net-libs/libmnl:= )
atm? ( net-dialup/linux-atm )
berkdb? ( sys-libs/db:= )
bpf? ( dev-libs/libbpf:= )
caps? ( sys-libs/libcap )
elf? ( virtual/libelf:= )
iptables? ( >=net-firewall/iptables-1.4.20:= )
libbsd? ( dev-libs/libbsd )
nfs? ( net-libs/libtirpc:= )
selinux? ( sys-libs/libselinux )
"
# We require newer linux-headers for ipset support (bug #549948) and some defines (bug #553876)
DEPEND="
${RDEPEND}
>=sys-kernel/linux-headers-3.16
"
BDEPEND="
app-arch/xz-utils
>=sys-devel/bison-2.4
sys-devel/flex
virtual/pkgconfig
"
PATCHES=(
"${FILESDIR}"/${PN}-3.1.0-mtu.patch # bug #291907
"${FILESDIR}"/${PN}-5.12.0-configure-nomagic.patch # bug #643722
#"${FILESDIR}"/${PN}-5.1.0-portability.patch
"${FILESDIR}"/${PN}-5.7.0-mix-signal.h-include.patch
"${FILESDIR}"/${PN}-default-color-auto.patch
)
src_prepare() {
default
# Fix version if necessary
local versionfile="include/version.h"
if [[ ${PV} != 9999 ]] && ! grep -Fq "${PV}" ${versionfile} ; then
einfo "Fixing version string"
sed "s@\"[[:digit:]\.]\+\"@\"${PV}\"@" \
-i ${versionfile} || die
fi
# echo -n is not POSIX compliant
sed 's@echo -n@printf@' -i configure || die
sed -i \
-e '/^CC :\?=/d' \
-e "/^LIBDIR/s:=.*:=/$(get_libdir):" \
-e "s|-O2|${CFLAGS} ${CPPFLAGS}|" \
-e "/^HOSTCC/s:=.*:= $(tc-getBUILD_CC):" \
-e "/^DBM_INCLUDE/s:=.*:=${T}:" \
Makefile || die
# Build against system headers
rm -r include/netinet || die #include/linux include/ip{,6}tables{,_common}.h include/libiptc
sed -i 's:TCPI_OPT_ECN_SEEN:16:' misc/ss.c || die
if use minimal ; then
sed -i -e '/^SUBDIRS=/s:=.*:=lib tc ip:' Makefile || die
fi
}
src_configure() {
tc-export AR CC PKG_CONFIG
# This sure is ugly. Should probably move into toolchain-funcs at some point.
local setns
pushd "${T}" >/dev/null || die
printf '#include <sched.h>\nint main(){return setns(0, 0);}\n' > test.c || die
if ${CC} ${CFLAGS} ${CPPFLAGS} -D_GNU_SOURCE ${LDFLAGS} test.c >&/dev/null ; then
setns=y
else
setns=n
fi
echo 'int main(){return 0;}' > test.c || die
if ! ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.c -lresolv >&/dev/null ; then
sed -i '/^LDLIBS/s:-lresolv::' "${S}"/Makefile || die
fi
popd >/dev/null || die
# run "configure" script first which will create "config.mk"...
# Using econf breaks since 5.14.0 (a9c3d70d902a0473ee5c13336317006a52ce8242)
edo ./configure --libbpf_force $(usex bpf on off)
# Remove the definitions made by configure and allow them to be overridden
# by USE flags below.
# We have to do the cheesy only-sed-if-disabled because otherwise
# the *_FLAGS etc stuff found by configure will be used but result
# in a broken build.
if ! use berkdb ; then
sed -i -e '/HAVE_BERKELEY_DB/d' config.mk || die
fi
if ! use caps ; then
sed -i -e '/HAVE_CAP/d' config.mk || die
fi
if use minimal ; then
sed -i -e '/HAVE_MNL/d' config.mk || die
fi
if ! use elf ; then
sed -i -e '/HAVE_ELF/d' config.mk || die
fi
if ! use nfs ; then
sed -i -e '/HAVE_RPC/d' config.mk || die
fi
if ! use selinux ; then
sed -i -e '/HAVE_SELINUX/d' config.mk || die
fi
if ! use libbsd ; then
sed -i -e '/HAVE_LIBBSD/d' config.mk || die
fi
# ...Now switch on/off requested features via USE flags
# this is only useful if the test did not set other things, per bug #643722
# Keep in sync with ifs above, or refactor to be unified.
cat <<-EOF >> config.mk
TC_CONFIG_ATM := $(usex atm y n)
TC_CONFIG_XT := $(usex iptables y n)
TC_CONFIG_NO_XT := $(usex iptables n y)
# We've locked in recent enough kernel headers, bug #549948
TC_CONFIG_IPSET := y
HAVE_BERKELEY_DB := $(usex berkdb y n)
HAVE_CAP := $(usex caps y n)
HAVE_MNL := $(usex minimal n y)
HAVE_ELF := $(usex elf y n)
HAVE_RPC := $(usex nfs y n)
HAVE_SELINUX := $(usex selinux y n)
IP_CONFIG_SETNS := ${setns}
# Use correct iptables dir, bug #144265, bug #293709
IPT_LIB_DIR := $(use iptables && ${PKG_CONFIG} xtables --variable=xtlibdir)
HAVE_LIBBSD := $(usex libbsd y n)
EOF
}
src_compile() {
emake V=1 NETNS_RUN_DIR=/run/netns
}
src_install() {
if use minimal ; then
into /
dosbin tc/tc
dobin ip/ip
return 0
fi
emake \
DESTDIR="${D}" \
PREFIX="${EPREFIX}/usr" \
LIBDIR="${EPREFIX}"/$(get_libdir) \
SBINDIR="${EPREFIX}"/sbin \
CONFDIR="${EPREFIX}"/etc/iproute2 \
DOCDIR="${EPREFIX}"/usr/share/doc/${PF} \
MANDIR="${EPREFIX}"/usr/share/man \
ARPDDIR="${EPREFIX}"/var/lib/arpd \
install
dodir /bin
mv "${ED}"/{s,}bin/ip || die # bug #330115
dolib.a lib/libnetlink.a
insinto /usr/include
doins include/libnetlink.h
# Collides with net-analyzer/ifstat
# https://bugs.gentoo.org/868321
mv "${ED}"/sbin/ifstat{,-iproute2} || die
if use split-usr ; then
# Can remove compatibility symlink in a year: 2023-05-28.
# bug #547264
mv "${ED}"/sbin/ss "${ED}"/bin/ss || die
dosym -r /bin/ss /sbin/ss
fi
if use berkdb ; then
keepdir /var/lib/arpd
# bug #47482, arpd doesn't need to be in /sbin
dodir /usr/bin
mv "${ED}"/sbin/arpd "${ED}"/usr/bin/ || die
elif [[ -d "${ED}"/var/lib/arpd ]]; then
rmdir --ignore-fail-on-non-empty -p "${ED}"/var/lib/arpd || die
fi
}

View File

@ -0,0 +1,216 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit edo toolchain-funcs
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/net/${PN}/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
fi
DESCRIPTION="kernel routing and traffic control utilities"
HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2"
LICENSE="GPL-2"
SLOT="0"
IUSE="atm berkdb bpf caps elf +iptables libbsd minimal nfs selinux split-usr"
# We could make libmnl optional, but it's tiny, so eh
RDEPEND="
!net-misc/arpd
!minimal? ( net-libs/libmnl:= )
atm? ( net-dialup/linux-atm )
berkdb? ( sys-libs/db:= )
bpf? ( dev-libs/libbpf:= )
caps? ( sys-libs/libcap )
elf? ( virtual/libelf:= )
iptables? ( >=net-firewall/iptables-1.4.20:= )
libbsd? ( dev-libs/libbsd )
nfs? ( net-libs/libtirpc:= )
selinux? ( sys-libs/libselinux )
"
# We require newer linux-headers for ipset support (bug #549948) and some defines (bug #553876)
DEPEND="
${RDEPEND}
>=sys-kernel/linux-headers-3.16
"
BDEPEND="
app-arch/xz-utils
>=sys-devel/bison-2.4
sys-devel/flex
virtual/pkgconfig
"
PATCHES=(
"${FILESDIR}"/${PN}-3.1.0-mtu.patch # bug #291907
"${FILESDIR}"/${PN}-5.12.0-configure-nomagic.patch # bug #643722
#"${FILESDIR}"/${PN}-5.1.0-portability.patch
"${FILESDIR}"/${PN}-5.7.0-mix-signal.h-include.patch
"${FILESDIR}"/${PN}-default-color-auto.patch
"${FILESDIR}"/${PN}-6.1.0-strncpy-overlap.patch
)
src_prepare() {
default
# Fix version if necessary
local versionfile="include/version.h"
if [[ ${PV} != 9999 ]] && ! grep -Fq "${PV}" ${versionfile} ; then
einfo "Fixing version string"
sed "s@\"[[:digit:]\.]\+\"@\"${PV}\"@" \
-i ${versionfile} || die
fi
# echo -n is not POSIX compliant
sed 's@echo -n@printf@' -i configure || die
sed -i \
-e '/^CC :\?=/d' \
-e "/^LIBDIR/s:=.*:=/$(get_libdir):" \
-e "s|-O2|${CFLAGS} ${CPPFLAGS}|" \
-e "/^HOSTCC/s:=.*:= $(tc-getBUILD_CC):" \
-e "/^DBM_INCLUDE/s:=.*:=${T}:" \
Makefile || die
# Build against system headers
rm -r include/netinet || die #include/linux include/ip{,6}tables{,_common}.h include/libiptc
sed -i 's:TCPI_OPT_ECN_SEEN:16:' misc/ss.c || die
if use minimal ; then
sed -i -e '/^SUBDIRS=/s:=.*:=lib tc ip:' Makefile || die
fi
}
src_configure() {
tc-export AR CC PKG_CONFIG
# This sure is ugly. Should probably move into toolchain-funcs at some point.
local setns
pushd "${T}" >/dev/null || die
printf '#include <sched.h>\nint main(){return setns(0, 0);}\n' > test.c || die
if ${CC} ${CFLAGS} ${CPPFLAGS} -D_GNU_SOURCE ${LDFLAGS} test.c >&/dev/null ; then
setns=y
else
setns=n
fi
echo 'int main(){return 0;}' > test.c || die
if ! ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.c -lresolv >&/dev/null ; then
sed -i '/^LDLIBS/s:-lresolv::' "${S}"/Makefile || die
fi
popd >/dev/null || die
# run "configure" script first which will create "config.mk"...
# Using econf breaks since 5.14.0 (a9c3d70d902a0473ee5c13336317006a52ce8242)
edo ./configure --libbpf_force $(usex bpf on off)
# Remove the definitions made by configure and allow them to be overridden
# by USE flags below.
# We have to do the cheesy only-sed-if-disabled because otherwise
# the *_FLAGS etc stuff found by configure will be used but result
# in a broken build.
if ! use berkdb ; then
sed -i -e '/HAVE_BERKELEY_DB/d' config.mk || die
fi
if ! use caps ; then
sed -i -e '/HAVE_CAP/d' config.mk || die
fi
if use minimal ; then
sed -i -e '/HAVE_MNL/d' config.mk || die
fi
if ! use elf ; then
sed -i -e '/HAVE_ELF/d' config.mk || die
fi
if ! use nfs ; then
sed -i -e '/HAVE_RPC/d' config.mk || die
fi
if ! use selinux ; then
sed -i -e '/HAVE_SELINUX/d' config.mk || die
fi
if ! use libbsd ; then
sed -i -e '/HAVE_LIBBSD/d' config.mk || die
fi
# ...Now switch on/off requested features via USE flags
# this is only useful if the test did not set other things, per bug #643722
# Keep in sync with ifs above, or refactor to be unified.
cat <<-EOF >> config.mk
TC_CONFIG_ATM := $(usex atm y n)
TC_CONFIG_XT := $(usex iptables y n)
TC_CONFIG_NO_XT := $(usex iptables n y)
# We've locked in recent enough kernel headers, bug #549948
TC_CONFIG_IPSET := y
HAVE_BERKELEY_DB := $(usex berkdb y n)
HAVE_CAP := $(usex caps y n)
HAVE_MNL := $(usex minimal n y)
HAVE_ELF := $(usex elf y n)
HAVE_RPC := $(usex nfs y n)
HAVE_SELINUX := $(usex selinux y n)
IP_CONFIG_SETNS := ${setns}
# Use correct iptables dir, bug #144265, bug #293709
IPT_LIB_DIR := $(use iptables && ${PKG_CONFIG} xtables --variable=xtlibdir)
HAVE_LIBBSD := $(usex libbsd y n)
EOF
}
src_compile() {
emake V=1 NETNS_RUN_DIR=/run/netns
}
src_install() {
if use minimal ; then
into /
dosbin tc/tc
dobin ip/ip
return 0
fi
emake \
DESTDIR="${D}" \
PREFIX="${EPREFIX}/usr" \
LIBDIR="${EPREFIX}"/$(get_libdir) \
SBINDIR="${EPREFIX}"/sbin \
CONFDIR="${EPREFIX}"/etc/iproute2 \
DOCDIR="${EPREFIX}"/usr/share/doc/${PF} \
MANDIR="${EPREFIX}"/usr/share/man \
ARPDDIR="${EPREFIX}"/var/lib/arpd \
install
dodir /bin
mv "${ED}"/{s,}bin/ip || die # bug #330115
dolib.a lib/libnetlink.a
insinto /usr/include
doins include/libnetlink.h
# Collides with net-analyzer/ifstat
# https://bugs.gentoo.org/868321
mv "${ED}"/sbin/ifstat{,-iproute2} || die
if use split-usr ; then
# Can remove compatibility symlink in a year: 2023-05-28.
# bug #547264
mv "${ED}"/sbin/ss "${ED}"/bin/ss || die
dosym -r /bin/ss /sbin/ss
fi
if use berkdb ; then
keepdir /var/lib/arpd
# bug #47482, arpd doesn't need to be in /sbin
dodir /usr/bin
mv "${ED}"/sbin/arpd "${ED}"/usr/bin/ || die
elif [[ -d "${ED}"/var/lib/arpd ]]; then
rmdir --ignore-fail-on-non-empty -p "${ED}"/var/lib/arpd || die
fi
}

View File

@ -0,0 +1,220 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit edo toolchain-funcs
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/net/${PN}/${P}.tar.xz"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
fi
DESCRIPTION="kernel routing and traffic control utilities"
HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2"
LICENSE="GPL-2"
SLOT="0"
IUSE="atm berkdb bpf caps elf +iptables libbsd minimal nfs selinux split-usr"
# Needs root
RESTRICT="test"
# We could make libmnl optional, but it's tiny, so eh
RDEPEND="
!net-misc/arpd
!minimal? ( net-libs/libmnl:= )
atm? ( net-dialup/linux-atm )
berkdb? ( sys-libs/db:= )
bpf? ( dev-libs/libbpf:= )
caps? ( sys-libs/libcap )
elf? ( virtual/libelf:= )
iptables? ( >=net-firewall/iptables-1.4.20:= )
libbsd? ( dev-libs/libbsd )
nfs? ( net-libs/libtirpc:= )
selinux? ( sys-libs/libselinux )
"
# We require newer linux-headers for ipset support (bug #549948) and some defines (bug #553876)
DEPEND="
${RDEPEND}
>=sys-kernel/linux-headers-3.16
"
BDEPEND="
app-arch/xz-utils
>=sys-devel/bison-2.4
sys-devel/flex
virtual/pkgconfig
"
PATCHES=(
"${FILESDIR}"/${PN}-3.1.0-mtu.patch # bug #291907
"${FILESDIR}"/${PN}-5.12.0-configure-nomagic.patch # bug #643722
#"${FILESDIR}"/${PN}-5.1.0-portability.patch
"${FILESDIR}"/${PN}-5.7.0-mix-signal.h-include.patch
)
src_prepare() {
default
# Fix version if necessary
local versionfile="include/version.h"
if [[ ${PV} != 9999 ]] && ! grep -Fq "${PV}" ${versionfile} ; then
einfo "Fixing version string"
sed "s@\"[[:digit:]\.]\+\"@\"${PV}\"@" \
-i ${versionfile} || die
fi
# echo -n is not POSIX compliant
sed 's@echo -n@printf@' -i configure || die
sed -i \
-e '/^CC :\?=/d' \
-e "/^LIBDIR/s:=.*:=/$(get_libdir):" \
-e "s|-O2|${CFLAGS} ${CPPFLAGS}|" \
-e "/^HOSTCC/s:=.*:= $(tc-getBUILD_CC):" \
-e "/^DBM_INCLUDE/s:=.*:=${T}:" \
Makefile || die
# Build against system headers
rm -r include/netinet || die #include/linux include/ip{,6}tables{,_common}.h include/libiptc
sed -i 's:TCPI_OPT_ECN_SEEN:16:' misc/ss.c || die
if use minimal ; then
sed -i -e '/^SUBDIRS=/s:=.*:=lib tc ip:' Makefile || die
fi
}
src_configure() {
tc-export AR CC PKG_CONFIG
# This sure is ugly. Should probably move into toolchain-funcs at some point.
local setns
pushd "${T}" >/dev/null || die
printf '#include <sched.h>\nint main(){return setns(0, 0);}\n' > test.c || die
if ${CC} ${CFLAGS} ${CPPFLAGS} -D_GNU_SOURCE ${LDFLAGS} test.c >&/dev/null ; then
setns=y
else
setns=n
fi
echo 'int main(){return 0;}' > test.c || die
if ! ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.c -lresolv >&/dev/null ; then
sed -i '/^LDLIBS/s:-lresolv::' "${S}"/Makefile || die
fi
popd >/dev/null || die
# run "configure" script first which will create "config.mk"...
# Using econf breaks since 5.14.0 (a9c3d70d902a0473ee5c13336317006a52ce8242)
edo ./configure --libbpf_force $(usex bpf on off)
# Remove the definitions made by configure and allow them to be overridden
# by USE flags below.
# We have to do the cheesy only-sed-if-disabled because otherwise
# the *_FLAGS etc stuff found by configure will be used but result
# in a broken build.
if ! use berkdb ; then
sed -i -e '/HAVE_BERKELEY_DB/d' config.mk || die
fi
if ! use caps ; then
sed -i -e '/HAVE_CAP/d' config.mk || die
fi
if use minimal ; then
sed -i -e '/HAVE_MNL/d' config.mk || die
fi
if ! use elf ; then
sed -i -e '/HAVE_ELF/d' config.mk || die
fi
if ! use nfs ; then
sed -i -e '/HAVE_RPC/d' config.mk || die
fi
if ! use selinux ; then
sed -i -e '/HAVE_SELINUX/d' config.mk || die
fi
if ! use libbsd ; then
sed -i -e '/HAVE_LIBBSD/d' config.mk || die
fi
# ...Now switch on/off requested features via USE flags
# this is only useful if the test did not set other things, per bug #643722
# Keep in sync with ifs above, or refactor to be unified.
cat <<-EOF >> config.mk
TC_CONFIG_ATM := $(usex atm y n)
TC_CONFIG_XT := $(usex iptables y n)
TC_CONFIG_NO_XT := $(usex iptables n y)
# We've locked in recent enough kernel headers, bug #549948
TC_CONFIG_IPSET := y
HAVE_BERKELEY_DB := $(usex berkdb y n)
HAVE_CAP := $(usex caps y n)
HAVE_MNL := $(usex minimal n y)
HAVE_ELF := $(usex elf y n)
HAVE_RPC := $(usex nfs y n)
HAVE_SELINUX := $(usex selinux y n)
IP_CONFIG_SETNS := ${setns}
# Use correct iptables dir, bug #144265, bug #293709
IPT_LIB_DIR := $(use iptables && ${PKG_CONFIG} xtables --variable=xtlibdir)
HAVE_LIBBSD := $(usex libbsd y n)
EOF
}
src_compile() {
emake V=1 NETNS_RUN_DIR=/run/netns
}
src_test() {
emake check
}
src_install() {
if use minimal ; then
into /
dosbin tc/tc
dobin ip/ip
return 0
fi
emake \
DESTDIR="${D}" \
PREFIX="${EPREFIX}/usr" \
LIBDIR="${EPREFIX}"/$(get_libdir) \
SBINDIR="${EPREFIX}"/sbin \
CONFDIR="${EPREFIX}"/etc/iproute2 \
DOCDIR="${EPREFIX}"/usr/share/doc/${PF} \
MANDIR="${EPREFIX}"/usr/share/man \
ARPDDIR="${EPREFIX}"/var/lib/arpd \
install
dodir /bin
mv "${ED}"/{s,}bin/ip || die # bug #330115
dolib.a lib/libnetlink.a
insinto /usr/include
doins include/libnetlink.h
# Collides with net-analyzer/ifstat
# https://bugs.gentoo.org/868321
mv "${ED}"/sbin/ifstat{,-iproute2} || die
if use split-usr ; then
# Can remove compatibility symlink in a year: 2023-05-28.
# bug #547264
mv "${ED}"/sbin/ss "${ED}"/bin/ss || die
dosym -r /bin/ss /sbin/ss
fi
if use berkdb ; then
keepdir /var/lib/arpd
# bug #47482, arpd doesn't need to be in /sbin
dodir /usr/bin
mv "${ED}"/sbin/arpd "${ED}"/usr/bin/ || die
elif [[ -d "${ED}"/var/lib/arpd ]]; then
rmdir --ignore-fail-on-non-empty -p "${ED}"/var/lib/arpd || die
fi
}

View File

@ -0,0 +1,220 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit edo toolchain-funcs
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/net/${PN}/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
fi
DESCRIPTION="kernel routing and traffic control utilities"
HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2"
LICENSE="GPL-2"
SLOT="0"
IUSE="atm berkdb bpf caps elf +iptables libbsd minimal nfs selinux split-usr"
# Needs root
RESTRICT="test"
# We could make libmnl optional, but it's tiny, so eh
RDEPEND="
!net-misc/arpd
!minimal? ( net-libs/libmnl:= )
atm? ( net-dialup/linux-atm )
berkdb? ( sys-libs/db:= )
bpf? ( dev-libs/libbpf:= )
caps? ( sys-libs/libcap )
elf? ( virtual/libelf:= )
iptables? ( >=net-firewall/iptables-1.4.20:= )
libbsd? ( dev-libs/libbsd )
nfs? ( net-libs/libtirpc:= )
selinux? ( sys-libs/libselinux )
"
# We require newer linux-headers for ipset support (bug #549948) and some defines (bug #553876)
DEPEND="
${RDEPEND}
>=sys-kernel/linux-headers-3.16
"
BDEPEND="
app-arch/xz-utils
>=sys-devel/bison-2.4
sys-devel/flex
virtual/pkgconfig
"
PATCHES=(
"${FILESDIR}"/${PN}-3.1.0-mtu.patch # bug #291907
"${FILESDIR}"/${PN}-5.12.0-configure-nomagic.patch # bug #643722
#"${FILESDIR}"/${PN}-5.1.0-portability.patch
"${FILESDIR}"/${PN}-5.7.0-mix-signal.h-include.patch
)
src_prepare() {
default
# Fix version if necessary
local versionfile="include/version.h"
if [[ ${PV} != 9999 ]] && ! grep -Fq "${PV}" ${versionfile} ; then
einfo "Fixing version string"
sed "s@\"[[:digit:]\.]\+\"@\"${PV}\"@" \
-i ${versionfile} || die
fi
# echo -n is not POSIX compliant
sed 's@echo -n@printf@' -i configure || die
sed -i \
-e '/^CC :\?=/d' \
-e "/^LIBDIR/s:=.*:=/$(get_libdir):" \
-e "s|-O2|${CFLAGS} ${CPPFLAGS}|" \
-e "/^HOSTCC/s:=.*:= $(tc-getBUILD_CC):" \
-e "/^DBM_INCLUDE/s:=.*:=${T}:" \
Makefile || die
# Build against system headers
rm -r include/netinet || die #include/linux include/ip{,6}tables{,_common}.h include/libiptc
sed -i 's:TCPI_OPT_ECN_SEEN:16:' misc/ss.c || die
if use minimal ; then
sed -i -e '/^SUBDIRS=/s:=.*:=lib tc ip:' Makefile || die
fi
}
src_configure() {
tc-export AR CC PKG_CONFIG
# This sure is ugly. Should probably move into toolchain-funcs at some point.
local setns
pushd "${T}" >/dev/null || die
printf '#include <sched.h>\nint main(){return setns(0, 0);}\n' > test.c || die
if ${CC} ${CFLAGS} ${CPPFLAGS} -D_GNU_SOURCE ${LDFLAGS} test.c >&/dev/null ; then
setns=y
else
setns=n
fi
echo 'int main(){return 0;}' > test.c || die
if ! ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.c -lresolv >&/dev/null ; then
sed -i '/^LDLIBS/s:-lresolv::' "${S}"/Makefile || die
fi
popd >/dev/null || die
# run "configure" script first which will create "config.mk"...
# Using econf breaks since 5.14.0 (a9c3d70d902a0473ee5c13336317006a52ce8242)
edo ./configure --libbpf_force $(usex bpf on off)
# Remove the definitions made by configure and allow them to be overridden
# by USE flags below.
# We have to do the cheesy only-sed-if-disabled because otherwise
# the *_FLAGS etc stuff found by configure will be used but result
# in a broken build.
if ! use berkdb ; then
sed -i -e '/HAVE_BERKELEY_DB/d' config.mk || die
fi
if ! use caps ; then
sed -i -e '/HAVE_CAP/d' config.mk || die
fi
if use minimal ; then
sed -i -e '/HAVE_MNL/d' config.mk || die
fi
if ! use elf ; then
sed -i -e '/HAVE_ELF/d' config.mk || die
fi
if ! use nfs ; then
sed -i -e '/HAVE_RPC/d' config.mk || die
fi
if ! use selinux ; then
sed -i -e '/HAVE_SELINUX/d' config.mk || die
fi
if ! use libbsd ; then
sed -i -e '/HAVE_LIBBSD/d' config.mk || die
fi
# ...Now switch on/off requested features via USE flags
# this is only useful if the test did not set other things, per bug #643722
# Keep in sync with ifs above, or refactor to be unified.
cat <<-EOF >> config.mk
TC_CONFIG_ATM := $(usex atm y n)
TC_CONFIG_XT := $(usex iptables y n)
TC_CONFIG_NO_XT := $(usex iptables n y)
# We've locked in recent enough kernel headers, bug #549948
TC_CONFIG_IPSET := y
HAVE_BERKELEY_DB := $(usex berkdb y n)
HAVE_CAP := $(usex caps y n)
HAVE_MNL := $(usex minimal n y)
HAVE_ELF := $(usex elf y n)
HAVE_RPC := $(usex nfs y n)
HAVE_SELINUX := $(usex selinux y n)
IP_CONFIG_SETNS := ${setns}
# Use correct iptables dir, bug #144265, bug #293709
IPT_LIB_DIR := $(use iptables && ${PKG_CONFIG} xtables --variable=xtlibdir)
HAVE_LIBBSD := $(usex libbsd y n)
EOF
}
src_compile() {
emake V=1 NETNS_RUN_DIR=/run/netns
}
src_test() {
emake check
}
src_install() {
if use minimal ; then
into /
dosbin tc/tc
dobin ip/ip
return 0
fi
emake \
DESTDIR="${D}" \
PREFIX="${EPREFIX}/usr" \
LIBDIR="${EPREFIX}"/$(get_libdir) \
SBINDIR="${EPREFIX}"/sbin \
CONFDIR="${EPREFIX}"/etc/iproute2 \
DOCDIR="${EPREFIX}"/usr/share/doc/${PF} \
MANDIR="${EPREFIX}"/usr/share/man \
ARPDDIR="${EPREFIX}"/var/lib/arpd \
install
dodir /bin
mv "${ED}"/{s,}bin/ip || die # bug #330115
dolib.a lib/libnetlink.a
insinto /usr/include
doins include/libnetlink.h
# Collides with net-analyzer/ifstat
# https://bugs.gentoo.org/868321
mv "${ED}"/sbin/ifstat{,-iproute2} || die
if use split-usr ; then
# Can remove compatibility symlink in a year: 2023-05-28.
# bug #547264
mv "${ED}"/sbin/ss "${ED}"/bin/ss || die
dosym -r /bin/ss /sbin/ss
fi
if use berkdb ; then
keepdir /var/lib/arpd
# bug #47482, arpd doesn't need to be in /sbin
dodir /usr/bin
mv "${ED}"/sbin/arpd "${ED}"/usr/bin/ || die
elif [[ -d "${ED}"/var/lib/arpd ]]; then
rmdir --ignore-fail-on-non-empty -p "${ED}"/var/lib/arpd || die
fi
}

View File

@ -1,16 +1,16 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
inherit toolchain-funcs flag-o-matic multilib
inherit edo toolchain-funcs
if [[ ${PV} == "9999" ]] ; then
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/net/${PN}/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
fi
DESCRIPTION="kernel routing and traffic control utilities"
@ -18,7 +18,9 @@ HOMEPAGE="https://wiki.linuxfoundation.org/networking/iproute2"
LICENSE="GPL-2"
SLOT="0"
IUSE="atm berkdb bpf caps elf +iptables ipv6 libbsd minimal selinux"
IUSE="atm berkdb bpf caps elf +iptables libbsd minimal nfs selinux split-usr"
# Needs root
RESTRICT="test"
# We could make libmnl optional, but it's tiny, so eh
RDEPEND="
@ -31,9 +33,10 @@ RDEPEND="
elf? ( virtual/libelf:= )
iptables? ( >=net-firewall/iptables-1.4.20:= )
libbsd? ( dev-libs/libbsd )
nfs? ( net-libs/libtirpc:= )
selinux? ( sys-libs/libselinux )
"
# We require newer linux-headers for ipset support #549948 and some defines #553876
# We require newer linux-headers for ipset support (bug #549948) and some defines (bug #553876)
DEPEND="
${RDEPEND}
>=sys-kernel/linux-headers-3.16
@ -46,29 +49,18 @@ BDEPEND="
"
PATCHES=(
"${FILESDIR}"/${PN}-3.1.0-mtu.patch #291907
"${FILESDIR}"/${PN}-5.12.0-configure-nomagic.patch # bug 643722
"${FILESDIR}"/${PN}-3.1.0-mtu.patch # bug #291907
"${FILESDIR}"/${PN}-5.12.0-configure-nomagic.patch # bug #643722
#"${FILESDIR}"/${PN}-5.1.0-portability.patch
"${FILESDIR}"/${PN}-5.7.0-mix-signal.h-include.patch
)
doecho() {
echo "${@}"
"${@}" || die
}
src_prepare() {
if ! use ipv6 ; then
PATCHES+=(
"${FILESDIR}"/${PN}-4.20.0-no-ipv6.patch #326849
)
fi
default
# Fix version if necessary
local versionfile="include/version.h"
if [[ "${PV}" != 9999 ]] && ! grep -Fq "${PV}" ${versionfile} ; then
if [[ ${PV} != 9999 ]] && ! grep -Fq "${PV}" ${versionfile} ; then
einfo "Fixing version string"
sed "s@\"[[:digit:]\.]\+\"@\"${PV}\"@" \
-i ${versionfile} || die
@ -85,7 +77,7 @@ src_prepare() {
-e "/^DBM_INCLUDE/s:=.*:=${T}:" \
Makefile || die
# build against system headers
# Build against system headers
rm -r include/netinet || die #include/linux include/ip{,6}tables{,_common}.h include/libiptc
sed -i 's:TCPI_OPT_ECN_SEEN:16:' misc/ss.c || die
@ -99,32 +91,74 @@ src_configure() {
# This sure is ugly. Should probably move into toolchain-funcs at some point.
local setns
pushd "${T}" >/dev/null
printf '#include <sched.h>\nint main(){return setns(0, 0);}\n' > test.c
${CC} ${CFLAGS} ${CPPFLAGS} -D_GNU_SOURCE ${LDFLAGS} test.c >&/dev/null && setns=y || setns=n
echo 'int main(){return 0;}' > test.c
${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.c -lresolv >&/dev/null || sed -i '/^LDLIBS/s:-lresolv::' "${S}"/Makefile
popd >/dev/null
pushd "${T}" >/dev/null || die
printf '#include <sched.h>\nint main(){return setns(0, 0);}\n' > test.c || die
if ${CC} ${CFLAGS} ${CPPFLAGS} -D_GNU_SOURCE ${LDFLAGS} test.c >&/dev/null ; then
setns=y
else
setns=n
fi
echo 'int main(){return 0;}' > test.c || die
if ! ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.c -lresolv >&/dev/null ; then
sed -i '/^LDLIBS/s:-lresolv::' "${S}"/Makefile || die
fi
popd >/dev/null || die
# run "configure" script first which will create "config.mk"...
# Using econf breaks since 5.14.0 (a9c3d70d902a0473ee5c13336317006a52ce8242)
doecho ./configure --libbpf_force $(usex bpf on off)
edo ./configure --libbpf_force $(usex bpf on off)
# ...now switch on/off requested features via USE flags
# Remove the definitions made by configure and allow them to be overridden
# by USE flags below.
# We have to do the cheesy only-sed-if-disabled because otherwise
# the *_FLAGS etc stuff found by configure will be used but result
# in a broken build.
if ! use berkdb ; then
sed -i -e '/HAVE_BERKELEY_DB/d' config.mk || die
fi
if ! use caps ; then
sed -i -e '/HAVE_CAP/d' config.mk || die
fi
if use minimal ; then
sed -i -e '/HAVE_MNL/d' config.mk || die
fi
if ! use elf ; then
sed -i -e '/HAVE_ELF/d' config.mk || die
fi
if ! use nfs ; then
sed -i -e '/HAVE_RPC/d' config.mk || die
fi
if ! use selinux ; then
sed -i -e '/HAVE_SELINUX/d' config.mk || die
fi
if ! use libbsd ; then
sed -i -e '/HAVE_LIBBSD/d' config.mk || die
fi
# ...Now switch on/off requested features via USE flags
# this is only useful if the test did not set other things, per bug #643722
# Keep in sync with ifs above, or refactor to be unified.
cat <<-EOF >> config.mk
TC_CONFIG_ATM := $(usex atm y n)
TC_CONFIG_XT := $(usex iptables y n)
TC_CONFIG_NO_XT := $(usex iptables n y)
# We've locked in recent enough kernel headers #549948
# We've locked in recent enough kernel headers, bug #549948
TC_CONFIG_IPSET := y
HAVE_BERKELEY_DB := $(usex berkdb y n)
HAVE_CAP := $(usex caps y n)
HAVE_MNL := $(usex minimal n y)
HAVE_ELF := $(usex elf y n)
HAVE_RPC := $(usex nfs y n)
HAVE_SELINUX := $(usex selinux y n)
IP_CONFIG_SETNS := ${setns}
# Use correct iptables dir, #144265 #293709
# Use correct iptables dir, bug #144265, bug #293709
IPT_LIB_DIR := $(use iptables && ${PKG_CONFIG} xtables --variable=xtlibdir)
HAVE_LIBBSD := $(usex libbsd y n)
EOF
@ -134,6 +168,10 @@ src_compile() {
emake V=1 NETNS_RUN_DIR=/run/netns
}
src_test() {
emake check
}
src_install() {
if use minimal ; then
into /
@ -154,19 +192,26 @@ src_install() {
install
dodir /bin
mv "${ED}"/{s,}bin/ip || die #330115
mv "${ED}"/{s,}bin/ip || die # bug #330115
dolib.a lib/libnetlink.a
insinto /usr/include
doins include/libnetlink.h
# This local header pulls in a lot of linux headers it
# doesn't directly need. Delete this header that requires
# linux-headers-3.8 until that goes stable. #467716
sed -i '/linux\/netconf.h/d' "${ED}"/usr/include/libnetlink.h || die
# Collides with net-analyzer/ifstat
# https://bugs.gentoo.org/868321
mv "${ED}"/sbin/ifstat{,-iproute2} || die
if use split-usr ; then
# Can remove compatibility symlink in a year: 2023-05-28.
# bug #547264
mv "${ED}"/sbin/ss "${ED}"/bin/ss || die
dosym -r /bin/ss /sbin/ss
fi
if use berkdb ; then
keepdir /var/lib/arpd
# bug 47482, arpd doesn't need to be in /sbin
# bug #47482, arpd doesn't need to be in /sbin
dodir /usr/bin
mv "${ED}"/sbin/arpd "${ED}"/usr/bin/ || die
elif [[ -d "${ED}"/var/lib/arpd ]]; then

View File

@ -12,8 +12,10 @@
<flag name="iptables">include support for iptables filtering</flag>
<flag name="libbsd">Use <pkg>dev-libs/libbsd</pkg> instead of internal funcs</flag>
<flag name="minimal">only install ip and tc programs, without eBPF support</flag>
<flag name="nfs">Support RPC lookups via <pkg>net-libs/libtirpc</pkg> in ss</flag>
</use>
<upstream>
<remote-id type="cpe">cpe:/a:iproute2_project:iproute2</remote-id>
<remote-id type="github">shemminger/iproute2</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1 +1 @@
DIST kbd-2.4.0.tar.xz 1120700 BLAKE2B aa5fc1067d3414b9fa18f35dd81dcc050cdf10bd8692221b6e5304e94c4f90055386ce1f79d2bd092241f9ce15ffd36d5c00d1a15725166d16183f475be4a2e3 SHA512 c3823e40878ed4cb5b90edf753dba37a7fc3189b7b08a2e59a7830cac23a7a7daf31dedef1fcc130698c7508bc2a037c8ab54e749d0cdbf51756e346f2ed5abb
DIST kbd-2.5.1.tar.xz 1491952 BLAKE2B aab4c3d78c28709bf562b54fe94c0533d5c33185e183bf3eb944f89147b250d9df9b30b64a06eb4742feafe8c05a6aa491a7f007b4d6d9077bc19a4628ba05ae SHA512 74855f486aff5fc2f93a6cb29460a590c94eac653b001574e1b4eb1300ea99dfed9222f9e5d1d3a05a112a6880591d5c44ed6e76b8a64edf744ecb0892f562d0

View File

@ -0,0 +1,83 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
if [[ ${PV} == 9999 ]] ; then
inherit autotools git-r3
EGIT_REPO_URI="https://github.com/legionus/kbd.git https://git.kernel.org/pub/scm/linux/kernel/git/legion/kbd.git"
EGIT_BRANCH="master"
else
if [[ $(ver_cut 3) -lt 90 ]] ; then
SRC_URI="https://www.kernel.org/pub/linux/utils/kbd/${P}.tar.xz"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
else
inherit autotools
SRC_URI="https://github.com/legionus/kbd/archive/v${PV}.tar.gz -> ${P}.tar.gz"
fi
fi
DESCRIPTION="Keyboard and console utilities"
HOMEPAGE="https://kbd-project.org/"
LICENSE="GPL-2"
SLOT="0"
IUSE="nls pam test"
RESTRICT="!test? ( test )"
# Testsuite's Makefile.am calls missing(!)
# ... but this seems to be consistent with the autoconf docs?
# Needs more investigation: https://www.gnu.org/software/autoconf/manual/autoconf-2.67/html_node/autom4te-Invocation.html
QA_AM_MAINTAINER_MODE=".*--run autom4te --language=autotest.*"
RDEPEND="
app-arch/gzip
pam? (
!app-misc/vlock
sys-libs/pam
)
"
DEPEND="${RDEPEND}"
BDEPEND="
virtual/pkgconfig
test? ( dev-libs/check )
"
src_prepare() {
default
# Rename conflicting keymaps to have unique names, bug #293228
# See also https://github.com/legionus/kbd/issues/76.
pushd "${S}"/data/keymaps/i386 &> /dev/null || die
mv fgGIod/trf.map fgGIod/trf-fgGIod.map || die
mv olpc/es.map olpc/es-olpc.map || die
mv olpc/pt.map olpc/pt-olpc.map || die
mv qwerty/cz.map qwerty/cz-qwerty.map || die
popd &> /dev/null || die
if [[ ${PV} == 9999 ]] || [[ $(ver_cut 3) -ge 90 ]] ; then
eautoreconf
fi
}
src_configure() {
local myeconfargs=(
--disable-werror
$(use_enable nls)
$(use_enable pam vlock)
$(use_enable test tests)
)
econf "${myeconfargs[@]}"
}
src_install() {
default
docinto html
dodoc docs/doc/*.html
# USE="test" installs .la files
find "${ED}" -type f -name "*.la" -delete || die
}

View File

@ -1,17 +1,16 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
if [[ ${PV} == "9999" ]] ; then
if [[ ${PV} == 9999 ]] ; then
inherit autotools git-r3
#EGIT_REPO_URI="https://git.kernel.org/pub/scm/linux/kernel/git/legion/kbd.git"
EGIT_REPO_URI="https://github.com/legionus/kbd.git"
EGIT_REPO_URI="https://github.com/legionus/kbd.git https://git.kernel.org/pub/scm/linux/kernel/git/legion/kbd.git"
EGIT_BRANCH="master"
else
if [[ $(ver_cut 3) -lt 90 ]] ; then
SRC_URI="https://www.kernel.org/pub/linux/utils/kbd/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
else
inherit autotools
SRC_URI="https://github.com/legionus/kbd/archive/v${PV}.tar.gz -> ${P}.tar.gz"
@ -19,14 +18,17 @@ else
fi
DESCRIPTION="Keyboard and console utilities"
HOMEPAGE="http://kbd-project.org/"
HOMEPAGE="https://kbd-project.org/"
LICENSE="GPL-2"
SLOT="0"
IUSE="nls pam test"
#RESTRICT="!test? ( test )"
# Upstream has strange assumptions how to run tests (see bug #732868)
RESTRICT="test"
RESTRICT="!test? ( test )"
# Testsuite's Makefile.am calls missing(!)
# ... but this seems to be consistent with the autoconf docs?
# Needs more investigation: https://www.gnu.org/software/autoconf/manual/autoconf-2.67/html_node/autom4te-Invocation.html
QA_AM_MAINTAINER_MODE=".*--run autom4te --language=autotest.*"
RDEPEND="
app-arch/gzip
@ -41,41 +43,38 @@ BDEPEND="
test? ( dev-libs/check )
"
src_unpack() {
if [[ ${PV} == "9999" ]] ; then
git-r3_src_unpack
else
src_prepare() {
default
fi
# Rename conflicting keymaps to have unique names, bug #293228
cd "${S}"/data/keymaps/i386 || die
# See also https://github.com/legionus/kbd/issues/76.
pushd "${S}"/data/keymaps/i386 &> /dev/null || die
mv fgGIod/trf.map fgGIod/trf-fgGIod.map || die
mv olpc/es.map olpc/es-olpc.map || die
mv olpc/pt.map olpc/pt-olpc.map || die
mv qwerty/cz.map qwerty/cz-qwerty.map || die
}
popd &> /dev/null || die
src_prepare() {
default
if [[ ${PV} == "9999" ]] || [[ $(ver_cut 3) -ge 90 ]] ; then
if [[ ${PV} == 9999 ]] || [[ $(ver_cut 3) -ge 90 ]] ; then
eautoreconf
fi
}
src_configure() {
local myeconfargs=(
# USE="test" installs .a files
--disable-static
--disable-werror
$(use_enable nls)
$(use_enable pam vlock)
$(use_enable test tests)
)
econf "${myeconfargs[@]}"
}
src_install() {
default
docinto html
dodoc docs/doc/*.html

View File

@ -6,6 +6,6 @@
<name>Gentoo Base System</name>
</maintainer>
<upstream>
<remote-id type="freshmeat">kbd</remote-id>
<remote-id type="github">legionus/kbd</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1,2 +1,2 @@
DIST kexec-tools-2.0.22.tar.xz 303564 BLAKE2B 977c741eabf9b6b882550713ba59b18289b4f997fb382e96338efce6d04a9390fea952fc46ca72fd0a0b782261841ab2002da84b1819f955e63996eac900b0f7 SHA512 7580860f272eee5af52139809f12961e5a5d3a65f4e191183ca9c845410425d25818945ac14ed04a60e6ce474dc2656fc6a14041177b0bf703f450820c7d6aba
DIST kexec-tools-2.0.23.tar.xz 304024 BLAKE2B 0150985093dc0012d3870c127ac5eab81d4cc839c0a79ff20224d1a409462a194d7e304f54ed8f0952e4d325dbff11bcbe1565b2c57c45c212302810dc06ed62 SHA512 b6e3b967cacc31c434b185d25da4d53c822ae4bbcec26ef9d6cb171f294fdcc80913d381e686a0a41e025187835f4dc088052ff88efe75a021d7624c8b1a1ed8
DIST kexec-tools-2.0.24.tar.xz 303808 BLAKE2B 8188602f1b843c1dccc0307131f8c9ec0426c6cb3de898040352c1fed5f6d4bd7c58a0c2bf54290b91c8fe3401180df682959ee6c41693d07acc199c087c7db2 SHA512 ef7cf78246e2d729d81a3649791a5a23c385353cc75cbe8ef279616329fdaccc876d614c7f51e1456822a13a11520296070d9897467d24310399909e049c3822

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -114,7 +114,7 @@ pkg_postinst() {
fi
fi
if [[ ${n_root_args} > 1 && "${has_rootpart_set}" == "no" ]]; then
if [[ ${n_root_args} -gt 1 && "${has_rootpart_set}" == "no" ]]; then
ewarn "WARNING: Multiple root arguments (root=) on kernel command-line detected!"
ewarn "This was probably caused by a previous version of ${PN}."
ewarn "Please reboot system once *without* kexec to avoid boot problems"

View File

@ -0,0 +1,124 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit libtool linux-info systemd
if [[ ${PV} == "9999" ]] ; then
inherit git-r3 autotools
EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git"
else
SRC_URI="https://www.kernel.org/pub/linux/utils/kernel/kexec/${P/_/-}.tar.xz"
[[ "${PV}" == *_rc* ]] || \
KEYWORDS="amd64 ~arm64 ~ppc64 x86"
fi
DESCRIPTION="Load another kernel from the currently executing Linux kernel"
HOMEPAGE="https://kernel.org/pub/linux/utils/kernel/kexec/"
LICENSE="GPL-2"
SLOT="0"
IUSE="booke lzma xen zlib"
REQUIRED_USE="lzma? ( zlib )"
DEPEND="
lzma? ( app-arch/xz-utils )
zlib? ( sys-libs/zlib )"
RDEPEND="${DEPEND}"
S="${WORKDIR}/${P/_/-}"
CONFIG_CHECK="~KEXEC"
PATCHES=(
"${FILESDIR}"/${PN}-2.0.4-disable-kexec-test.patch
"${FILESDIR}"/${PN}-2.0.4-out-of-source.patch
)
pkg_setup() {
# GNU Make's $(COMPILE.S) passes ASFLAGS to $(CCAS), CCAS=$(CC)
export ASFLAGS="${CCASFLAGS}"
}
src_prepare() {
default
# Append PURGATORY_EXTRA_CFLAGS flags set by configure, instead of overriding them completely.
sed -e "/^PURGATORY_EXTRA_CFLAGS =/s/=/+=/" -i Makefile.in || die
if [[ "${PV}" == 9999 ]] ; then
eautoreconf
else
elibtoolize
fi
}
src_configure() {
local myeconfargs=(
$(use_with booke)
$(use_with lzma)
$(use_with xen)
$(use_with zlib)
)
econf "${myeconfargs[@]}"
}
src_compile() {
# Respect CFLAGS for purgatory.
# purgatory/Makefile uses PURGATORY_EXTRA_CFLAGS variable.
# -mfunction-return=thunk and -mindirect-branch=thunk conflict with
# -mcmodel=large which is added by build system.
# Replace them with -mfunction-return=thunk-inline and -mindirect-branch=thunk-inline.
local flag flags=()
for flag in ${CFLAGS}; do
[[ ${flag} == -mfunction-return=thunk ]] && flag="-mfunction-return=thunk-inline"
[[ ${flag} == -mindirect-branch=thunk ]] && flag="-mindirect-branch=thunk-inline"
flags+=("${flag}")
done
local -x PURGATORY_EXTRA_CFLAGS="${flags[*]}"
default
}
src_install() {
default
dodoc "${FILESDIR}"/README.Gentoo
newinitd "${FILESDIR}"/kexec-r2.init kexec
newconfd "${FILESDIR}"/kexec.conf-2.0.4 kexec
insinto /etc
doins "${FILESDIR}"/kexec.conf
insinto /etc/kernel/postinst.d
doins "${FILESDIR}"/90_kexec
systemd_dounit "${FILESDIR}"/kexec.service
}
pkg_postinst() {
if systemd_is_booted || has_version sys-apps/systemd; then
elog "For systemd support the new config file is"
elog " /etc/kexec.conf"
elog "Please adopt it to your needs as there is no autoconfig anymore"
fi
local n_root_args=$(grep -o -- '\<root=' /proc/cmdline 2>/dev/null | wc -l)
local has_rootpart_set=no
if [[ -f "${EROOT}/etc/conf.d/kexec" ]]; then
if grep -q -E -- '^ROOTPART=' "${EROOT}/etc/conf.d/kexec" 2>/dev/null; then
has_rootpart_set=yes
fi
fi
if [[ ${n_root_args} -gt 1 && "${has_rootpart_set}" == "no" ]]; then
ewarn "WARNING: Multiple root arguments (root=) on kernel command-line detected!"
ewarn "This was probably caused by a previous version of ${PN}."
ewarn "Please reboot system once *without* kexec to avoid boot problems"
ewarn "in case running system and initramfs do not agree on detected"
ewarn "root device name!"
fi
}

View File

@ -1,4 +1,4 @@
# Copyright 1999-2020 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -114,7 +114,7 @@ pkg_postinst() {
fi
fi
if [[ ${n_root_args} > 1 && "${has_rootpart_set}" == "no" ]]; then
if [[ ${n_root_args} -gt 1 && "${has_rootpart_set}" == "no" ]]; then
ewarn "WARNING: Multiple root arguments (root=) on kernel command-line detected!"
ewarn "This was probably caused by a previous version of ${PN}."
ewarn "Please reboot system once *without* kexec to avoid boot problems"

View File

@ -10,4 +10,7 @@
<flag name="booke">Include support for Book-E memory management</flag>
<flag name="xen">Enable extended xen support</flag>
</use>
<upstream>
<remote-id type="cpe">cpe:/a:kernel:kexec-tools</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1 +1 @@
DIST kmod-29.tar.xz 560160 BLAKE2B 1362b6e7c07f66594074f07239d0f7a64e6efeb928483ed027b22a4ac77b916c631d1c03780b0515714a87847a716c35341edb1ced04a1795b4c7f8942d3207a SHA512 557cdcaec75e5a1ceea2d10862c944e9a65ef54f6ee9da6dc98ce4582418fdc9958aab2e14a84807db61daf36ec4fcdc23a36376c39d5dc31d1823ca7cd47998
DIST kmod-30.tar.xz 567484 BLAKE2B c5cb690dbb8fad66ac603648ff330794b417ff2fa2f8f61b6e9cb76dab93f984128b3d83a826203f39f3fb94f174f0db7395db6a47e52e8b7c561486f9d00778 SHA512 e2cd34e600a72e44710760dfda9364b790b8352a99eafbd43e683e4a06f37e6b5c0b5d14e7c28070e30fc5fc6ceddedf7b97f3b6c2c5c2d91204fefd630b9a3e

View File

@ -0,0 +1,26 @@
https://github.com/kmod-project/kmod/commit/035e6667d1ace2fd77ef36f5e5d93cd4b1e128a2
From 035e6667d1ace2fd77ef36f5e5d93cd4b1e128a2 Mon Sep 17 00:00:00 2001
From: Florian Weimer <fweimer@redhat.com>
Date: Sat, 17 Dec 2022 17:52:34 +0100
Subject: [PATCH] kmod: configure.ac: In _Noreturn check, include <stdlib.h>
for exit
Otherwise, an implicit functiona declaration is used, causing
a C99 compatibility issue.
Signed-off-by: Florian Weimer <fweimer@redhat.com>
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
--- a/configure.ac
+++ b/configure.ac
@@ -68,7 +68,8 @@ AC_COMPILE_IFELSE(
AC_MSG_CHECKING([whether _Noreturn is supported])
AC_COMPILE_IFELSE(
- [AC_LANG_SOURCE([[_Noreturn int foo(void) { exit(0); }]])],
+ [AC_LANG_SOURCE([[#include <stdlib.h>
+ _Noreturn int foo(void) { exit(0); }]])],
[AC_DEFINE([HAVE_NORETURN], [1], [Define if _Noreturn is available])
AC_MSG_RESULT([yes])],
[AC_MSG_RESULT([no])])

View File

@ -0,0 +1,231 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{9..11} )
inherit autotools libtool bash-completion-r1 python-r1
if [[ ${PV} == 9999* ]]; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/kernel/${PN}/${PN}.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/kernel/kmod/${P}.tar.xz"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
fi
DESCRIPTION="library and tools for managing linux kernel modules"
HOMEPAGE="https://git.kernel.org/?p=utils/kernel/kmod/kmod.git"
LICENSE="LGPL-2"
SLOT="0"
IUSE="debug doc +lzma pkcs7 python static-libs +tools +zlib +zstd"
# Upstream does not support running the test suite with custom configure flags.
# I was also told that the test suite is intended for kmod developers.
# So we have to restrict it.
# See bug #408915.
#RESTRICT="test"
# - >=zlib-1.2.6 required because of bug #427130
# - Block systemd below 217 for -static-nodes-indicate-that-creation-of-static-nodes-.patch
# - >=zstd-1.5.2-r1 required for bug #771078
RDEPEND="!sys-apps/module-init-tools
!sys-apps/modutils
!<sys-apps/openrc-0.13.8
!<sys-apps/systemd-216-r3
lzma? ( >=app-arch/xz-utils-5.0.4-r1 )
python? ( ${PYTHON_DEPS} )
pkcs7? ( >=dev-libs/openssl-1.1.0:= )
zlib? ( >=sys-libs/zlib-1.2.6 )
zstd? ( >=app-arch/zstd-1.5.2-r1:= )"
DEPEND="${RDEPEND}"
BDEPEND="
doc? (
dev-util/gtk-doc
dev-util/gtk-doc-am
)
lzma? ( virtual/pkgconfig )
python? (
dev-python/cython[${PYTHON_USEDEP}]
virtual/pkgconfig
)
zlib? ( virtual/pkgconfig )
"
if [[ ${PV} == 9999* ]]; then
BDEPEND="${BDEPEND}
dev-libs/libxslt"
fi
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
DOCS=( NEWS README.md TODO )
PATCHES=(
"${FILESDIR}"/${P}-configure-clang16.patch
)
src_prepare() {
default
if [[ ! -e configure ]] || use doc ; then
if use doc; then
cp "${BROOT}"/usr/share/aclocal/gtk-doc.m4 m4 || die
gtkdocize --copy --docdir libkmod/docs || die
else
touch libkmod/docs/gtk-doc.make
fi
eautoreconf
else
#elibtoolize
# TODO: restore to elibtoolize in next release after 30
# autoreconf only here for clang patch.
eautoreconf
fi
# Restore possibility of running --enable-static, bug #472608
sed -i \
-e '/--enable-static is not supported by kmod/s:as_fn_error:echo:' \
configure || die
}
src_configure() {
local myeconfargs=(
--bindir="${EPREFIX}/bin"
--enable-shared
--with-bashcompletiondir="$(get_bashcompdir)"
--with-rootlibdir="${EPREFIX}/$(get_libdir)"
$(use_enable debug)
$(usex doc '--enable-gtk-doc' '')
$(use_enable static-libs static)
$(use_enable tools)
$(use_with lzma xz)
$(use_with pkcs7 openssl)
$(use_with zlib)
$(use_with zstd)
)
local ECONF_SOURCE="${S}"
kmod_configure() {
mkdir -p "${BUILD_DIR}" || die
run_in_build_dir econf "${myeconfargs[@]}" "$@"
}
BUILD_DIR="${WORKDIR}/build"
kmod_configure --disable-python
if use python; then
python_foreach_impl kmod_configure --enable-python
fi
}
src_compile() {
emake -C "${BUILD_DIR}"
if use python; then
local native_builddir="${BUILD_DIR}"
python_compile() {
emake -C "${BUILD_DIR}" -f Makefile -f - python \
VPATH="${native_builddir}:${S}" \
native_builddir="${native_builddir}" \
libkmod_python_kmod_{kmod,list,module,_util}_la_LIBADD='$(PYTHON_LIBS) $(native_builddir)/libkmod/libkmod.la' \
<<< 'python: $(pkgpyexec_LTLIBRARIES)'
}
python_foreach_impl python_compile
fi
}
src_test() {
python_test() {
mkdir "${T}/test-${EPYTHON}" || die
emake -C "${BUILD_DIR}" DESTDIR="${T}/test-${EPYTHON}" \
VPATH="${native_builddir}:${S}" \
install-pkgpyexecLTLIBRARIES \
install-dist_pkgpyexecPYTHON
# Smoke test based on https://bugs.gentoo.org/891975#c5
local -x PYTHONPATH="${T}/test-${EPYTHON}/usr/lib/${EPYTHON}/site-packages:${PYTHONPATH}"
${EPYTHON} -c 'import kmod; km = kmod.Kmod(); print([(m.name, m.size) for m in km.loaded()])' || die
rm -r "${T}/test-${EPYTHON}" || die
}
if use python; then
python_foreach_impl python_test
fi
}
src_install() {
emake -C "${BUILD_DIR}" DESTDIR="${D}" install
einstalldocs
if use python; then
local native_builddir="${BUILD_DIR}"
python_install() {
emake -C "${BUILD_DIR}" DESTDIR="${D}" \
VPATH="${native_builddir}:${S}" \
install-pkgpyexecLTLIBRARIES \
install-dist_pkgpyexecPYTHON
python_optimize
}
python_foreach_impl python_install
fi
find "${ED}" -type f -name "*.la" -delete || die
if use tools; then
local cmd
for cmd in depmod insmod modprobe rmmod; do
dosym ../bin/kmod /sbin/${cmd}
done
# These are also usable as normal user
for cmd in lsmod modinfo; do
dosym kmod /bin/${cmd}
done
fi
cat <<-EOF > "${T}"/usb-load-ehci-first.conf
softdep uhci_hcd pre: ehci_hcd
softdep ohci_hcd pre: ehci_hcd
EOF
insinto /lib/modprobe.d
# bug #260139
doins "${T}"/usb-load-ehci-first.conf
newinitd "${FILESDIR}"/kmod-static-nodes-r1 kmod-static-nodes
}
pkg_postinst() {
if [[ -L ${EROOT}/etc/runlevels/boot/static-nodes ]]; then
ewarn "Removing old conflicting static-nodes init script from the boot runlevel"
rm -f "${EROOT}"/etc/runlevels/boot/static-nodes
fi
# Add kmod to the runlevel automatically if this is the first install of this package.
if [[ -z ${REPLACING_VERSIONS} ]]; then
if [[ ! -d ${EROOT}/etc/runlevels/sysinit ]]; then
mkdir -p "${EROOT}"/etc/runlevels/sysinit
fi
if [[ -x ${EROOT}/etc/init.d/kmod-static-nodes ]]; then
ln -s /etc/init.d/kmod-static-nodes "${EROOT}"/etc/runlevels/sysinit/kmod-static-nodes
fi
fi
if [[ -e ${EROOT}/etc/runlevels/sysinit ]]; then
if ! has_version sys-apps/systemd && [[ ! -e ${EROOT}/etc/runlevels/sysinit/kmod-static-nodes ]]; then
ewarn
ewarn "You need to add kmod-static-nodes to the sysinit runlevel for"
ewarn "kernel modules to have required static nodes!"
ewarn "Run this command:"
ewarn "\trc-update add kmod-static-nodes sysinit"
fi
fi
}

View File

@ -0,0 +1,205 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{9..10} )
inherit autotools libtool bash-completion-r1 python-r1
if [[ ${PV} == 9999* ]]; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/kernel/${PN}/${PN}.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/kernel/kmod/${P}.tar.xz"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
fi
DESCRIPTION="library and tools for managing linux kernel modules"
HOMEPAGE="https://git.kernel.org/?p=utils/kernel/kmod/kmod.git"
LICENSE="LGPL-2"
SLOT="0"
IUSE="debug doc +lzma pkcs7 python static-libs +tools +zlib +zstd"
# Upstream does not support running the test suite with custom configure flags.
# I was also told that the test suite is intended for kmod developers.
# So we have to restrict it.
# See bug #408915.
RESTRICT="test"
# - >=zlib-1.2.6 required because of bug #427130
# - Block systemd below 217 for -static-nodes-indicate-that-creation-of-static-nodes-.patch
# - >=zstd-1.5.2-r1 required for bug #771078
RDEPEND="!sys-apps/module-init-tools
!sys-apps/modutils
!<sys-apps/openrc-0.13.8
!<sys-apps/systemd-216-r3
lzma? ( >=app-arch/xz-utils-5.0.4-r1 )
python? ( ${PYTHON_DEPS} )
pkcs7? ( >=dev-libs/openssl-1.1.0:= )
zlib? ( >=sys-libs/zlib-1.2.6 )
zstd? ( >=app-arch/zstd-1.5.2-r1:= )"
DEPEND="${RDEPEND}"
BDEPEND="
doc? (
dev-util/gtk-doc
dev-util/gtk-doc-am
)
lzma? ( virtual/pkgconfig )
python? (
dev-python/cython[${PYTHON_USEDEP}]
virtual/pkgconfig
)
zlib? ( virtual/pkgconfig )
"
if [[ ${PV} == 9999* ]]; then
BDEPEND="${BDEPEND}
dev-libs/libxslt"
fi
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
DOCS=( NEWS README.md TODO )
src_prepare() {
default
if [[ ! -e configure ]] || use doc ; then
if use doc; then
cp "${BROOT}"/usr/share/aclocal/gtk-doc.m4 m4 || die
gtkdocize --copy --docdir libkmod/docs || die
else
touch libkmod/docs/gtk-doc.make
fi
eautoreconf
else
elibtoolize
fi
# Restore possibility of running --enable-static, bug #472608
sed -i \
-e '/--enable-static is not supported by kmod/s:as_fn_error:echo:' \
configure || die
}
src_configure() {
local myeconfargs=(
--bindir="${EPREFIX}/bin"
--enable-shared
--with-bashcompletiondir="$(get_bashcompdir)"
--with-rootlibdir="${EPREFIX}/$(get_libdir)"
$(use_enable debug)
$(usex doc '--enable-gtk-doc' '')
$(use_enable static-libs static)
$(use_enable tools)
$(use_with lzma xz)
$(use_with pkcs7 openssl)
$(use_with zlib)
$(use_with zstd)
)
local ECONF_SOURCE="${S}"
kmod_configure() {
mkdir -p "${BUILD_DIR}" || die
run_in_build_dir econf "${myeconfargs[@]}" "$@"
}
BUILD_DIR="${WORKDIR}/build"
kmod_configure --disable-python
if use python; then
python_foreach_impl kmod_configure --enable-python
fi
}
src_compile() {
emake -C "${BUILD_DIR}"
if use python; then
local native_builddir="${BUILD_DIR}"
python_compile() {
emake -C "${BUILD_DIR}" -f Makefile -f - python \
VPATH="${native_builddir}:${S}" \
native_builddir="${native_builddir}" \
libkmod_python_kmod_{kmod,list,module,_util}_la_LIBADD='$(PYTHON_LIBS) $(native_builddir)/libkmod/libkmod.la' \
<<< 'python: $(pkgpyexec_LTLIBRARIES)'
}
python_foreach_impl python_compile
fi
}
src_install() {
emake -C "${BUILD_DIR}" DESTDIR="${D}" install
einstalldocs
if use python; then
local native_builddir="${BUILD_DIR}"
python_install() {
emake -C "${BUILD_DIR}" DESTDIR="${D}" \
VPATH="${native_builddir}:${S}" \
install-pkgpyexecLTLIBRARIES \
install-dist_pkgpyexecPYTHON
python_optimize
}
python_foreach_impl python_install
fi
find "${ED}" -type f -name "*.la" -delete || die
if use tools; then
local cmd
for cmd in depmod insmod modprobe rmmod; do
dosym ../bin/kmod /sbin/${cmd}
done
# These are also usable as normal user
for cmd in lsmod modinfo; do
dosym kmod /bin/${cmd}
done
fi
cat <<-EOF > "${T}"/usb-load-ehci-first.conf
softdep uhci_hcd pre: ehci_hcd
softdep ohci_hcd pre: ehci_hcd
EOF
insinto /lib/modprobe.d
# bug #260139
doins "${T}"/usb-load-ehci-first.conf
newinitd "${FILESDIR}"/kmod-static-nodes-r1 kmod-static-nodes
}
pkg_postinst() {
if [[ -L ${EROOT}/etc/runlevels/boot/static-nodes ]]; then
ewarn "Removing old conflicting static-nodes init script from the boot runlevel"
rm -f "${EROOT}"/etc/runlevels/boot/static-nodes
fi
# Add kmod to the runlevel automatically if this is the first install of this package.
if [[ -z ${REPLACING_VERSIONS} ]]; then
if [[ ! -d ${EROOT}/etc/runlevels/sysinit ]]; then
mkdir -p "${EROOT}"/etc/runlevels/sysinit
fi
if [[ -x ${EROOT}/etc/init.d/kmod-static-nodes ]]; then
ln -s /etc/init.d/kmod-static-nodes "${EROOT}"/etc/runlevels/sysinit/kmod-static-nodes
fi
fi
if [[ -e ${EROOT}/etc/runlevels/sysinit ]]; then
if ! has_version sys-apps/systemd && [[ ! -e ${EROOT}/etc/runlevels/sysinit/kmod-static-nodes ]]; then
ewarn
ewarn "You need to add kmod-static-nodes to the sysinit runlevel for"
ewarn "kernel modules to have required static nodes!"
ewarn "Run this command:"
ewarn "\trc-update add kmod-static-nodes sysinit"
fi
fi
}

View File

@ -1,19 +1,18 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
PYTHON_COMPAT=( python3_{7..10} )
PYTHON_COMPAT=( python3_{9..11} )
inherit autotools bash-completion-r1 multilib python-r1
inherit autotools libtool bash-completion-r1 python-r1
if [[ ${PV} == 9999* ]]; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/utils/kernel/${PN}/${PN}.git"
inherit git-r3
else
SRC_URI="https://www.kernel.org/pub/linux/utils/kernel/kmod/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
#inherit libtool
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
fi
DESCRIPTION="library and tools for managing linux kernel modules"
@ -21,25 +20,26 @@ HOMEPAGE="https://git.kernel.org/?p=utils/kernel/kmod/kmod.git"
LICENSE="LGPL-2"
SLOT="0"
IUSE="debug doc +lzma pkcs7 python static-libs +tools +zlib zstd"
IUSE="debug doc +lzma pkcs7 python static-libs +tools +zlib +zstd"
# Upstream does not support running the test suite with custom configure flags.
# I was also told that the test suite is intended for kmod developers.
# So we have to restrict it.
# See bug #408915.
RESTRICT="test"
#RESTRICT="test"
# >=zlib-1.2.6 required because of bug #427130
# Block systemd below 217 for -static-nodes-indicate-that-creation-of-static-nodes-.patch
# - >=zlib-1.2.6 required because of bug #427130
# - Block systemd below 217 for -static-nodes-indicate-that-creation-of-static-nodes-.patch
# - >=zstd-1.5.2-r1 required for bug #771078
RDEPEND="!sys-apps/module-init-tools
!sys-apps/modutils
!<sys-apps/openrc-0.13.8
!<sys-apps/systemd-216-r3
lzma? ( >=app-arch/xz-utils-5.0.4-r1 )
python? ( ${PYTHON_DEPS} )
pkcs7? ( >=dev-libs/openssl-1.1.0:0= )
pkcs7? ( >=dev-libs/openssl-1.1.0:= )
zlib? ( >=sys-libs/zlib-1.2.6 )
zstd? ( >=app-arch/zstd-1.4.4 )"
zstd? ( >=app-arch/zstd-1.5.2-r1:= )"
DEPEND="${RDEPEND}"
BDEPEND="
doc? (
@ -60,7 +60,7 @@ fi
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
DOCS=( NEWS README TODO )
DOCS=( NEWS README.md TODO )
src_prepare() {
default
@ -77,7 +77,7 @@ src_prepare() {
elibtoolize
fi
# Restore possibility of running --enable-static wrt #472608
# Restore possibility of running --enable-static, bug #472608
sed -i \
-e '/--enable-static is not supported by kmod/s:as_fn_error:echo:' \
configure || die
@ -118,7 +118,7 @@ src_compile() {
emake -C "${BUILD_DIR}"
if use python; then
local native_builddir=${BUILD_DIR}
local native_builddir="${BUILD_DIR}"
python_compile() {
emake -C "${BUILD_DIR}" -f Makefile -f - python \
@ -132,12 +132,32 @@ src_compile() {
fi
}
src_test() {
python_test() {
mkdir "${T}/test-${EPYTHON}" || die
emake -C "${BUILD_DIR}" DESTDIR="${T}/test-${EPYTHON}" \
VPATH="${native_builddir}:${S}" \
install-pkgpyexecLTLIBRARIES \
install-dist_pkgpyexecPYTHON
# Smoke test based on https://bugs.gentoo.org/891975#c5
local -x PYTHONPATH="${T}/test-${EPYTHON}/usr/lib/${EPYTHON}/site-packages:${PYTHONPATH}"
${EPYTHON} -c 'import kmod; km = kmod.Kmod(); print([(m.name, m.size) for m in km.loaded()])' || die
rm -r "${T}/test-${EPYTHON}" || die
}
if use python; then
python_foreach_impl python_test
fi
}
src_install() {
emake -C "${BUILD_DIR}" DESTDIR="${D}" install
einstalldocs
if use python; then
local native_builddir=${BUILD_DIR}
local native_builddir="${BUILD_DIR}"
python_install() {
emake -C "${BUILD_DIR}" DESTDIR="${D}" \
@ -170,7 +190,8 @@ src_install() {
EOF
insinto /lib/modprobe.d
doins "${T}"/usb-load-ehci-first.conf #260139
# bug #260139
doins "${T}"/usb-load-ehci-first.conf
newinitd "${FILESDIR}"/kmod-static-nodes-r1 kmod-static-nodes
}

View File

@ -13,5 +13,6 @@
</use>
<upstream>
<remote-id type="cpe">cpe:/a:kernel:kmod</remote-id>
<remote-id type="github">kmod-project/kmod</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1 +1,2 @@
DIST lshw-02.19.2b_p20210121-B.02.19.2_p20210121.tar.gz 2469481 BLAKE2B b9a886c21d6abde00f234cc93fc25ae2b4cf734ffd3fdea7847283fa44eef80bfddd6d83ab428c126ef6518eb8da35f3ba15d88cfc5dbb304813a4d28c173351 SHA512 699ee270eb9a8dd6652d7bcab5d99187585159428bdceab2e17add51e29d73a929a4d34168d92308e775383b9920b07e3b02e0781f9f1b1f099aff3550e9b0c0
DIST lshw-02.19.2b_p20220831-B.02.19.2_p20220831.tar.gz 2482679 BLAKE2B 00cc7512a020e05577d82b6ab528524f929ef51455502eb8d9abbb3a2f75cac25d837a888ecf1e55a9c4251bb6515aedf4586da0c3f2f6b587ff0413acda3865 SHA512 d0ea5706850a07bbc82c627ce25a2774bbda6f565e259136d89774ec5e85770d8c2373ead46f6f7b1586c85aebdf1383b7ae1539b3f2f9d1b33fa777bc5589f5

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -32,6 +32,8 @@ S=${WORKDIR}/${PN}
DOCS=( COPYING README.md docs/{Changelog,TODO,IODC.txt,lshw.xsd,proc_usb_info.txt} )
PATCHES=( "${FILESDIR}"/lshw-02.19.2b-respect-LDFLAGS.patch )
src_prepare() {
default
@ -73,7 +75,7 @@ src_compile() {
src_install() {
emake VERSION=${MY_PV} DESTDIR="${D}" PREFIX="${EPREFIX}/usr" install $(usex gtk 'install-gui' '')
if use gtk ; then
newicon -s scalable src/gui/artwork/logo.svg gtk-lshw.svg
newicon -s scalable src/gui/artwork/logo.svg lshw.svg
make_desktop_entry \
"${EPREFIX}"/usr/sbin/gtk-lshw \
"${DESCRIPTION}"

View File

@ -1,13 +1,13 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
PLOCALES='fr'
PLOCALES="ca es fr"
inherit desktop flag-o-matic plocale toolchain-funcs xdg
MY_COMMIT="fdab06ac0b190ea0aa02cd468f904ed69ce0d9f1"
MY_COMMIT=42fef565731411a784101de614a54bff79d1858e
MY_PV=$(ver_cut 3 PV/b/B).$(ver_cut 1-3)_$(ver_cut 5-6)
DESCRIPTION="Hardware Lister"
@ -16,7 +16,7 @@ SRC_URI="https://ezix.org/src/pkg/lshw/archive/${MY_COMMIT}.tar.gz -> ${P}-${MY_
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux"
KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ppc ppc64 ~riscv sparc x86 ~amd64-linux ~x86-linux"
IUSE="gtk sqlite static"
REQUIRED_USE="static? ( !gtk !sqlite )"
@ -75,7 +75,7 @@ src_compile() {
src_install() {
emake VERSION=${MY_PV} DESTDIR="${D}" PREFIX="${EPREFIX}/usr" install $(usex gtk 'install-gui' '')
if use gtk ; then
newicon -s scalable src/gui/artwork/logo.svg gtk-lshw.svg
newicon -s scalable src/gui/artwork/logo.svg lshw.svg
make_desktop_entry \
"${EPREFIX}"/usr/sbin/gtk-lshw \
"${DESCRIPTION}"

View File

@ -1,7 +1,7 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
EAPI=8
inherit toolchain-funcs
@ -9,22 +9,21 @@ MY_PN="MAKEDEV"
MY_VER=${PV%.*}
MY_REL=${PV#${MY_VER}.}
MY_P="${MY_PN}-${MY_VER}"
DESCRIPTION="program used for creating device files in /dev"
DESCRIPTION="Program used for creating device files in /dev"
HOMEPAGE="https://people.redhat.com/nalin/MAKEDEV/"
SRC_URI="https://people.redhat.com/nalin/MAKEDEV/${MY_P}-${MY_REL}.tar.gz"
S="${WORKDIR}"/${MY_P}
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86"
IUSE="build selinux"
RDEPEND="!<sys-apps/baselayout-2.0.0_rc"
DEPEND=""
S=${WORKDIR}/${MY_P}
PATCHES=(
"${FILESDIR}"/${P}-headers.patch #339674
"${FILESDIR}"/${P}-headers.patch # bug #339674
)
src_compile() {
@ -33,7 +32,7 @@ src_compile() {
}
src_install() {
# set devdir to makedevdir so we dont have to worry about /dev
# set devdir to makedevdir so we don't have to worry about /dev
emake install DESTDIR="${D}" makedevdir=/sbin devdir=/sbin
dodoc *.txt
keepdir /dev
@ -41,10 +40,11 @@ src_install() {
pkg_postinst() {
if use build ; then
# set up a base set of nodes to make recovery easier #368597
# Set up a base set of nodes to make recovery easier, bug #368597
"${ROOT}"/sbin/MAKEDEV -c "${ROOT}"/etc/makedev.d \
-d "${ROOT}"/dev console hda input ptmx std sd tty
# trim useless nodes
# Trim useless nodes
rm -f "${ROOT}"/dev/fd[0-9]* # floppy
rm -f "${ROOT}"/dev/sd[a-d][a-z]* "${ROOT}"/dev/sd[e-z]* # excess sata/scsi
rm -f "${ROOT}"/dev/tty[a-zA-Z]* # excess tty

View File

@ -1,2 +1 @@
DIST man-db-2.10.1.tar.xz 1890536 BLAKE2B b052a7006e1d47dfe7b82f82b6e6e47500ca1c8fa20716af7d3d4193ebde0b109f13f4ed3148c5e4bbc76f34d457ec71bf93ed88f9ab0f5da5b5e1c9066e6d70 SHA512 25a3c4e3d7b171faf0771885a7a7d502c4af801881777231c79d7ee9768c2e48e44afbf5603af13f5ac63e6981cfdb8e36ba8a33d5f926d8122635cf45fcff7a
DIST man-db-2.9.4.tar.xz 1909020 BLAKE2B 43427e851f0e661ca1cee55211dd7636f4ffde067c75de7715f525029b22c205728f8e86ac49abff60e47a4a4c9e1fbd78e2c87e70bd37778b88594a3897275f SHA512 169f091dd0a1d0dbd1583366f8257afb8f57e030d0f7d4213c14ce0b1fc5debf8b9cf2731de503830cb2826b3a22b3cff7da993d44ec18557935bd293529133c
DIST man-db-2.11.2.tar.xz 1953276 BLAKE2B 80ac565cdb69736c0f922b9cbfddcae753d176329781deaf9434d87d7718f9b6ce0b6d4642a03f22a04c7f042dda7f8986b5bce0038f0748461ca55d66964ccc SHA512 edb71cce7249c7b7f2f524e92f682047a77ed9ae8856763dfc8e18e239444651ff4c505e697f5a8b1be3b85678e714fbb1a520defe72a4eb685bc2cecc0e4391

View File

@ -1,30 +0,0 @@
https://gitlab.com/cjwatson/man-db/-/merge_requests/3
libdb: link against libintl
necessary since gettext is used for translations
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
--- a/libdb/Makefile.am
+++ b/libdb/Makefile.am
@@ -43,7 +43,7 @@
db_xdbm.h \
mydbm.h
-libmandb_la_LIBADD = ../lib/libman.la $(DBLIBS)
+libmandb_la_LIBADD = ../lib/libman.la $(DBLIBS) $(LIBINTL)
libmandb_la_LDFLAGS = \
-avoid-version -release $(VERSION) -rpath $(pkglibdir) -no-undefined
--- a/libdb/Makefile.in
+++ b/libdb/Makefile.in
@@ -1541,7 +1541,7 @@
db_xdbm.h \
mydbm.h
-libmandb_la_LIBADD = ../lib/libman.la $(DBLIBS)
+libmandb_la_LIBADD = ../lib/libman.la $(DBLIBS) $(LIBINTL)
libmandb_la_LDFLAGS = \
-avoid-version -release $(VERSION) -rpath $(pkglibdir) -no-undefined

View File

@ -1,30 +1,29 @@
# Copyright 1999-2022 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
inherit systemd prefix tmpfiles
DESCRIPTION="A man replacement that utilizes berkdb instead of flat files"
HOMEPAGE="https://gitlab.com/cjwatson/man-db https://www.nongnu.org/man-db/"
DESCRIPTION="A man replacement that utilizes dbm instead of flat files"
HOMEPAGE="https://gitlab.com/man-db/man-db https://www.nongnu.org/man-db/"
if [[ ${PV} == *9999 ]] ; then
inherit autotools git-r3
EGIT_REPO_URI="https://gitlab.com/cjwatson/man-db.git"
EGIT_REPO_URI="https://gitlab.com/man-db/man-db"
else
# TODO: Change tarballs to gitlab too...?
SRC_URI="mirror://nongnu/${PN}/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-3"
SLOT="0"
IUSE="berkdb +manpager nls +seccomp selinux static-libs zlib"
IUSE="+manpager nls +seccomp selinux static-libs zlib"
CDEPEND="!sys-apps/man
CDEPEND="
>=dev-libs/libpipeline-1.5.0
sys-apps/groff
!berkdb? ( sys-libs/gdbm:= )
berkdb? ( sys-libs/db:= )
sys-libs/gdbm:=
seccomp? ( sys-libs/libseccomp )
zlib? ( sys-libs/zlib )"
DEPEND="${CDEPEND}"
@ -62,7 +61,7 @@ src_unpack() {
src_prepare() {
default
if [[ "${PV}" == *9999 ]] ; then
if [[ ${PV} == *9999 ]] ; then
local bootstrap_opts=(
--gnulib-srcdir=../gnulib
--no-bootstrap-sync
@ -117,7 +116,7 @@ src_configure() {
$(use_enable static-libs static)
$(use_with seccomp libseccomp)
--with-db=$(usex berkdb db gdbm)
--with-db=gdbm
)
case ${CHOST} in
@ -132,9 +131,11 @@ src_configure() {
econf "${myeconfargs[@]}"
# Disable color output from groff so that the manpager can add it. bug #184604
if use manpager; then
sed -i \
-e '/^#DEFINE.*\<[nt]roff\>/{s:^#::;s:$: -c:}' \
src/man_db.conf || die
fi
cat > 15man-db <<-EOF || die
SANDBOX_PREDICT="/var/cache/man"

View File

@ -1,201 +0,0 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit systemd prefix tmpfiles
DESCRIPTION="A man replacement that utilizes berkdb instead of flat files"
HOMEPAGE="http://www.nongnu.org/man-db/"
if [[ "${PV}" = 9999* ]] ; then
inherit autotools git-r3
EGIT_REPO_URI="https://git.savannah.gnu.org/git/man-db.git"
else
SRC_URI="mirror://nongnu/${PN}/${P}.tar.xz"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-3"
SLOT="0"
IUSE="berkdb +gdbm +manpager nls +seccomp selinux static-libs zlib"
CDEPEND="
!sys-apps/man
>=dev-libs/libpipeline-1.5.0
sys-apps/groff
gdbm? ( sys-libs/gdbm:= )
!gdbm? ( berkdb? ( sys-libs/db:= ) )
!berkdb? ( !gdbm? ( sys-libs/gdbm:= ) )
seccomp? ( sys-libs/libseccomp )
zlib? ( sys-libs/zlib )
"
DEPEND="${CDEPEND}"
BDEPEND="
app-arch/xz-utils
virtual/pkgconfig
nls? (
>=app-text/po4a-0.45
sys-devel/gettext
virtual/libiconv
virtual/libintl
)
"
RDEPEND="
${CDEPEND}
acct-group/man
acct-user/man
selinux? ( sec-policy/selinux-mandb )
"
PDEPEND="manpager? ( app-text/manpager )"
PATCHES=(
"${FILESDIR}"/man-db-2.9.3-sandbox-env-tests.patch
"${FILESDIR}"/man-db-2.9.3-darwin-libdb-intl.patch
)
pkg_setup() {
if (use gdbm && use berkdb) || (use !gdbm && use !berkdb) ; then #496150
ewarn "Defaulting to USE=gdbm due to ambiguous berkdb/gdbm USE flag settings"
fi
}
src_unpack() {
if [[ "${PV}" == *9999 ]] ; then
git-r3_src_unpack
# We need to mess with gnulib :-/
EGIT_REPO_URI="https://git.savannah.gnu.org/r/gnulib.git" \
EGIT_CHECKOUT_DIR="${WORKDIR}/gnulib" \
git-r3_src_unpack
else
default
fi
}
src_prepare() {
default
if [[ "${PV}" == *9999 ]] ; then
local bootstrap_opts=(
--gnulib-srcdir=../gnulib
--no-bootstrap-sync
--copy
--no-git
)
AUTORECONF="/bin/true" \
LIBTOOLIZE="/bin/true" \
sh ./bootstrap "${bootstrap_opts[@]}" || die
eautoreconf
fi
hprefixify src/man_db.conf.in
if use prefix ; then
{
echo "#"
echo "# Added settings for Gentoo Prefix"
[[ ${CHOST} == *-darwin* ]] && \
echo "MANDATORY_MANPATH ${EPREFIX}/MacOSX.sdk/usr/share/man"
echo "MANDATORY_MANPATH /usr/share/man"
} >> src/man_db.conf.in
fi
}
src_configure() {
# set sections we want to search by default
local sections="1 1p 8 2 3 3p 4 5 6 7 9 0p tcl n l p o"
sections+=" 1x 2x 3x 4x 5x 6x 7x 8x"
case ${CHOST} in
*-solaris*)
# Solaris tends to use sections named after the pkgs that
# owns them, in particular for libc functions we want those
# sections
local s
for s in $(cd /usr/share/man/ && echo man*) ; do
s=${s#man}
[[ " ${sections} " != *" ${s} "* ]] && sections+=" ${s}"
done
;;
esac
export ac_cv_lib_z_gzopen=$(usex zlib)
local myeconfargs=(
--with-systemdtmpfilesdir="${EPREFIX}"/usr/lib/tmpfiles.d
--with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
--disable-setuid #662438
--enable-cache-owner=man
--with-sections="${sections}"
$(use_enable nls)
$(use_enable static-libs static)
$(use_with seccomp libseccomp)
--with-db=$(usex gdbm gdbm $(usex berkdb db gdbm))
)
case ${CHOST} in
*-solaris*|*-darwin*)
myeconfargs+=(
$(use_with nls libiconv-prefix ${EPREFIX}/usr)
$(use_with nls libintl-prefix ${EPREFIX}/usr)
)
;;
esac
econf "${myeconfargs[@]}"
# Disable color output from groff so that the manpager can add it. #184604
sed -i \
-e '/^#DEFINE.*\<[nt]roff\>/{s:^#::;s:$: -c:}' \
src/man_db.conf || die
cat > 15man-db <<-EOF || die
SANDBOX_PREDICT="/var/cache/man"
EOF
}
src_install() {
default
dodoc docs/{HACKING,TODO}
find "${ED}" -type f -name "*.la" -delete || die
exeinto /etc/cron.daily
newexe "${FILESDIR}"/man-db.cron-r1 man-db #289884
insinto /etc/sandbox.d
doins 15man-db
}
pkg_preinst() {
local cachedir="${EROOT}/var/cache/man"
# If the system was already exploited, and the attacker is hiding in the
# cachedir of the old man-db, let's wipe them out.
# see bug #602588 comment 18
local _replacing_version=
local _setgid_vuln=0
for _replacing_version in ${REPLACING_VERSIONS}; do
if ver_test '2.7.6.1-r2' -le "${_replacing_version}"; then
debug-print "Skipping security bug #602588 ... existing installation (${_replacing_version}) should not be affected!"
else
_setgid_vuln=1
debug-print "Applying cleanup for security bug #602588"
fi
done
[[ ${_setgid_vuln} -eq 1 ]] && rm -rf "${cachedir}"
# Fall back to recreating the cachedir
if [[ ! -d ${cachedir} ]] ; then
mkdir -p "${cachedir}" || die
chown man:man "${cachedir}" || die
fi
# Update the whatis cache
if [[ -f ${cachedir}/whatis ]] ; then
einfo "Cleaning ${cachedir} from sys-apps/man"
find "${cachedir}" -type f '!' '(' -name index.bt -o -name index.db ')' -delete
fi
}
pkg_postinst() {
tmpfiles_process man-db.conf
if [[ $(ver_cut 2 ${REPLACING_VERSIONS}) -lt 7 ]] ; then
einfo "Rebuilding man-db from scratch with new database format!"
su man -s /bin/sh -c 'mandb --quiet --create' 2>/dev/null
fi
}

View File

@ -1,30 +1,29 @@
# Copyright 1999-2022 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
EAPI=8
inherit systemd prefix tmpfiles
DESCRIPTION="A man replacement that utilizes berkdb instead of flat files"
HOMEPAGE="https://gitlab.com/cjwatson/man-db https://www.nongnu.org/man-db/"
DESCRIPTION="A man replacement that utilizes dbm instead of flat files"
HOMEPAGE="https://gitlab.com/man-db/man-db https://www.nongnu.org/man-db/"
if [[ ${PV} == *9999 ]] ; then
inherit autotools git-r3
EGIT_REPO_URI="https://gitlab.com/cjwatson/man-db.git"
EGIT_REPO_URI="https://gitlab.com/man-db/man-db"
else
# TODO: Change tarballs to gitlab too...?
SRC_URI="mirror://nongnu/${PN}/${P}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-3"
SLOT="0"
IUSE="berkdb +manpager nls +seccomp selinux static-libs zlib"
IUSE="+manpager nls +seccomp selinux static-libs zlib"
CDEPEND="!sys-apps/man
CDEPEND="
>=dev-libs/libpipeline-1.5.0
sys-apps/groff
!berkdb? ( sys-libs/gdbm:= )
berkdb? ( sys-libs/db:= )
sys-libs/gdbm:=
seccomp? ( sys-libs/libseccomp )
zlib? ( sys-libs/zlib )"
DEPEND="${CDEPEND}"
@ -62,7 +61,7 @@ src_unpack() {
src_prepare() {
default
if [[ "${PV}" == *9999 ]] ; then
if [[ ${PV} == *9999 ]] ; then
local bootstrap_opts=(
--gnulib-srcdir=../gnulib
--no-bootstrap-sync
@ -117,7 +116,7 @@ src_configure() {
$(use_enable static-libs static)
$(use_with seccomp libseccomp)
--with-db=$(usex berkdb db gdbm)
--with-db=gdbm
)
case ${CHOST} in
@ -132,9 +131,11 @@ src_configure() {
econf "${myeconfargs[@]}"
# Disable color output from groff so that the manpager can add it. bug #184604
if use manpager; then
sed -i \
-e '/^#DEFINE.*\<[nt]roff\>/{s:^#::;s:$: -c:}' \
src/man_db.conf || die
fi
cat > 15man-db <<-EOF || die
SANDBOX_PREDICT="/var/cache/man"

View File

@ -8,4 +8,7 @@
<use>
<flag name="manpager">Enable manpager wrapper for colorizing output</flag>
</use>
<upstream>
<remote-id type="gitlab">man-db/man-db</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1 +1,2 @@
DIST man-pages-posix-2013-a.tar.xz 930736 BLAKE2B 4d496a4ea7bcf9f101a9b5c31eaa437317e872d9d266c202a1fcfd16d9b2fa71f968c3653bc9789ba18916a93802736e795c43bb3f87324397f49aed0f6d1556 SHA512 e6ec8eb57269fadf368aeaac31b5a98b9c71723d4d5cc189f9c4642d6e865c88e44f77481dccbdb72e31526488eb531f624d455016361687a834ccfcac19fa14
DIST man-pages-posix-2017-a.tar.xz 935196 BLAKE2B 45d732c712f8d6b18f151c7383130a367d5774ec9d814cf9e61accb01e9d91ad3e9b49bc4f1b993f28688e9c39cf1fbea91b86b00c05968b0bc0a5665211defb SHA512 dac6bd5bb3e1d5f8918bad3eb15e08eeb3e06ae160c04ccd5619bfb0c536139ac06faa62b6856656a1bb9a7496f3148e52a5227b83e4099be6e6b93230de211d

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -10,13 +10,13 @@ SRC_URI="https://www.kernel.org/pub/linux/docs/man-pages/${PN}/${MY_P}.tar.xz"
LICENSE="man-pages-posix-2013"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos"
IUSE=""
RESTRICT="binchecks"
RDEPEND="virtual/man !<sys-apps/man-pages-3"
S="${WORKDIR}/${PN}-${PV:0:4}"
S=${WORKDIR}/${MY_P}
src_configure() { :; }

View File

@ -0,0 +1,28 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
MY_P="${PN}-${PV:0:4}-${PV:0-1}"
DESCRIPTION="POSIX man-pages (0p, 1p, 3p)"
HOMEPAGE="https://www.kernel.org/doc/man-pages/"
SRC_URI="https://www.kernel.org/pub/linux/docs/man-pages/${PN}/${MY_P}.tar.xz"
LICENSE="freedist" # to be clarified, see bug 871636
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos"
IUSE=""
RESTRICT="binchecks"
RDEPEND="virtual/man !<sys-apps/man-pages-3"
S="${WORKDIR}/${PN}-${PV:0:4}"
src_configure() { :; }
src_compile() { :; }
src_install() {
emake install DESTDIR="${ED}"
dodoc man-pages-*.Announce README
}

View File

@ -1,3 +1,7 @@
DIST man-pages-5.12.tar.xz 1778220 BLAKE2B 347c5ef63cb80134018f322f810545354ccc7afdb8acb62f83e3b06ef15d7fbe6c0c68db37f52ce9727682a856a7810a5e64f1dcbe1cc11b22f83fb0273f7add SHA512 455794ed6e3bf20649f78b464300d5c1adad5000668a82a1194c1af8bdcbd064e4d930696cbe534481368d6526c7cda69927e958b9a868d95891202476fb4608
DIST man-pages-5.13.tar.xz 1788980 BLAKE2B 7cca88b7f201d177b087893f60e6a87fd3ed8c78a183bd6ebcd0c28961f5f5d24aa2ba9d3a1d9cec4e0fc9cc0b26489c91e991a2d4420c28e1f61b850b882752 SHA512 a68c0bd5f078aff2f13f962060863e5d30734c1c562e8e9e3d5eda5a329b18ad3e9b4ebb883d31cacfc0a476f91fccb8dd4257598acd75d09dd21351893d3499
DIST man-pages-6.01.tar.xz 1789204 BLAKE2B 37005b45af798315992fe4836457982d4203245eb546a6f1dcb02b67d63db1ba7e872b1259ebb58ee01178c726fff5f2276ec548ba768f73683edaee9a3233ca SHA512 93d09380a08c36740dbb2f3f246d190e5467147344b584253a2e0248fa764559008c21bb567f379f6166952ee1635ae3c2145e2a63aaf6d30728ca680d7b57a9
DIST man-pages-6.02.tar.xz 1800876 BLAKE2B 005bc57d2abca18516502faa7ea31798e6fb992d4a2fa1ce83dbba2992d9cc29e3b48fef97f1faa55bc40eafcb4eedbafb113dc2561f4a438f0a7fa711e259f0 SHA512 124e5157c25b5a3c62d225be1da2879f436d7fd8fe2f116c11982178e34085d1e50ef47e13fde413a7bf16d1177cbe744d00b2a178be3dfe4c4828371812ea5a
DIST man-pages-6.03.tar.xz 2184824 BLAKE2B 16eba629c5fcbac7b52fa0ecf32d30d0e07308653d3617d1edf7503b6f983aa3f5145b1af7c5fcc96cb5a64ad425af7fe9be9a0da74c92c52d2d9b8fc60c9661 SHA512 df9de826c8289869fb27928f14eb28040b0f5bdae18247dc2ea847e660dd8bff9eee5656f6b2b38330abc64b69cad7cd44681bdf49173dd49a53877eaf725dba
DIST man-pages-6.04.tar.xz 2188236 BLAKE2B 741ff7e279c9bd961a1d39e432599a985d010516c03eb13978c5bda46a26ef914053c511bce923d49eb9111b3a1f7537e4418df3b5abd2eb0c051faf9f39c7fb SHA512 3f95d15dda419e824f902947a268d8021e9e04c5ba8503e4fe9f96a9ab8363fde8088b2712cc9c795638163ad8432bc5f8c6a3ea320293ec6aa79bb748e85b9e
DIST man-pages-gentoo-2.tar.bz2 5141 BLAKE2B c5c7956ab47c8a473e258b1902d5d19d9eb2e9d01786e907d9c3ba691c2a506834ed96cd1f54e8d8415e65d4fea0056659537f0faffe68fcbed33aa728a5e61e SHA512 6e6524b8ad6f1b8c9b147665ee32af49e05603dac61d433acd6b4f1164adef27cd542898f272b07d8659725013dac59c7f34a858968cc054a4785c945e14a770

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -14,7 +14,7 @@ SRC_URI="https://www.kernel.org/pub/linux/docs/man-pages/Archive/${P}.tar.xz
LICENSE="man-pages GPL-2+ BSD"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 amd64-linux ~x86-linux"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 amd64-linux ~x86-linux ~arm64-macos"
IUSE_L10N=" de es fr it ja nl pl pt-BR ro ru zh-CN"
IUSE="${IUSE_L10N// / l10n_}"
RESTRICT="binchecks"
@ -37,7 +37,6 @@ PDEPEND="
l10n_ro? ( app-i18n/man-pages-l10n[l10n_ro(-)] )
l10n_ru? ( app-i18n/man-pages-ru )
l10n_zh-CN? ( app-i18n/man-pages-zh_CN )
sys-apps/man-pages-posix
"
src_prepare() {
@ -60,3 +59,15 @@ src_install() {
doman */*
dodoc README.Gentoo
}
pkg_postinst() {
for ver in ${REPLACING_VERSIONS} ; do
if ver_test ${ver} -lt 5.12-r3 ; then
# Avoid ACCEPT_LICENSE issues for users by default
# bug #871636
ewarn "This version of ${PN} no longer depends on sys-apps/man-pages-posix!"
ewarn "Please install sys-apps/man-pages-posix yourself if needed."
break
fi
done
}

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -14,7 +14,7 @@ SRC_URI="https://www.kernel.org/pub/linux/docs/man-pages/Archive/${P}.tar.xz
LICENSE="man-pages GPL-2+ BSD"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos"
IUSE_L10N=" de es fr it ja nl pl pt-BR ro ru zh-CN"
IUSE="${IUSE_L10N// / l10n_}"
RESTRICT="binchecks"
@ -37,7 +37,6 @@ PDEPEND="
l10n_ro? ( app-i18n/man-pages-l10n[l10n_ro(-)] )
l10n_ru? ( app-i18n/man-pages-ru )
l10n_zh-CN? ( app-i18n/man-pages-zh_CN )
sys-apps/man-pages-posix
"
src_prepare() {
@ -60,3 +59,15 @@ src_install() {
doman */*
dodoc README.Gentoo
}
pkg_postinst() {
for ver in ${REPLACING_VERSIONS} ; do
if ver_test ${ver} -lt 5.13-r2 ; then
# Avoid ACCEPT_LICENSE issues for users by default
# bug #871636
ewarn "This version of ${PN} no longer depends on sys-apps/man-pages-posix!"
ewarn "Please install sys-apps/man-pages-posix yourself if needed."
break
fi
done
}

View File

@ -0,0 +1,116 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Maintenance notes:
# - Upstream are very friendly, do approach them if have any questions;
#
# - It's considered fine (and somewhat encouraged) for us to make snapshots
# if we want specific fixes, perhaps aligned with newer kernels, glibc, etc.
# Just generate it with 'make dist'. We can set DISTVERSION if we want a vanity
# name or if the comit hash is too long;
#
# - If we do use a snapshot, *don't* grab it directly from git and use it
# raw in the ebuild. Use 'make dist' as above;
#
# - Sometimes there's no dist tarball available post-release and upstream
# encourage distros to make their own. Set MAN_PAGES_GENTOO_DIST to 1 if none is
# available, 0 otherwise.
MAN_PAGES_GENTOO_DIST=0
GENTOO_PATCH=2
DESCRIPTION="A somewhat comprehensive collection of Linux man pages"
HOMEPAGE="https://www.kernel.org/doc/man-pages/"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git"
inherit git-r3
elif [[ ${PV} == *_rc* ]] ; then
MY_P=${PN}-${PV/_/-}
SRC_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/snapshot/${MY_P}.tar.gz"
S="${WORKDIR}"/${MY_P}
else
if [[ ${MAN_PAGES_GENTOO_DIST} -eq 1 ]] ; then
SRC_URI="https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${P}-gentoo.tar.xz"
else
SRC_URI="
https://www.kernel.org/pub/linux/docs/man-pages/Archive/${P}.tar.xz
https://www.kernel.org/pub/linux/docs/man-pages/${P}.tar.xz
"
fi
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos"
fi
SRC_URI+="
mirror://gentoo/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
https://dev.gentoo.org/~cardoe/files/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
"
LICENSE="man-pages GPL-2+ BSD"
SLOT="0"
# Keep the following in sync with app-i18n/man-pages-l10n
MY_L10N=( cs da de el es fi fr hu id it mk nb nl pl pt-BR ro sr sv uk vi )
IUSE="l10n_ja l10n_ru l10n_zh-CN ${MY_L10N[@]/#/l10n_}"
RESTRICT="binchecks"
BDEPEND="
sys-devel/bc
"
# Block packages that used to install colliding man pages:
# bug #341953, bug #548900, bug #612640, bug #617462
RDEPEND="
virtual/man
!<sys-apps/keyutils-1.5.9-r4
!<dev-libs/libbsd-0.8.3-r1
"
PDEPEND="
l10n_ja? ( app-i18n/man-pages-ja )
l10n_ru? ( || (
app-i18n/man-pages-l10n[l10n_ru(-)]
app-i18n/man-pages-ru
) )
l10n_zh-CN? ( app-i18n/man-pages-zh_CN )
"
for lang in "${MY_L10N[@]}"; do
PDEPEND+=" l10n_${lang}? ( app-i18n/man-pages-l10n[l10n_${lang}(-)] )"
done
unset lang
src_unpack() {
default
[[ ${PV} == 9999 ]] && git-r3_src_unpack
}
src_prepare() {
default
# passwd.5 installed by sys-apps/shadow, bug #776787
rm man5/passwd.5 || die
}
src_compile() { :; }
src_install() {
emake install prefix="${EPREFIX}"/usr DESTDIR="${D}"
dodoc man-pages-*.Announce README Changes*
# Override with Gentoo specific or additional Gentoo pages
cd "${WORKDIR}"/man-pages-gentoo || die
doman */*
dodoc README.Gentoo
}
pkg_postinst() {
for ver in ${REPLACING_VERSIONS} ; do
if ver_test ${ver} -lt 5.13-r2 ; then
# Avoid ACCEPT_LICENSE issues for users by default
# bug #871636
ewarn "This version of ${PN} no longer depends on sys-apps/man-pages-posix!"
ewarn "Please install sys-apps/man-pages-posix yourself if needed."
break
fi
done
}

View File

@ -0,0 +1,116 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Maintenance notes:
# - Upstream are very friendly, do approach them if have any questions;
#
# - It's considered fine (and somewhat encouraged) for us to make snapshots
# if we want specific fixes, perhaps aligned with newer kernels, glibc, etc.
# Just generate it with 'make dist'. We can set DISTVERSION if we want a vanity
# name or if the comit hash is too long;
#
# - If we do use a snapshot, *don't* grab it directly from git and use it
# raw in the ebuild. Use 'make dist' as above;
#
# - Sometimes there's no dist tarball available post-release and upstream
# encourage distros to make their own. Set MAN_PAGES_GENTOO_DIST to 1 if none is
# available, 0 otherwise.
MAN_PAGES_GENTOO_DIST=0
GENTOO_PATCH=2
DESCRIPTION="A somewhat comprehensive collection of Linux man pages"
HOMEPAGE="https://www.kernel.org/doc/man-pages/"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git"
inherit git-r3
elif [[ ${PV} == *_rc* ]] ; then
MY_P=${PN}-${PV/_/-}
SRC_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/snapshot/${MY_P}.tar.gz"
S="${WORKDIR}"/${MY_P}
else
if [[ ${MAN_PAGES_GENTOO_DIST} -eq 1 ]] ; then
SRC_URI="https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${P}-gentoo.tar.xz"
else
SRC_URI="
https://www.kernel.org/pub/linux/docs/man-pages/Archive/${P}.tar.xz
https://www.kernel.org/pub/linux/docs/man-pages/${P}.tar.xz
"
fi
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos"
fi
SRC_URI+="
mirror://gentoo/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
https://dev.gentoo.org/~cardoe/files/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
"
LICENSE="man-pages GPL-2+ BSD"
SLOT="0"
# Keep the following in sync with app-i18n/man-pages-l10n
MY_L10N=( cs da de el es fi fr hu id it mk nb nl pl pt-BR ro sr sv uk vi )
IUSE="l10n_ja l10n_ru l10n_zh-CN ${MY_L10N[@]/#/l10n_}"
RESTRICT="binchecks"
BDEPEND="
sys-devel/bc
"
# Block packages that used to install colliding man pages:
# bug #341953, bug #548900, bug #612640, bug #617462
RDEPEND="
virtual/man
!<sys-apps/keyutils-1.5.9-r4
!<dev-libs/libbsd-0.8.3-r1
"
PDEPEND="
l10n_ja? ( app-i18n/man-pages-ja )
l10n_ru? ( || (
app-i18n/man-pages-l10n[l10n_ru(-)]
app-i18n/man-pages-ru
) )
l10n_zh-CN? ( app-i18n/man-pages-zh_CN )
"
for lang in "${MY_L10N[@]}"; do
PDEPEND+=" l10n_${lang}? ( app-i18n/man-pages-l10n[l10n_${lang}(-)] )"
done
unset lang
src_unpack() {
default
[[ ${PV} == 9999 ]] && git-r3_src_unpack
}
src_prepare() {
default
# passwd.5 installed by sys-apps/shadow, bug #776787
rm man5/passwd.5 || die
}
src_compile() { :; }
src_install() {
emake install prefix="${EPREFIX}"/usr DESTDIR="${D}"
dodoc README Changes*
# Override with Gentoo specific or additional Gentoo pages
cd "${WORKDIR}"/man-pages-gentoo || die
doman */*
dodoc README.Gentoo
}
pkg_postinst() {
for ver in ${REPLACING_VERSIONS} ; do
if ver_test ${ver} -lt 5.13-r2 ; then
# Avoid ACCEPT_LICENSE issues for users by default
# bug #871636
ewarn "This version of ${PN} no longer depends on sys-apps/man-pages-posix!"
ewarn "Please install sys-apps/man-pages-posix yourself if needed."
break
fi
done
}

View File

@ -0,0 +1,116 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Maintenance notes:
# - Upstream are very friendly, do approach them if have any questions;
#
# - It's considered fine (and somewhat encouraged) for us to make snapshots
# if we want specific fixes, perhaps aligned with newer kernels, glibc, etc.
# Just generate it with 'make dist'. We can set DISTVERSION if we want a vanity
# name or if the comit hash is too long;
#
# - If we do use a snapshot, *don't* grab it directly from git and use it
# raw in the ebuild. Use 'make dist' as above;
#
# - Sometimes there's no dist tarball available post-release and upstream
# encourage distros to make their own. Set MAN_PAGES_GENTOO_DIST to 1 if none is
# available, 0 otherwise.
MAN_PAGES_GENTOO_DIST=0
GENTOO_PATCH=2
DESCRIPTION="A somewhat comprehensive collection of Linux man pages"
HOMEPAGE="https://www.kernel.org/doc/man-pages/"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git"
inherit git-r3
elif [[ ${PV} == *_rc* ]] ; then
MY_P=${PN}-${PV/_/-}
SRC_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/snapshot/${MY_P}.tar.gz"
S="${WORKDIR}"/${MY_P}
else
if [[ ${MAN_PAGES_GENTOO_DIST} -eq 1 ]] ; then
SRC_URI="https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${P}-gentoo.tar.xz"
else
SRC_URI="
https://www.kernel.org/pub/linux/docs/man-pages/Archive/${P}.tar.xz
https://www.kernel.org/pub/linux/docs/man-pages/${P}.tar.xz
"
fi
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos"
fi
SRC_URI+="
mirror://gentoo/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
https://dev.gentoo.org/~cardoe/files/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
"
LICENSE="man-pages GPL-2+ BSD"
SLOT="0"
# Keep the following in sync with app-i18n/man-pages-l10n
MY_L10N=( cs da de el es fi fr hu id it mk nb nl pl pt-BR ro sr sv uk vi )
IUSE="l10n_ja l10n_ru l10n_zh-CN ${MY_L10N[@]/#/l10n_}"
RESTRICT="binchecks"
BDEPEND="
sys-devel/bc
"
# Block packages that used to install colliding man pages:
# bug #341953, bug #548900, bug #612640, bug #617462
RDEPEND="
virtual/man
!<sys-apps/keyutils-1.5.9-r4
!<dev-libs/libbsd-0.8.3-r1
"
PDEPEND="
l10n_ja? ( app-i18n/man-pages-ja )
l10n_ru? ( || (
app-i18n/man-pages-l10n[l10n_ru(-)]
app-i18n/man-pages-ru
) )
l10n_zh-CN? ( app-i18n/man-pages-zh_CN )
"
for lang in "${MY_L10N[@]}"; do
PDEPEND+=" l10n_${lang}? ( app-i18n/man-pages-l10n[l10n_${lang}(-)] )"
done
unset lang
src_unpack() {
default
[[ ${PV} == 9999 ]] && git-r3_src_unpack
}
src_prepare() {
default
# passwd.5 installed by sys-apps/shadow, bug #776787
rm man5/passwd.5 || die
}
src_compile() { :; }
src_install() {
emake install prefix="${EPREFIX}"/usr DESTDIR="${D}"
dodoc README Changes*
# Override with Gentoo specific or additional Gentoo pages
cd "${WORKDIR}"/man-pages-gentoo || die
doman */*
dodoc README.Gentoo
}
pkg_postinst() {
for ver in ${REPLACING_VERSIONS} ; do
if ver_test ${ver} -lt 5.13-r2 ; then
# Avoid ACCEPT_LICENSE issues for users by default
# bug #871636
ewarn "This version of ${PN} no longer depends on sys-apps/man-pages-posix!"
ewarn "Please install sys-apps/man-pages-posix yourself if needed."
break
fi
done
}

View File

@ -0,0 +1,122 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Maintenance notes:
# - Upstream are very friendly, do approach them if have any questions;
#
# - It's considered fine (and somewhat encouraged) for us to make snapshots
# if we want specific fixes, perhaps aligned with newer kernels, glibc, etc.
# Just generate it with 'make dist'. We can set DISTVERSION if we want a vanity
# name or if the comit hash is too long;
#
# - If we do use a snapshot, *don't* grab it directly from git and use it
# raw in the ebuild. Use 'make dist' as above;
#
# - Sometimes there's no dist tarball available post-release and upstream
# encourage distros to make their own. Set MAN_PAGES_GENTOO_DIST to 1 if none is
# available, 0 otherwise.
MAN_PAGES_GENTOO_DIST=0
GENTOO_PATCH=2
DESCRIPTION="A somewhat comprehensive collection of Linux man pages"
HOMEPAGE="https://www.kernel.org/doc/man-pages/"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git"
inherit git-r3
elif [[ ${PV} == *_rc* ]] ; then
MY_P=${PN}-${PV/_/-}
SRC_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/snapshot/${MY_P}.tar.gz"
S="${WORKDIR}"/${MY_P}
else
if [[ ${MAN_PAGES_GENTOO_DIST} -eq 1 ]] ; then
SRC_URI="https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${P}-gentoo.tar.xz"
else
SRC_URI="
https://www.kernel.org/pub/linux/docs/man-pages/Archive/${P}.tar.xz
https://www.kernel.org/pub/linux/docs/man-pages/${P}.tar.xz
"
fi
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos"
fi
SRC_URI+="
mirror://gentoo/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
https://dev.gentoo.org/~cardoe/files/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
"
LICENSE="man-pages GPL-2+ BSD"
SLOT="0"
# Keep the following in sync with app-i18n/man-pages-l10n
MY_L10N=( cs da de el es fi fr hu id it mk nb nl pl pt-BR ro sr sv uk vi )
IUSE="l10n_ja l10n_ru l10n_zh-CN ${MY_L10N[@]/#/l10n_}"
RESTRICT="binchecks"
BDEPEND="
sys-devel/bc
"
# Block packages that used to install colliding man pages:
# bug #341953, bug #548900, bug #612640, bug #617462
RDEPEND="
virtual/man
!<sys-apps/keyutils-1.5.9-r4
!<dev-libs/libbsd-0.8.3-r1
"
PDEPEND="
l10n_ja? ( app-i18n/man-pages-ja )
l10n_ru? ( || (
app-i18n/man-pages-l10n[l10n_ru(-)]
app-i18n/man-pages-ru
) )
l10n_zh-CN? ( app-i18n/man-pages-zh_CN )
"
for lang in "${MY_L10N[@]}"; do
PDEPEND+=" l10n_${lang}? ( app-i18n/man-pages-l10n[l10n_${lang}(-)] )"
done
unset lang
src_unpack() {
default
[[ ${PV} == 9999 ]] && git-r3_src_unpack
}
src_prepare() {
default
# passwd.5 installed by sys-apps/shadow, bug #776787
rm man5/passwd.5 || die
}
src_compile() { :; }
src_test() {
# We don't use the 'check' target right now because of known errors
# https://lore.kernel.org/linux-man/0dfd5319-2d22-a8ad-f085-d635eb6d0678@gmail.com/T/#t
emake lint-man-tbl
}
src_install() {
emake install prefix="${EPREFIX}"/usr DESTDIR="${D}"
dodoc README Changes*
# Override with Gentoo specific or additional Gentoo pages
cd "${WORKDIR}"/man-pages-gentoo || die
doman */*
dodoc README.Gentoo
}
pkg_postinst() {
for ver in ${REPLACING_VERSIONS} ; do
if ver_test ${ver} -lt 5.13-r2 ; then
# Avoid ACCEPT_LICENSE issues for users by default
# bug #871636
ewarn "This version of ${PN} no longer depends on sys-apps/man-pages-posix!"
ewarn "Please install sys-apps/man-pages-posix yourself if needed."
break
fi
done
}

View File

@ -0,0 +1,122 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
# Maintenance notes:
# - Upstream are very friendly, do approach them if have any questions;
#
# - It's considered fine (and somewhat encouraged) for us to make snapshots
# if we want specific fixes, perhaps aligned with newer kernels, glibc, etc.
# Just generate it with 'make dist'. We can set DISTVERSION if we want a vanity
# name or if the comit hash is too long;
#
# - If we do use a snapshot, *don't* grab it directly from git and use it
# raw in the ebuild. Use 'make dist' as above;
#
# - Sometimes there's no dist tarball available post-release and upstream
# encourage distros to make their own. Set MAN_PAGES_GENTOO_DIST to 1 if none is
# available, 0 otherwise.
MAN_PAGES_GENTOO_DIST=0
GENTOO_PATCH=2
DESCRIPTION="A somewhat comprehensive collection of Linux man pages"
HOMEPAGE="https://www.kernel.org/doc/man-pages/"
if [[ ${PV} == 9999 ]] ; then
EGIT_REPO_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git"
inherit git-r3
elif [[ ${PV} == *_rc* ]] ; then
MY_P=${PN}-${PV/_/-}
SRC_URI="https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/snapshot/${MY_P}.tar.gz"
S="${WORKDIR}"/${MY_P}
else
if [[ ${MAN_PAGES_GENTOO_DIST} -eq 1 ]] ; then
SRC_URI="https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${P}-gentoo.tar.xz"
else
SRC_URI="
https://www.kernel.org/pub/linux/docs/man-pages/Archive/${P}.tar.xz
https://www.kernel.org/pub/linux/docs/man-pages/${P}.tar.xz
"
fi
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos"
fi
SRC_URI+="
mirror://gentoo/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
https://dev.gentoo.org/~cardoe/files/man-pages-gentoo-${GENTOO_PATCH}.tar.bz2
"
LICENSE="man-pages GPL-2+ BSD"
SLOT="0"
# Keep the following in sync with app-i18n/man-pages-l10n
MY_L10N=( cs da de el es fi fr hu id it mk nb nl pl pt-BR ro sr sv uk vi )
IUSE="l10n_ja l10n_ru l10n_zh-CN ${MY_L10N[@]/#/l10n_}"
RESTRICT="binchecks"
BDEPEND="
sys-devel/bc
"
# Block packages that used to install colliding man pages:
# bug #341953, bug #548900, bug #612640, bug #617462
RDEPEND="
virtual/man
!<sys-apps/keyutils-1.5.9-r4
!<dev-libs/libbsd-0.8.3-r1
"
PDEPEND="
l10n_ja? ( app-i18n/man-pages-ja )
l10n_ru? ( || (
app-i18n/man-pages-l10n[l10n_ru(-)]
app-i18n/man-pages-ru
) )
l10n_zh-CN? ( app-i18n/man-pages-zh_CN )
"
for lang in "${MY_L10N[@]}"; do
PDEPEND+=" l10n_${lang}? ( app-i18n/man-pages-l10n[l10n_${lang}(-)] )"
done
unset lang
src_unpack() {
default
[[ ${PV} == 9999 ]] && git-r3_src_unpack
}
src_prepare() {
default
# passwd.5 installed by sys-apps/shadow, bug #776787
rm man5/passwd.5 || die
}
src_compile() { :; }
src_test() {
# We don't use the 'check' target right now because of known errors
# https://lore.kernel.org/linux-man/0dfd5319-2d22-a8ad-f085-d635eb6d0678@gmail.com/T/#t
emake lint-man-tbl
}
src_install() {
emake install prefix="${EPREFIX}"/usr DESTDIR="${D}"
dodoc README Changes*
# Override with Gentoo specific or additional Gentoo pages
cd "${WORKDIR}"/man-pages-gentoo || die
doman */*
dodoc README.Gentoo
}
pkg_postinst() {
for ver in ${REPLACING_VERSIONS} ; do
if ver_test ${ver} -lt 5.13-r2 ; then
# Avoid ACCEPT_LICENSE issues for users by default
# bug #871636
ewarn "This version of ${PN} no longer depends on sys-apps/man-pages-posix!"
ewarn "Please install sys-apps/man-pages-posix yourself if needed."
break
fi
done
}

View File

@ -5,4 +5,7 @@
<email>base-system@gentoo.org</email>
<name>Gentoo Base System</name>
</maintainer>
<upstream>
<remote-id type="savannah">miscfiles</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1,7 +1,7 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
EAPI=7
UNI_PV="10.0.0"
DESCRIPTION="Miscellaneous files"
@ -12,7 +12,7 @@ SRC_URI="mirror://gnu/miscfiles/${P}.tar.gz
LICENSE="GPL-2 unicode"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x86-solaris"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x86-solaris"
IUSE="minimal"
src_prepare() {
@ -31,14 +31,14 @@ src_install() {
# not sure if this is still needed ...
dodir /usr/share/dict
cd "${ED%/}"/usr/share/misc || die
cd "${ED}"/usr/share/misc || die
mv $(awk '$1=="dictfiles"{$1="";$2="";print}' "${S}"/Makefile) ../dict/ || die
cd ../dict || die
ln -s web2 words || die
ln -s web2a extra.words || die
if use minimal ; then
pushd "${ED%/}"/usr/share/dict || die
pushd "${ED}"/usr/share/dict || die
rm -f words extra.words || die
gzip -9 * || die
ln -s web2.gz words || die
@ -46,12 +46,12 @@ src_install() {
ln -s connectives{.gz,} || die
ln -s propernames{.gz,} || die
popd || die
rm -r "${ED%/}"/usr/share/misc || die
rm -r "${ED}"/usr/share/misc || die
fi
}
pkg_postinst() {
if [[ ${ROOT} == "/" ]] && type -P create-cracklib-dict >/dev/null ; then
if [[ -z ${ROOT} ]] && type -P create-cracklib-dict >/dev/null ; then
ebegin "Regenerating cracklib dictionary"
create-cracklib-dict "${EPREFIX}"/usr/share/dict/* > /dev/null
eend $?

View File

@ -12,6 +12,7 @@
<flag name="slattach">build the slattach tool (for working with old serial ports)</flag>
</use>
<upstream>
<remote-id type="cpe">cpe:/a:net-tools_project:net-tools</remote-id>
<remote-id type="sourceforge">net-tools</remote-id>
</upstream>
</pkgmetadata>

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="7"
@ -10,7 +10,7 @@ if [[ ${PV} == "9999" ]] ; then
inherit git-r3
else
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.xz"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux"
fi
DESCRIPTION="Standard Linux networking tools"
@ -23,7 +23,8 @@ REQUIRED_USE="nis? ( hostname )"
DEPEND="selinux? ( sys-libs/libselinux )"
RDEPEND="${DEPEND}
hostname? ( !sys-apps/coreutils[hostname] )"
hostname? ( !sys-apps/coreutils[hostname] )
nis? ( !net-nds/yp-tools )"
BDEPEND="
selinux? ( virtual/pkgconfig )
app-arch/xz-utils

View File

@ -1,4 +1,4 @@
# Copyright 1999-2021 Gentoo Authors
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="7"
@ -23,7 +23,8 @@ REQUIRED_USE="nis? ( hostname )"
DEPEND="selinux? ( sys-libs/libselinux )"
RDEPEND="${DEPEND}
hostname? ( !sys-apps/coreutils[hostname] )"
hostname? ( !sys-apps/coreutils[hostname] )
nis? ( !net-nds/yp-tools )"
BDEPEND="
selinux? ( virtual/pkgconfig )
app-arch/xz-utils

View File

@ -1,3 +1,3 @@
DIST nvme-cli-1.14.tar.gz 579561 BLAKE2B e27dade228ee47d88ef5cbab4d9d6163e75af44fb3345ed2ae566e875b973355255a5aba1b1846e53006f9676922cf7901a5e6e4867fcf04c591bf372a119bca SHA512 b5e18708233fd37069d84ee34232d737ed6d6909b0ec523d82cc2c4940172f7ce769b9bbec0d8615ebee544a5174cb4d752ad6d96ea05cfaa1177efc760f0e9e
DIST nvme-cli-1.15.tar.gz 610927 BLAKE2B 66278904d49987d92083c1bb28a98d362adee8e85ee92e44e9dee381f3efcc76ac53ddf82957495ac7b2ef82e717c570d55e1b2052224740c1bc7e5af8af137e SHA512 0614105153edf7217d4c428927423628b63f6bee034c59926370a13d433c9c3af217338fb6fe2f8bbf781fc17ebae0102e8c072371b7ea4324c18dfdffd40305
DIST nvme-cli-1.16.tar.gz 598246 BLAKE2B 8aef6ae82ec9a2c67de6c69addd72c87ade6554e6d374c717f8e3c0585565974a2b2870eb172b3ebdc1ae307bd3a55a14a17d3feea8d437265db136b434b519f SHA512 c713eb15b979ad17791cf95717b42d5f638cb4803d646bca1f4825e6bb50f086226b44b108b61571709b2cb615ae6ba86dbad309f675b240ebd3968d1cf536ff
DIST nvme-cli-2.2.1.gh.tar.gz 706199 BLAKE2B e0026fc2ee3edeffa18b0fc8365703e3de6f69cdd665878e8589fefa334ddb78f3fdf2768bd5a141dc27b0a7403d0fd7472db763e7e41b55a3cac314105faac3 SHA512 8efa94d49a4d443cdb0310386733e88117f17719b05044f11e63e2a09143fce55918171b457a467371263ebb2e36552558aad249ae4dbd27941af79fe9722e26
DIST nvme-cli-2.3.gh.tar.gz 733161 BLAKE2B b6da650379f24e0dc5c41af3d09fe15076ed70ad39cf48060fd949e3a4bbfe896eef4dd42e27314fab695710c9cb04985f3444e0384b71794cfbf489aa3e6244 SHA512 9ef654e782ba737d3858fb11f24caf27aea820480179d07d32599731be204e52693062cdb86786ab5cdd1d94fe32ae9028baa0a58693d2eaee5a2b71155e3db2
DIST nvme-cli-2.4.gh.tar.gz 746955 BLAKE2B 7ca26f957bf6927f7af17ac18267cb1099d63ce0f19b085a412b3a1b343946311edf8c5d5924444b7c7d440fbf42597ee7b9717bf9f5dcdeed0a9a17f135d343 SHA512 155667a0b91e15267e3f991a30cf1d4ae26cb4c53b20c002e3d3341496dd463397e1afbfefcd7a8df88370d28417940ce44a060bda87c04482bbe3be4e901b73

View File

@ -1,37 +0,0 @@
https://github.com/linux-nvme/nvme-cli/commit/4729b13f36d4713ce1162dc1d4425d44e1474078.patch
https://bugs.gentoo.org/829705
(and an additional hunk for https://bugs.gentoo.org/830744)
From: Ariadne Conill <ariadne@dereferenced.org>
Date: Mon, 26 Apr 2021 00:41:20 -0600
Subject: [PATCH] nvme-rpmb: Add limits.h due to missing PATH_MAX definition
Commit 21f40f38b introduced new use of PATH_MAX, but did not add the
limits.h header. This resulted in nvme-cli failing to build on
ppc64le systems using the musl C library.
Signed-off-by: Ariadne Conill <ariadne@dereferenced.org>
[dwagner: removed nvme-topology.c bits]
Signed-off-by: Daniel Wagner <dwagner@suse.de>
--- a/nvme-rpmb.c
+++ b/nvme-rpmb.c
@@ -25,6 +25,7 @@
#include <sys/socket.h>
#include <linux/if_alg.h>
#include <linux/socket.h>
+#include <limits.h>
#include "nvme.h"
#include "libnvme.h"
diff --git a/nvme-topology.c b/nvme-topology.c
index 0a22f6b..6d510f2 100644
--- a/nvme-topology.c
+++ b/nvme-topology.c
@@ -1,6 +1,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
+#include <limits.h>
#include <unistd.h>
#include <fcntl.h>
#include <sys/stat.h>

View File

@ -0,0 +1,13 @@
diff --git a/Documentation/meson.build b/Documentation/meson.build
index bb0c9724..519c4bfc 100644
--- a/Documentation/meson.build
+++ b/Documentation/meson.build
@@ -187,7 +187,7 @@ want_docs = get_option('docs')
want_docs_build = get_option('docs-build')
if want_docs != 'false'
mandir = join_paths(get_option('mandir'), 'man1')
- htmldir = join_paths(get_option('htmldir'), 'nvme')
+ htmldir = get_option('htmldir')
asciidoctor = find_program('asciidoc', required: get_option('docs-build'))
if want_docs_build and asciidoctor.found()

View File

@ -0,0 +1,25 @@
diff --git a/meson.build b/meson.build
index c05dc47f..4ae7c513 100644
--- a/meson.build
+++ b/meson.build
@@ -64,9 +64,9 @@ libz_dep = dependency('zlib', required: true,
fallback : ['zlib', 'zlib_dep'])
# Check for libhugetlbfs availability (optional)
-if cc.has_header('hugetlbfs.h')
+if get_option('hugepages') and cc.has_header('hugetlbfs.h')
libhugetlbfs_dep = cc.find_library('hugetlbfs',
- required : false)
+ required : true)
have_libhugetlbfs = libhugetlbfs_dep.found()
else
libhugetlbfs_dep = []
diff --git a/meson_options.txt b/meson_options.txt
index 04843ea5..bb10b6c0 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -9,3 +9,4 @@ option('nvme-tests', type : 'boolean', value : false, description: 'Run tests ag
option('docs', type : 'combo', choices : ['false', 'html', 'man', 'all'], description : 'install documentation')
option('docs-build', type : 'boolean', value : false, description : 'build documentation')
option('pdc-enabled', type: 'boolean', value : false, description : 'set default Persistent Discovery Controllers behavior')
+option('hugepages', type: 'boolean', value : false, description : 'Enable support for hugetlbfs')

View File

@ -0,0 +1,25 @@
diff --git a/meson.build b/meson.build
index 24fa16e2..fc3ef0d7 100644
--- a/meson.build
+++ b/meson.build
@@ -66,9 +66,9 @@ endif
conf.set('CONFIG_JSONC', json_c_dep.found(), description: 'Is json-c available?')
# Check for libhugetlbfs availability (optional)
-if cc.has_header('hugetlbfs.h')
+if get_option('hugepages') and cc.has_header('hugetlbfs.h')
libhugetlbfs_dep = cc.find_library('hugetlbfs',
- required : false)
+ required : true)
have_libhugetlbfs = libhugetlbfs_dep.found()
else
libhugetlbfs_dep = []
diff --git a/meson_options.txt b/meson_options.txt
index 677942ae..752ecd40 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -10,3 +10,4 @@ option('docs', type : 'combo', choices : ['false', 'html', 'man', 'all'], descri
option('docs-build', type : 'boolean', value : false, description : 'build documentation')
option('pdc-enabled', type: 'boolean', value : false, description : 'set default Persistent Discovery Controllers behavior')
option('json-c', type: 'feature', value: 'auto', description: 'JSON suppport')
+option('hugepages', type: 'boolean', value : false, description : 'Enable support for hugetlbfs')

View File

@ -1,8 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>zmedico@gentoo.org</email>
<maintainer type="project">
<email>base-system@gentoo.org</email>
<name>Gentoo Base System</name>
</maintainer>
<upstream>
<remote-id type="github">linux-nvme/nvme-cli</remote-id>
@ -10,6 +11,5 @@
<use>
<flag name="json">Support JSON output via <pkg>dev-libs/json-c</pkg></flag>
<flag name="hugepages">Use huge pages for memory allocations via <pkg>sys-libs/libhugetlbfs</pkg></flag>
<flag name="uuid">UUID support via <pkg>sys-apps/util-linux</pkg></flag>
</use>
</pkgmetadata>

Some files were not shown because too many files have changed in this diff Show More