Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/elfutils/
Date: Thu, 03 Nov 2022 06:46:08
Message-Id: 1667457952.bcbb7ea6de9193425a1ea6e47482ca2a4a741921.sam@gentoo
1 commit: bcbb7ea6de9193425a1ea6e47482ca2a4a741921
2 Author: Sam James <sam <AT> gentoo <DOT> org>
3 AuthorDate: Thu Nov 3 06:45:52 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Thu Nov 3 06:45:52 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bcbb7ea6
7
8 dev-libs/elfutils: add 0.188
9
10 Signed-off-by: Sam James <sam <AT> gentoo.org>
11
12 dev-libs/elfutils/Manifest | 2 +
13 dev-libs/elfutils/elfutils-0.188.ebuild | 123 ++++++++++++++++++++++++++++++++
14 2 files changed, 125 insertions(+)
15
16 diff --git a/dev-libs/elfutils/Manifest b/dev-libs/elfutils/Manifest
17 index 69cbb014c06e..624a9cb966f2 100644
18 --- a/dev-libs/elfutils/Manifest
19 +++ b/dev-libs/elfutils/Manifest
20 @@ -1,3 +1,5 @@
21 DIST elfutils-0.187-patches.tar.xz 2804 BLAKE2B 77cbd0666d8da3d5229baaba6605c84e7990200f39bfb72b2008eb2527e4567abd90c93c291cc0c8f3c10bbf97758ccf5877cbdae823780cf8dc97ff4ff2f932 SHA512 d056fdd6ae0e71471087af472a72384d6e73ff2d7fe1b708b5ec9f091a913c8327197660132b7a6619a0db86534715507ef67ee91691a00a591c1d24c55a99f4
22 DIST elfutils-0.187.tar.bz2 9240221 BLAKE2B 00ba3efa689d137808f5f53ecda93fd006be0c18d690ce76616ed1dba442281098579fa4b9a9e91b8ba865a3de15968f0ae06703a7b50b15c48a4beb5c970a46 SHA512 a9b9e32b503b8b50a62d4e4001097ed2721d3475232a6380e6b9853bd1647aec016440c0ca7ceb950daf1144f8db9814ab43cf33cc0ebef7fc91e9e775c9e874
23 DIST elfutils-0.187.tar.bz2.sig 310 BLAKE2B b23f656de269030cc3dd518a008e22e22726138a3bd619ad269166d3b9fac4b1064d98c81a02fcc6250ca1a996cc3e81322b50e7692fe23cbee92e2908f0300d SHA512 2619d8d537364386491d5e54f2add7ffa5bab21cd19c94a29249f2d9c5cc5dac53e2031a5515268ddeee4799b71115a5d98bdbcafd361aa75bcc13a1d9b70b14
24 +DIST elfutils-0.188.tar.bz2 9112977 BLAKE2B 6b0474f1436eaf6af73b735b9b2ddd5448ab9c03fbaa0be745a31c89ae8f15b0e21a651409c38643ca125794ce82c19d7b46db4a079f3e72cb919d643560e7a4 SHA512 585551b2d937d19d1becfc2f28935db1dd1a3d25571a62f322b70ac8da98c1a741a55d070327705df6c3e2ee026652e0b9a3c733b050a0b0ec5f2fc75d5b74b5
25 +DIST elfutils-0.188.tar.bz2.sig 310 BLAKE2B c8d9135cffde3b1dd337b692d5351855cf799915d3ebd553327febaac192bd2f108b3f45a6376d458e179390a1ceaf4809762cdc40ea1e05fed0214ac33ed56e SHA512 4cc8a7417d244e319a1650d71b1831660cfe41afc7c73e9c83d1f076f4013fe15247e8b4f5e12a5396d83c4f1c7663ca4be5ea42bff3dc23263f85331fd9d566
26
27 diff --git a/dev-libs/elfutils/elfutils-0.188.ebuild b/dev-libs/elfutils/elfutils-0.188.ebuild
28 new file mode 100644
29 index 000000000000..13a2eb582fa0
30 --- /dev/null
31 +++ b/dev-libs/elfutils/elfutils-0.188.ebuild
32 @@ -0,0 +1,123 @@
33 +# Copyright 2003-2022 Gentoo Authors
34 +# Distributed under the terms of the GNU General Public License v2
35 +
36 +EAPI=8
37 +
38 +VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/elfutils.gpg
39 +inherit flag-o-matic multilib-minimal verify-sig
40 +
41 +DESCRIPTION="Libraries/utilities to handle ELF objects (drop in replacement for libelf)"
42 +HOMEPAGE="https://sourceware.org/elfutils/"
43 +SRC_URI="https://sourceware.org/elfutils/ftp/${PV}/${P}.tar.bz2"
44 +SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${PN}-0.187-patches.tar.xz"
45 +SRC_URI+=" verify-sig? ( https://sourceware.org/elfutils/ftp/${PV}/${P}.tar.bz2.sig )"
46 +
47 +LICENSE="|| ( GPL-2+ LGPL-3+ ) utils? ( GPL-3+ )"
48 +SLOT="0"
49 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
50 +IUSE="bzip2 lzma nls static-libs test +utils valgrind zstd"
51 +RESTRICT="!test? ( test )"
52 +
53 +RDEPEND="
54 + !dev-libs/libelf
55 + >=sys-libs/zlib-1.2.8-r1[static-libs?,${MULTILIB_USEDEP}]
56 + bzip2? ( >=app-arch/bzip2-1.0.6-r4[static-libs?,${MULTILIB_USEDEP}] )
57 + lzma? ( >=app-arch/xz-utils-5.0.5-r1[static-libs?,${MULTILIB_USEDEP}] )
58 + zstd? ( app-arch/zstd:=[static-libs?,${MULTILIB_USEDEP}] )
59 + elibc_musl? (
60 + dev-libs/libbsd
61 + sys-libs/argp-standalone
62 + sys-libs/fts-standalone
63 + sys-libs/obstack-standalone
64 + )
65 +"
66 +DEPEND="
67 + ${RDEPEND}
68 + valgrind? ( dev-util/valgrind )
69 +"
70 +BDEPEND="
71 + >=sys-devel/flex-2.5.4a
72 + sys-devel/m4
73 + nls? ( sys-devel/gettext )
74 + verify-sig? ( sec-keys/openpgp-keys-elfutils )
75 +"
76 +
77 +PATCHES=(
78 + "${WORKDIR}"/${PN}-0.187-patches/
79 +)
80 +
81 +src_unpack() {
82 + if use verify-sig ; then
83 + # Needed for downloaded patch (which is unsigned, which is fine)
84 + verify-sig_verify_detached "${DISTDIR}"/${P}.tar.bz2{,.sig}
85 + fi
86 +
87 + default
88 +}
89 +
90 +src_prepare() {
91 + default
92 +
93 + if use elibc_musl; then
94 + eapply "${WORKDIR}"/${PN}-0.187-patches/musl/
95 + fi
96 +
97 + if ! use static-libs; then
98 + sed -i -e '/^lib_LIBRARIES/s:=.*:=:' -e '/^%.os/s:%.o$::' lib{asm,dw,elf}/Makefile.in || die
99 + fi
100 +
101 + # https://sourceware.org/PR23914
102 + sed -i 's:-Werror::' */Makefile.in || die
103 +}
104 +
105 +src_configure() {
106 + # bug #407135
107 + use test && append-flags -g
108 +
109 + # Symbol aliases are implemented as asm statements.
110 + # Will require porting: https://gcc.gnu.org/PR48200
111 + filter-flags '-flto*'
112 +
113 + multilib-minimal_src_configure
114 +}
115 +
116 +multilib_src_configure() {
117 + local myeconfargs=(
118 + $(use_enable nls)
119 + --disable-debuginfod
120 + --disable-libdebuginfod
121 +
122 + # explicitly disable thread safety, it's not recommended by upstream
123 + # doesn't build either on musl.
124 + --disable-thread-safety
125 +
126 + # Valgrind option is just for running tests under it; dodgy under sandbox
127 + # and indeed even w/ glibc with newer instructions.
128 + --disable-valgrind
129 + --program-prefix="eu-"
130 + --with-zlib
131 + $(use_with bzip2 bzlib)
132 + $(use_with lzma)
133 + $(use_with zstd)
134 + )
135 +
136 + ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
137 +}
138 +
139 +multilib_src_test() {
140 + env LD_LIBRARY_PATH="${BUILD_DIR}/libelf:${BUILD_DIR}/libebl:${BUILD_DIR}/libdw:${BUILD_DIR}/libasm" \
141 + LC_ALL="C" \
142 + emake check VERBOSE=1
143 +}
144 +
145 +multilib_src_install_all() {
146 + einstalldocs
147 +
148 + dodoc NOTES
149 +
150 + # These build quick, and are needed for most tests, so don't
151 + # disable their building when the USE flag is disabled.
152 + if ! use utils; then
153 + rm -rf "${ED}"/usr/bin || die
154 + fi
155 +}