1 # Maintainer: David Runge <dvzrv@archlinux.org>
2 # Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
3 # Maintainer: Lukas Fleischer <lfleischer@archlinux.org>
4 # Contributor: Gaetan Bisson <bisson@archlinux.org>
5 # Contributor: Tobias Powalowski <tpowa@archlinux.org>
6 # Contributor: Andreas Radke <andyrtr@archlinux.org>
7 # Contributor: Judd Vinet <jvinet@zeroflux.org>
12 pkgdesc='Complete and free implementation of the OpenPGP standard'
14 url='https://www.gnupg.org/'
15 license=(BSD custom custom:CC0 GPL2 GPL3 LGPL3 LGPL2.1 MIT)
23 'libassuan' 'libassuan.so'
26 'readline' 'libreadline.so'
30 makedepends=('libldap' 'libusb-compat' 'pcsclite')
31 checkdepends=('openssh')
33 'libldap: gpg2keys_ldap'
34 'libusb-compat: scdaemon'
37 install=$pkgname.install
39 "https://gnupg.org/ftp/gcrypt/${pkgname}/${pkgname}-${pkgver}.tar.bz2"{,.sig}
40 'drop-import-clean.patch'
41 'avoid-beta-warning.patch'
43 sha256sums=('13f3291007a5e8546fcb7bc0c6610ce44aaa9b3995059d4f8145ba09fd5be3e1'
45 '02d375f0045f56f7dd82bacdb5ce559afd52ded8b75f6b2673c39ec666e81abc'
46 '22fdf9490fad477f225e731c417867d9e7571ac654944e8be63a1fbaccd5c62d')
47 b2sums=('0be2965a646a8636a127f89329030860908b0bbc447381782527459aed85f5276c29e7a2c89f87cb715407d9f1aabbf3ae1765073764d05e422035e8d5962569'
49 'd598015e7f27b27840667d1656c083b4ad85d6acdd312e9929854067313a5f28415ee7eecf4d84a4b8da0385b667aaa01a9743461f5c785402a56c238274e376'
50 '7ea069e81e2d91a3154bcb62516b4b599f34596de277f95ad1ccaba73869c4f84f94f063b65026ba0bc8a72c0fd8e8e182b82346964f67ea78166b6399c923c5')
52 '5B80C5754298F0CB55D8ED6ABCEF7E294B092E28' # Andre Heinecke (Release Signing Key)
53 '6DAA6E64A76D2840571B4902528897B826403ADA' # Werner Koch (dist signing 2020)
54 'AC8E115BF73E2D8D47FA9908E98E9B2D19C6C8BD' # Niibe Yutaka (GnuPG Release Key)
55 '02F38DFF731FF97CB039A1DA549E695E905BA208' # GnuPG.com (Release Signing Key 2021)
59 cd "${pkgname}-${pkgver}"
62 for src in "${source[@]}"; do
65 [[ $src = *.patch ]] || continue
66 msg2 "Applying patch $src..."
67 patch -Np1 < "../$src"
70 # improve reproducibility
77 cd "${pkgname}-${pkgver}"
82 --libexecdir=/usr/lib/gnupg \
83 --enable-maintainer-mode \
89 cd "${pkgname}-${pkgver}"
94 local units=({dirmngr,gpg-agent{,-{browser,extra,ssh}}}.socket)
95 local socket_target_dir="$pkgdir/usr/lib/systemd/user/sockets.target.wants/"
98 cd "${pkgname}-${pkgver}"
99 make DESTDIR="${pkgdir}" install
100 ln -s gpg "${pkgdir}"/usr/bin/gpg2
101 ln -s gpgv "${pkgdir}"/usr/bin/gpgv2
103 install -Dm 644 doc/examples/systemd-user/*.* -t "${pkgdir}/usr/lib/systemd/user"
104 install -Dm 644 COPYING.{CC0,other} -t "${pkgdir}/usr/share/licenses/$pkgname/"
106 install -vdm 755 "$socket_target_dir"
107 for unit in "${units[@]}"; do
108 ln -sv "../$unit" "$socket_target_dir$unit"