Gentoo Archives: gentoo-commits

From: Mikle Kolyada <zlogene@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/libgcrypt/
Date: Sun, 29 Aug 2021 15:54:04
Message-Id: 1630252431.106a61ba6125c38b6fde5c9e21ec43794179e981.zlogene@gentoo
1 commit: 106a61ba6125c38b6fde5c9e21ec43794179e981
2 Author: Mikle Kolyada <zlogene <AT> gentoo <DOT> org>
3 AuthorDate: Sun Aug 29 15:53:51 2021 +0000
4 Commit: Mikle Kolyada <zlogene <AT> gentoo <DOT> org>
5 CommitDate: Sun Aug 29 15:53:51 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=106a61ba
7
8 dev-libs/libgcrypt: add 1.9.4
9
10 Signed-off-by: Mikle Kolyada <zlogene <AT> gentoo.org>
11
12 dev-libs/libgcrypt/Manifest | 1 +
13 dev-libs/libgcrypt/libgcrypt-1.9.4.ebuild | 86 +++++++++++++++++++++++++++++++
14 2 files changed, 87 insertions(+)
15
16 diff --git a/dev-libs/libgcrypt/Manifest b/dev-libs/libgcrypt/Manifest
17 index 41d2164ca2a..1d1e4d9d62a 100644
18 --- a/dev-libs/libgcrypt/Manifest
19 +++ b/dev-libs/libgcrypt/Manifest
20 @@ -4,3 +4,4 @@ DIST libgcrypt-1.8.8.tar.bz2 2987685 BLAKE2B 7b590c06d91403f1bbfa108379b3747271e
21 DIST libgcrypt-1.9.1.tar.bz2 3202683 BLAKE2B 102a61c855fb4a9e5c9433f52988ea87db7672de6586ed47f888526369d0ef8ad640752ca1ef144c2db73ce90464d6624cc3b12dbdeaf568d706222af3955672 SHA512 e8a028724cf5476fff0ca82c5c279a64b3bc5d1fd1472b784df4084b185266825baffc49e27b90db7453c8faef68cd0b8264f379abacee629bbdf6b11f2a28d6
22 DIST libgcrypt-1.9.2.tar.bz2 3206187 BLAKE2B e0ceb02b0c26a7246c4146640a9dcea01429a365bd484532b9d85fdb0c8f4ac1308862e70899a1593f4665e4b2d16ceaa10029702f67720897975258a25d8ab0 SHA512 d2e3dc89788763229f554382b3cf0c3a2680f774258abc4c1fd9ef1ad44920d57d14422af9b6b405e42742e691d19ab2ee458fddf057e778964519eee090f016
23 DIST libgcrypt-1.9.3.tar.bz2 3219061 BLAKE2B 51a6273ba28829c016d9a93fffa181aec24170d0e4d3a363c788f336219e1531274344adeea289f3cc09161fdb2e56846551367a8ac880b14e03a52ab0dd551a SHA512 977e766887c14f19aa1b9fcc0214303036a649e41cd4278de76da7d734cf36888e2e1b6275590dac523dcb4ba8ab07993e6ee8209fd5f1a3383d738b09a060d6
24 +DIST libgcrypt-1.9.4.tar.bz2 3239704 BLAKE2B b8244bc12a68955797b0c2b474ac5c95df1014231f7180a2ffa113e3aacedc98eed60ee1e4b30b032a5fcd6a04855ae07142c223906d5db9c28328a71e014f33 SHA512 d0e117ac73c94d70e9521ee1e6328691498cc8328f8c4e21338096908f5c04c7b838966eb63d59494565f4e19f506c07dab4f4d922150d75610d9f7b57abbf60
25
26 diff --git a/dev-libs/libgcrypt/libgcrypt-1.9.4.ebuild b/dev-libs/libgcrypt/libgcrypt-1.9.4.ebuild
27 new file mode 100644
28 index 00000000000..584154b6ff2
29 --- /dev/null
30 +++ b/dev-libs/libgcrypt/libgcrypt-1.9.4.ebuild
31 @@ -0,0 +1,86 @@
32 +# Copyright 1999-2021 Gentoo Authors
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI=7
36 +
37 +inherit autotools flag-o-matic multilib-minimal toolchain-funcs
38 +
39 +DESCRIPTION="General purpose crypto library based on the code used in GnuPG"
40 +HOMEPAGE="https://www.gnupg.org/"
41 +SRC_URI="mirror://gnupg/${PN}/${P}.tar.bz2"
42 +
43 +LICENSE="LGPL-2.1 MIT"
44 +SLOT="0/20" # subslot = soname major version
45 +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"
46 +IUSE="+asm cpu_flags_arm_neon cpu_flags_x86_aes cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_padlock cpu_flags_x86_sha cpu_flags_x86_sse4_1 doc o-flag-munging static-libs"
47 +
48 +RDEPEND=">=dev-libs/libgpg-error-1.25[${MULTILIB_USEDEP}]"
49 +DEPEND="${RDEPEND}"
50 +BDEPEND="doc? ( virtual/texi2dvi )"
51 +
52 +PATCHES=(
53 + "${FILESDIR}"/${PN}-multilib-syspath.patch
54 +)
55 +
56 +MULTILIB_CHOST_TOOLS=(
57 + /usr/bin/libgcrypt-config
58 +)
59 +
60 +src_prepare() {
61 + default
62 + eautoreconf
63 +}
64 +
65 +multilib_src_configure() {
66 + if [[ ${CHOST} == *86*-solaris* ]] ; then
67 + # ASM code uses GNU ELF syntax, divide in particular, we need to
68 + # allow this via ASFLAGS, since we don't have a flag-o-matic
69 + # function for that, we'll have to abuse cflags for this
70 + append-cflags -Wa,--divide
71 + fi
72 + local myeconfargs=(
73 + CC_FOR_BUILD="$(tc-getBUILD_CC)"
74 +
75 + --enable-noexecstack
76 + $(use_enable cpu_flags_arm_neon neon-support)
77 + $(use_enable cpu_flags_x86_aes aesni-support)
78 + $(use_enable cpu_flags_x86_avx avx-support)
79 + $(use_enable cpu_flags_x86_avx2 avx2-support)
80 + $(use_enable cpu_flags_x86_padlock padlock-support)
81 + $(use_enable cpu_flags_x86_sha shaext-support)
82 + $(use_enable cpu_flags_x86_sse4_1 sse41-support)
83 + # required for sys-power/suspend[crypt], bug 751568
84 + $(use_enable static-libs static)
85 + $(use_enable o-flag-munging O-flag-munging)
86 +
87 + # disabled due to various applications requiring privileges
88 + # after libgcrypt drops them (bug #468616)
89 + --without-capabilities
90 +
91 + # http://trac.videolan.org/vlc/ticket/620
92 + # causes bus-errors on sparc64-solaris
93 + $([[ ${CHOST} == *86*-darwin* ]] && echo "--disable-asm")
94 + $([[ ${CHOST} == sparcv9-*-solaris* ]] && echo "--disable-asm")
95 +
96 + $(use asm || echo "--disable-asm")
97 +
98 + GPG_ERROR_CONFIG="${ESYSROOT}/usr/bin/${CHOST}-gpg-error-config"
99 + )
100 + ECONF_SOURCE="${S}" econf "${myeconfargs[@]}" \
101 + $("${S}/configure" --help | grep -o -- '--without-.*-prefix')
102 +}
103 +
104 +multilib_src_compile() {
105 + default
106 + multilib_is_native_abi && use doc && VARTEXFONTS="${T}/fonts" emake -C doc gcrypt.pdf
107 +}
108 +
109 +multilib_src_install() {
110 + emake DESTDIR="${D}" install
111 + multilib_is_native_abi && use doc && dodoc doc/gcrypt.pdf
112 +}
113 +
114 +multilib_src_install_all() {
115 + default
116 + find "${ED}" -type f -name '*.la' -delete || die
117 +}