diff options
Diffstat (limited to 'contrib/packages/arch/gnunet')
-rw-r--r-- | contrib/packages/arch/gnunet/.SRCINFO | 72 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/PKGBUILD | 118 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/gnunet-system.service | 13 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/gnunet-uri.desktop | 9 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/gnunet-user.conf | 3 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/gnunet-user.service | 10 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/gnunet.install | 54 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/gnunet.sysusers | 3 | ||||
-rw-r--r-- | contrib/packages/arch/gnunet/gnunet.tmpfiles | 9 |
9 files changed, 291 insertions, 0 deletions
diff --git a/contrib/packages/arch/gnunet/.SRCINFO b/contrib/packages/arch/gnunet/.SRCINFO new file mode 100644 index 000000000..438f91230 --- /dev/null +++ b/contrib/packages/arch/gnunet/.SRCINFO | |||
@@ -0,0 +1,72 @@ | |||
1 | pkgbase = gnunet | ||
2 | pkgdesc = A framework for secure peer-to-peer networking | ||
3 | pkgver = 0.17.0 | ||
4 | pkgrel = 1 | ||
5 | url = http://gnunet.org | ||
6 | install = gnunet.install | ||
7 | arch = i686 | ||
8 | arch = x86_64 | ||
9 | license = AGPL | ||
10 | makedepends = bluez-libs | ||
11 | makedepends = libpulse | ||
12 | makedepends = libtool | ||
13 | makedepends = opus | ||
14 | makedepends = pkgconfig | ||
15 | makedepends = postgresql | ||
16 | makedepends = python | ||
17 | depends = brotli | ||
18 | depends = gettext | ||
19 | depends = gnurl | ||
20 | depends = gnutls | ||
21 | depends = iptables | ||
22 | depends = jansson | ||
23 | depends = libextractor | ||
24 | depends = libgcrypt | ||
25 | depends = libidn2 | ||
26 | depends = libmicrohttpd | ||
27 | depends = libsodium | ||
28 | depends = libtool | ||
29 | depends = libunistring | ||
30 | depends = nss | ||
31 | depends = openssl | ||
32 | depends = sqlite | ||
33 | depends = which | ||
34 | depends = zlib | ||
35 | optdepends = bluez: for bluetooth transport | ||
36 | optdepends = gnunet-gtk: for handling the gnunet:// URI scheme | ||
37 | optdepends = libgabe: for Attribute-Based Encryption | ||
38 | optdepends = libogg: for conversation service | ||
39 | optdepends = libpabc: for re:claimID zero-knowledge privacy credentials | ||
40 | optdepends = libpulse: for conversation service | ||
41 | optdepends = miniupnpc: for NAT uPnP support | ||
42 | optdepends = mysql: for an alternative to sqlite in the database plugin | ||
43 | optdepends = opus: for conversation service | ||
44 | optdepends = pbc: for Attribute-Based Encryption | ||
45 | optdepends = postgresql: for an alternative to sqlite in the database plugin | ||
46 | optdepends = python: for test suite | ||
47 | optdepends = texi2mdoc: for automatic mdoc generation | ||
48 | optdepends = texinfo: for building the documentation | ||
49 | optdepends = texlive-core: for generating GNS business cards via gnunet-bcd | ||
50 | optdepends = zbar: for reading/writing QR codes using gnunet-qr | ||
51 | conflicts = gnunet-git | ||
52 | conflicts = gnunet-bin | ||
53 | backup = etc/gnunet.conf | ||
54 | source = ftp://ftp.gnu.org/gnu/gnunet/gnunet-0.17.0.tar.gz | ||
55 | source = ftp://ftp.gnu.org/gnu/gnunet/gnunet-0.17.0.tar.gz.sig | ||
56 | source = gnunet-system.service | ||
57 | source = gnunet.sysusers | ||
58 | source = gnunet.tmpfiles | ||
59 | source = gnunet-uri.desktop | ||
60 | source = gnunet-user.conf | ||
61 | source = gnunet-user.service | ||
62 | validpgpkeys = 3D11063C10F98D14BD24D1470B0998EF86F59B6A | ||
63 | sha256sums = 6b2f7bf34c3c3986f2c294f04e881dda9db8ef636c0e78ebcf8084b8a47d49ca | ||
64 | sha256sums = SKIP | ||
65 | sha256sums = 163818b89beddcaf78937daba5bdf0ae060b2975de0731aa13d1ccdd813cf262 | ||
66 | sha256sums = 66299dbbdd0219d2f5f0520e69fc094f38f789724d973c2f63a421257ea4f755 | ||
67 | sha256sums = 5c34e1ecc6208900426f8e399e8c3edbef12cce19eba605fd7364ddb3547d9f0 | ||
68 | sha256sums = 98e4e1d6d4fd7c7fd05d9e16402c95f1e7afeb4b97c8c68ac63e8abd11ff4ee7 | ||
69 | sha256sums = 3f17b9ed2c1f8cc0f919fe477df99678c17778a31f1eeb56517e285e3cef30f2 | ||
70 | sha256sums = 60caee20b53bcc69522556b35ac3d35d89e28c49b9a22a2ed5121df4a2c33be5 | ||
71 | |||
72 | pkgname = gnunet | ||
diff --git a/contrib/packages/arch/gnunet/PKGBUILD b/contrib/packages/arch/gnunet/PKGBUILD new file mode 100644 index 000000000..2dfcdd6ec --- /dev/null +++ b/contrib/packages/arch/gnunet/PKGBUILD | |||
@@ -0,0 +1,118 @@ | |||
1 | # Maintainer: grufo <madmurphy333 AT gmail DOT com> | ||
2 | # Contributor: redfish <redfish AT galactica DOT pw> | ||
3 | # Contributor: kertase <kertase AT gmail DOT com> | ||
4 | # Contributor: Sergej Pupykin <pupykin DOT s+arch AT gmail.com> | ||
5 | # Contributor: wahnby <wahnby AT yahoo DOT fr> | ||
6 | |||
7 | pkgname='gnunet' | ||
8 | pkgver='0.17.0' | ||
9 | pkgrel=1 | ||
10 | pkgdesc='A framework for secure peer-to-peer networking' | ||
11 | arch=('i686' 'x86_64') | ||
12 | url="http://${pkgname}.org" | ||
13 | license=('AGPL') | ||
14 | conflicts=("${pkgname}-git" "${pkgname}-bin") | ||
15 | depends=('brotli' 'gettext' 'gnurl' 'gnutls' 'iptables' 'jansson' | ||
16 | 'libextractor' 'libgcrypt' 'libidn2' 'libmicrohttpd' 'libsodium' | ||
17 | 'libtool' 'libunistring' 'nss' 'openssl' 'sqlite' 'which' 'zlib') | ||
18 | makedepends=('bluez-libs' 'libpulse' 'libtool' 'opus' 'pkgconfig' 'postgresql' | ||
19 | 'python') | ||
20 | optdepends=('bluez: for bluetooth transport' | ||
21 | 'gnunet-gtk: for handling the gnunet:// URI scheme' | ||
22 | 'libgabe: for Attribute-Based Encryption' | ||
23 | 'libogg: for conversation service' | ||
24 | 'libpabc: for re:claimID zero-knowledge privacy credentials' | ||
25 | 'libpulse: for conversation service' | ||
26 | 'miniupnpc: for NAT uPnP support' | ||
27 | 'mysql: for an alternative to sqlite in the database plugin' | ||
28 | 'opus: for conversation service' | ||
29 | 'pbc: for Attribute-Based Encryption' | ||
30 | 'postgresql: for an alternative to sqlite in the database plugin' | ||
31 | 'python: for test suite' | ||
32 | 'texi2mdoc: for automatic mdoc generation' | ||
33 | 'texinfo: for building the documentation' | ||
34 | 'texlive-core: for generating GNS business cards via gnunet-bcd' | ||
35 | 'zbar: for reading/writing QR codes using gnunet-qr') | ||
36 | backup=("etc/${pkgname}.conf") | ||
37 | source=("ftp://ftp.gnu.org/gnu/${pkgname}/${pkgname}-${pkgver}.tar.gz"{,.sig} | ||
38 | "${pkgname}-system.service" | ||
39 | "${pkgname}.sysusers" | ||
40 | "${pkgname}.tmpfiles" | ||
41 | "${pkgname}-uri.desktop" | ||
42 | "${pkgname}-user.conf" | ||
43 | "${pkgname}-user.service") | ||
44 | install="${pkgname}.install" | ||
45 | validpgpkeys=('3D11063C10F98D14BD24D1470B0998EF86F59B6A') | ||
46 | sha256sums=('6b2f7bf34c3c3986f2c294f04e881dda9db8ef636c0e78ebcf8084b8a47d49ca' | ||
47 | 'SKIP' | ||
48 | '163818b89beddcaf78937daba5bdf0ae060b2975de0731aa13d1ccdd813cf262' | ||
49 | '66299dbbdd0219d2f5f0520e69fc094f38f789724d973c2f63a421257ea4f755' | ||
50 | '5c34e1ecc6208900426f8e399e8c3edbef12cce19eba605fd7364ddb3547d9f0' | ||
51 | '98e4e1d6d4fd7c7fd05d9e16402c95f1e7afeb4b97c8c68ac63e8abd11ff4ee7' | ||
52 | '3f17b9ed2c1f8cc0f919fe477df99678c17778a31f1eeb56517e285e3cef30f2' | ||
53 | '60caee20b53bcc69522556b35ac3d35d89e28c49b9a22a2ed5121df4a2c33be5') | ||
54 | |||
55 | prepare() { | ||
56 | |||
57 | cd "${srcdir}/${pkgname}-${pkgver}" | ||
58 | |||
59 | export GNUNET_PREFIX='/usr/lib' | ||
60 | autoreconf -i | ||
61 | |||
62 | } | ||
63 | |||
64 | build() { | ||
65 | |||
66 | cd "${srcdir}/${pkgname}-${pkgver}" | ||
67 | |||
68 | ./configure --prefix='/usr' --enable-experimental | ||
69 | make | ||
70 | |||
71 | } | ||
72 | |||
73 | package() { | ||
74 | |||
75 | cd "${srcdir}/${pkgname}-${pkgver}" | ||
76 | |||
77 | make DESTDIR="${pkgdir}" install | ||
78 | |||
79 | install -dm755 "${pkgdir}/usr/lib/systemd/system" | ||
80 | install -Dm644 "${srcdir}/${pkgname}-system.service" \ | ||
81 | "${pkgdir}/usr/lib/systemd/system/${pkgname}.service" | ||
82 | |||
83 | install -dm755 "${pkgdir}/usr/lib/systemd/user" | ||
84 | install -Dm644 "${srcdir}/${pkgname}-user.service" \ | ||
85 | "${pkgdir}/usr/lib/systemd/user/${pkgname}.service" | ||
86 | |||
87 | install -dm755 "${pkgdir}/usr/lib/sysusers.d" | ||
88 | install -Dm644 "${srcdir}/${pkgname}.sysusers" \ | ||
89 | "${pkgdir}/usr/lib/sysusers.d/${pkgname}.conf" | ||
90 | |||
91 | install -dm755 "${pkgdir}/usr/lib/tmpfiles.d" | ||
92 | install -Dm644 "${srcdir}/${pkgname}.tmpfiles" \ | ||
93 | "${pkgdir}/usr/lib/tmpfiles.d/${pkgname}.conf" | ||
94 | |||
95 | install -dm755 "${pkgdir}/usr/share/applications" | ||
96 | install -Dm644 "${srcdir}/${pkgname}-uri.desktop" \ | ||
97 | "${pkgdir}/usr/share/applications/${pkgname}-uri.desktop" | ||
98 | |||
99 | install -dm700 "${pkgdir}/etc/skel/.config" | ||
100 | install -Dm600 "${srcdir}/${pkgname}-user.conf" \ | ||
101 | "${pkgdir}/etc/skel/.config/${pkgname}.conf" | ||
102 | |||
103 | # Automatically generate a configuration file using the content of | ||
104 | # `/usr/share/gnunet/config.d/` as model; in this way we can ensure | ||
105 | # that this configuration file is the one backed up with each update, | ||
106 | # while `/usr/share/gnunet/config.d/` is kept as immutable default | ||
107 | # configuration. | ||
108 | |||
109 | install -dm755 "${pkgdir}/etc" | ||
110 | |||
111 | { | ||
112 | echo "# /etc/${pkgname}.conf" | ||
113 | (cd "${pkgdir}" > /dev/null 2>&1 && find "usr/share/${pkgname}/config.d" -type f -name '*.conf' \ | ||
114 | -printf '\n\n# For the default values of the the following lines please refer to\n# /%p\n\n' \ | ||
115 | -exec cat '{}' ';') | ||
116 | } > "${pkgdir}/etc/${pkgname}.conf" | ||
117 | |||
118 | } | ||
diff --git a/contrib/packages/arch/gnunet/gnunet-system.service b/contrib/packages/arch/gnunet/gnunet-system.service new file mode 100644 index 000000000..b429caf46 --- /dev/null +++ b/contrib/packages/arch/gnunet/gnunet-system.service | |||
@@ -0,0 +1,13 @@ | |||
1 | [Unit] | ||
2 | Description=GNUnet system service | ||
3 | After=network.target | ||
4 | |||
5 | [Service] | ||
6 | Type=simple | ||
7 | User=gnunet | ||
8 | ExecStart=/usr/lib/gnunet/libexec/gnunet-service-arm -c /etc/gnunet.conf | ||
9 | StateDirectory=gnunet | ||
10 | StateDirectoryMode=0700 | ||
11 | |||
12 | [Install] | ||
13 | WantedBy=multi-user.target | ||
diff --git a/contrib/packages/arch/gnunet/gnunet-uri.desktop b/contrib/packages/arch/gnunet/gnunet-uri.desktop new file mode 100644 index 000000000..4f847d20f --- /dev/null +++ b/contrib/packages/arch/gnunet/gnunet-uri.desktop | |||
@@ -0,0 +1,9 @@ | |||
1 | [Desktop Entry] | ||
2 | Name=GNUnet URI | ||
3 | Exec=gnunet-uri %u | ||
4 | GenericName=URI handler for the GNUnet network | ||
5 | Icon=gnunet | ||
6 | Type=Application | ||
7 | Terminal=false | ||
8 | NoDisplay=true | ||
9 | MimeType=x-scheme-handler/gnunet; | ||
diff --git a/contrib/packages/arch/gnunet/gnunet-user.conf b/contrib/packages/arch/gnunet/gnunet-user.conf new file mode 100644 index 000000000..22f1fe37a --- /dev/null +++ b/contrib/packages/arch/gnunet/gnunet-user.conf | |||
@@ -0,0 +1,3 @@ | |||
1 | [arm] | ||
2 | START_SYSTEM_SERVICES = NO | ||
3 | START_USER_SERVICES = YES | ||
diff --git a/contrib/packages/arch/gnunet/gnunet-user.service b/contrib/packages/arch/gnunet/gnunet-user.service new file mode 100644 index 000000000..ae9f0d4f5 --- /dev/null +++ b/contrib/packages/arch/gnunet/gnunet-user.service | |||
@@ -0,0 +1,10 @@ | |||
1 | [Unit] | ||
2 | Description=GNUnet user service | ||
3 | After=network.target | ||
4 | |||
5 | [Service] | ||
6 | Type=simple | ||
7 | ExecStart=/usr/lib/gnunet/libexec/gnunet-service-arm -c ~/.config/gnunet.conf | ||
8 | |||
9 | [Install] | ||
10 | WantedBy=multi-user.target | ||
diff --git a/contrib/packages/arch/gnunet/gnunet.install b/contrib/packages/arch/gnunet/gnunet.install new file mode 100644 index 000000000..2560926d8 --- /dev/null +++ b/contrib/packages/arch/gnunet/gnunet.install | |||
@@ -0,0 +1,54 @@ | |||
1 | post_install() { | ||
2 | |||
3 | local _PWD_PAIRS_="$(awk -F ':' '$3>=1000 && $3<2000 {print $1":"$6}' '/etc/passwd')" | ||
4 | local _USER_ | ||
5 | local _GROUP_ | ||
6 | local _CFG_DIR_ | ||
7 | |||
8 | for _PWD_PAIR_ in ${_PWD_PAIRS_}; do | ||
9 | _USER_="$(echo $_PWD_PAIR_ | cut -d ':' -f 1)" | ||
10 | _GROUP_="$(id -gn "${_USER_}")" | ||
11 | _CFG_DIR_="$(echo $_PWD_PAIR_ | cut -d ':' -f 2)/.config" | ||
12 | test -e "${_CFG_DIR_}/gnunet.conf" || (install -dm700 -o \ | ||
13 | "${_USER_}" -g "${_GROUP_}" "${_CFG_DIR_}" && install \ | ||
14 | -Dm600 -o "${_USER_}" -g "${_GROUP_}" \ | ||
15 | '/etc/skel/.config/gnunet.conf' \ | ||
16 | "${_CFG_DIR_}/gnunet.conf") | ||
17 | done | ||
18 | |||
19 | echo | ||
20 | echo 'Do not forget to add your user to the `gnunet` group, with' | ||
21 | echo | ||
22 | echo ' sudo usermod -aG gnunet "$(whoami)"' | ||
23 | echo | ||
24 | echo 'If later you want to remove your user from the group, launch' | ||
25 | echo | ||
26 | echo ' sudo gpasswd --delete "$(whoami)" gnunet' | ||
27 | echo | ||
28 | echo 'For information on how to use GNUnet plaese refer to the GNUnet article in the' | ||
29 | echo 'ArchWiki (https://wiki.archlinux.org/title/GNUnet).' | ||
30 | echo | ||
31 | |||
32 | } | ||
33 | |||
34 | post_remove() { | ||
35 | |||
36 | echo | ||
37 | echo 'The home directory of the `gnunet` user (`/var/lib/gnunet/`) is left after' | ||
38 | echo 'uninstalling GNUnet. If you are sure that you are never going to use GNUnet' | ||
39 | echo 'ever again, launch:' | ||
40 | echo | ||
41 | echo ' for username in $(getent group gnunet | cut -d: -f4 | tr '\'','\'' '\'' '\''); do \' | ||
42 | echo ' sudo gpasswd --delete "${username}" gnunet; done' | ||
43 | echo ' sudo userdel -r gnunet' | ||
44 | echo ' sudo groupdel gnunetdns' | ||
45 | echo | ||
46 | echo '**Warning** The identity and all the information about the network' | ||
47 | echo 'cumulatively stored by the current peer will be destroyed - this will not' | ||
48 | echo 'affect files explicitly downloaded in other paths.' | ||
49 | echo | ||
50 | echo 'For further information plaese refer to the GNUnet article in the ArchWiki' | ||
51 | echo '(https://wiki.archlinux.org/title/GNUnet).' | ||
52 | echo | ||
53 | |||
54 | } | ||
diff --git a/contrib/packages/arch/gnunet/gnunet.sysusers b/contrib/packages/arch/gnunet/gnunet.sysusers new file mode 100644 index 000000000..163895934 --- /dev/null +++ b/contrib/packages/arch/gnunet/gnunet.sysusers | |||
@@ -0,0 +1,3 @@ | |||
1 | g gnunet - | ||
2 | u gnunet - "GNUnet system account" /var/lib/gnunet | ||
3 | g gnunetdns - | ||
diff --git a/contrib/packages/arch/gnunet/gnunet.tmpfiles b/contrib/packages/arch/gnunet/gnunet.tmpfiles new file mode 100644 index 000000000..5b0b4174d --- /dev/null +++ b/contrib/packages/arch/gnunet/gnunet.tmpfiles | |||
@@ -0,0 +1,9 @@ | |||
1 | d /var/lib/gnunet 0700 gnunet gnunet - - | ||
2 | z /usr/lib/gnunet/libexec/gnunet-helper-dns 4750 root gnunetdns - - | ||
3 | z /usr/lib/gnunet/libexec/gnunet-helper-exit 4755 root root - - | ||
4 | z /usr/lib/gnunet/libexec/gnunet-helper-nat-client 4755 root root - - | ||
5 | z /usr/lib/gnunet/libexec/gnunet-helper-nat-server 4755 root root - - | ||
6 | z /usr/lib/gnunet/libexec/gnunet-helper-transport-bluetooth 4755 root root - - | ||
7 | z /usr/lib/gnunet/libexec/gnunet-helper-transport-wlan 4755 root root - - | ||
8 | z /usr/lib/gnunet/libexec/gnunet-helper-vpn 4755 root root - - | ||
9 | z /usr/lib/gnunet/libexec/gnunet-service-dns 2750 gnunet gnunetdns - - | ||