Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-fs/e2fsprogs/
Date: Fri, 31 Dec 2021 17:50:13
Message-Id: 1640972988.3af0ed49ea0b1b91c50a7180b3a3b307ef8d2fba.soap@gentoo
1 commit: 3af0ed49ea0b1b91c50a7180b3a3b307ef8d2fba
2 Author: David Seifert <soap <AT> gentoo <DOT> org>
3 AuthorDate: Fri Dec 31 17:49:48 2021 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Fri Dec 31 17:49:48 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3af0ed49
7
8 sys-fs/e2fsprogs: add 1.46.5
9
10 Signed-off-by: David Seifert <soap <AT> gentoo.org>
11
12 sys-fs/e2fsprogs/Manifest | 1 +
13 sys-fs/e2fsprogs/e2fsprogs-1.46.5.ebuild | 189 +++++++++++++++++++++++++++++++
14 2 files changed, 190 insertions(+)
15
16 diff --git a/sys-fs/e2fsprogs/Manifest b/sys-fs/e2fsprogs/Manifest
17 index 0fe82b8dc06c..6a975975148c 100644
18 --- a/sys-fs/e2fsprogs/Manifest
19 +++ b/sys-fs/e2fsprogs/Manifest
20 @@ -1,2 +1,3 @@
21 DIST e2fsprogs-1.42.9-mint-r1.patch.xz 9012 BLAKE2B ae6421587c3cca2f9b26805c5f8d236d3fecde78cc7df3776ae9c23c7f254d7240e06507568fdd2154a16113c47609a8143535ab9cb2925426d3c578d077ce26 SHA512 591a7c80d65082eebcdc455028be6ade05c9aae96c94f654106be0facef330a8875dae82891e6e3ad2b48dece2b4e1c1940dbc47cd3eba3e6eea3b5ddba9a8fc
22 DIST e2fsprogs-1.46.4.tar.xz 7035200 BLAKE2B 473f7fd3f521b94cdaa68e37784a518fc1919387dd114f31b5338f1b4c472f86b150229ec3dcae8b73eac95330c0dea729befc8cea08bcf1e455c0b6652d6d2b SHA512 7d9cfdf00ed58e66049585e8382fe4977088956421a0fb8155900c69afd8857309ad2b9301b3f74c9c0afa7287a0ddba2fd1538fcf57858b37a9ab712390016d
23 +DIST e2fsprogs-1.46.5.tar.xz 7040672 BLAKE2B 8d8c02e891c464782a7cff518c41d793fc73366b57e17d80ffc5afd96e6144e354290e667e9710509a9dde4e5dab7e7185c5bf084c5bfd26219f05e5e92e0830 SHA512 53282e1c524f62a95012b1aceef296d494f5238c82c9b08b29fbe6a803dbf7ccfdcd9124eb2f11fe2ff9de26387c78751a92c3217ca414f6db6242098a72d3fa
24
25 diff --git a/sys-fs/e2fsprogs/e2fsprogs-1.46.5.ebuild b/sys-fs/e2fsprogs/e2fsprogs-1.46.5.ebuild
26 new file mode 100644
27 index 000000000000..9ae9e56c0922
28 --- /dev/null
29 +++ b/sys-fs/e2fsprogs/e2fsprogs-1.46.5.ebuild
30 @@ -0,0 +1,189 @@
31 +# Copyright 1999-2021 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +
36 +inherit flag-o-matic systemd toolchain-funcs udev usr-ldscript multilib-minimal
37 +
38 +DESCRIPTION="Standard EXT2/EXT3/EXT4 filesystem utilities"
39 +HOMEPAGE="http://e2fsprogs.sourceforge.net/"
40 +SRC_URI="https://www.kernel.org/pub/linux/kernel/people/tytso/e2fsprogs/v${PV}/${P}.tar.xz
41 + elibc_mintlib? ( mirror://gentoo/${PN}-1.42.9-mint-r1.patch.xz )"
42 +
43 +LICENSE="GPL-2 BSD"
44 +SLOT="0"
45 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
46 +IUSE="cron fuse lto nls static-libs +threads +tools elibc_FreeBSD"
47 +
48 +RDEPEND="
49 + !sys-libs/${PN}-libs
50 + cron? ( sys-fs/lvm2[-device-mapper-only(-)] )
51 + fuse? ( sys-fs/fuse:0 )
52 + nls? ( virtual/libintl )
53 + tools? ( >=sys-apps/util-linux-2.16 )"
54 +DEPEND="${RDEPEND}"
55 +BDEPEND="virtual/pkgconfig
56 + sys-apps/texinfo
57 + nls? ( sys-devel/gettext )"
58 +
59 +PATCHES=(
60 + "${FILESDIR}"/${PN}-1.40-fbsd.patch
61 + "${FILESDIR}"/${PN}-1.42.13-fix-build-cflags.patch #516854
62 +
63 + # Upstream patches (can usually removed with next version bump)
64 +)
65 +
66 +pkg_setup() {
67 + if use tools ; then
68 + MULTILIB_WRAPPED_HEADERS=(
69 + /usr/include/ext2fs/ext2_types.h
70 + )
71 + fi
72 +}
73 +
74 +src_prepare() {
75 + if [[ ${CHOST} == *-mint* ]] ; then
76 + PATCHES+=( "${WORKDIR}"/${PN}-1.42.9-mint-r1.patch )
77 + fi
78 +
79 + default
80 +
81 + cp doc/RelNotes/v${PV}.txt ChangeLog || die "Failed to copy Release Notes"
82 +
83 + # Get rid of doc -- we don't use them. This also prevents a sandbox
84 + # violation due to mktexfmt invocation
85 + rm -r doc || die "Failed to remove doc dir"
86 +
87 + # prevent included intl cruft from building #81096
88 + sed -i -r \
89 + -e 's:@LIBINTL@:@LTLIBINTL@:' \
90 + MCONFIG.in || die 'intl cruft'
91 +}
92 +
93 +multilib_src_configure() {
94 + # Keep the package from doing silly things #261411
95 + export VARTEXFONTS="${T}/fonts"
96 +
97 + # needs open64() prototypes and friends
98 + append-cppflags -D_GNU_SOURCE
99 +
100 + local myeconfargs=(
101 + --with-root-prefix="${EPREFIX}"
102 + $(use_with cron crond-dir "${EPREFIX}/etc/cron.d")
103 + --with-systemd-unit-dir="$(systemd_get_systemunitdir)"
104 + --with-udev-rules-dir="${EPREFIX}$(get_udevdir)/rules.d"
105 + --enable-symlink-install
106 + --enable-elf-shlibs
107 + $(tc-has-tls || echo --disable-tls)
108 + $(multilib_native_use_enable fuse fuse2fs)
109 + $(use_enable nls)
110 + $(multilib_native_use_enable tools e2initrd-helper)
111 + --disable-fsck
112 + --disable-uuidd
113 + $(use_enable lto)
114 + $(use_with threads pthread)
115 + )
116 +
117 + # we use blkid/uuid from util-linux now
118 + if use kernel_linux ; then
119 + export ac_cv_lib_{uuid_uuid_generate,blkid_blkid_get_cache}=yes
120 + myeconfargs+=( --disable-lib{blkid,uuid} )
121 + fi
122 +
123 + ac_cv_path_LDCONFIG=: \
124 + ECONF_SOURCE="${S}" \
125 + CC="$(tc-getCC)" \
126 + BUILD_CC="$(tc-getBUILD_CC)" \
127 + BUILD_LD="$(tc-getBUILD_LD)" \
128 + econf "${myeconfargs[@]}"
129 +
130 + if [[ ${CHOST} != *-uclibc ]] && grep -qs 'USE_INCLUDED_LIBINTL.*yes' config.{log,status} ; then
131 + eerror "INTL sanity check failed, aborting build."
132 + eerror "Please post your ${S}/config.log file as an"
133 + eerror "attachment to https://bugs.gentoo.org/show_bug.cgi?id=81096"
134 + die "Preventing included intl cruft from building"
135 + fi
136 +}
137 +
138 +multilib_src_compile() {
139 + if ! multilib_is_native_abi || ! use tools ; then
140 + emake -C lib/et V=1
141 + emake -C lib/ss V=1
142 + if use tools ; then
143 + emake -C lib/ext2fs V=1
144 + emake -C lib/e2p V=1
145 + fi
146 + return 0
147 + fi
148 +
149 + emake V=1
150 +
151 + # Build the FreeBSD helper
152 + if use elibc_FreeBSD ; then
153 + cp "${FILESDIR}"/fsck_ext2fs.c . || die
154 + emake V=1 fsck_ext2fs
155 + fi
156 +}
157 +
158 +multilib_src_test() {
159 + if multilib_is_native_abi ; then
160 + emake V=1 check
161 + else
162 + # For non-native, there's no binaries to test. Just libraries.
163 + emake -C lib/et V=1 check
164 + emake -C lib/ss V=1 check
165 + fi
166 +}
167 +
168 +multilib_src_install() {
169 + if ! multilib_is_native_abi || ! use tools ; then
170 + emake -C lib/et V=1 DESTDIR="${D}" install
171 + emake -C lib/ss V=1 DESTDIR="${D}" install
172 +
173 + if use tools ; then
174 + emake -C lib/ext2fs V=1 DESTDIR="${D}" install
175 + emake -C lib/e2p V=1 DESTDIR="${D}" install
176 + fi
177 + else
178 + emake \
179 + STRIP=: \
180 + DESTDIR="${D}" \
181 + install
182 +
183 + # Move shared libraries to /lib/, install static libraries to
184 + # /usr/lib/, and install linker scripts to /usr/lib/.
185 + gen_usr_ldscript -a e2p ext2fs
186 +
187 + if use elibc_FreeBSD ; then
188 + # Install helpers for us
189 + into /
190 + dosbin "${S}"/fsck_ext2fs
191 + fi
192 + fi
193 +
194 + gen_usr_ldscript -a com_err ss $(usex kernel_linux '' 'uuid blkid')
195 +
196 + # configure doesn't have an option to disable static libs :/
197 + if ! use static-libs ; then
198 + find "${ED}" -name '*.a' -delete || die
199 + fi
200 +}
201 +
202 +multilib_src_install_all() {
203 + einstalldocs
204 +
205 + if use tools ; then
206 + insinto /etc
207 + doins "${FILESDIR}"/e2fsck.conf
208 +
209 + if use elibc_FreeBSD ; then
210 + into /
211 + doman "${FILESDIR}"/fsck_ext2fs.8
212 +
213 + # filefrag is linux only
214 + rm \
215 + "${ED}"/usr/sbin/filefrag \
216 + "${ED}"/usr/share/man/man8/filefrag.8 || die
217 + fi
218 + fi
219 +}