| 1 | # Contributor: Alex Yam <[email protected]> |
| 2 | # Contributor: Sadie Powell <[email protected]> |
| 3 | # Maintainer: Ferass El Hafidi <[email protected]> |
| 4 | pkgname=inspircd |
| 5 | pkgver=4.12.1 |
| 6 | pkgrel=0 |
| 7 | pkgdesc="internet relay chat daemon (ircd)" |
| 8 | url="https://www.inspircd.org/" |
| 9 | pkgusers="inspircd" |
| 10 | pkggroups="inspircd" |
| 11 | arch="all" |
| 12 | license="GPL-2.0-or-later" |
| 13 | makedepends=" |
| 14 | argon2-dev |
| 15 | gnutls-dev |
| 16 | libpq-dev |
| 17 | mariadb-dev |
| 18 | openldap-dev |
| 19 | openssl-dev |
| 20 | pcre2-dev |
| 21 | perl |
| 22 | re2-dev |
| 23 | sqlite-dev |
| 24 | yyjson-dev |
| 25 | " |
| 26 | install="inspircd.pre-install" |
| 27 | subpackages="$pkgname-doc $pkgname-openrc" |
| 28 | options="!check" # no test suite |
| 29 | source="$pkgname-$pkgver.tar.gz::https://github.com/inspircd/inspircd/archive/v$pkgver.tar.gz |
| 30 | inspircd.initd |
| 31 | inspircd.confd |
| 32 | " |
| 33 | |
| 34 | # secfixes: |
| 35 | # 3.10.0-r0: |
| 36 | # - CVE-2021-33586 |
| 37 | |
| 38 | build() { |
| 39 | ./configure \ |
| 40 | --enable-extras "argon2 ldap log_json log_syslog mysql pgsql regex_pcre2 regex_posix regex_re2 sqlite3 ssl_openssl ssl_gnutls sslrehashsignal" |
| 41 | ./configure \ |
| 42 | --binary-dir /usr/bin \ |
| 43 | --data-dir /var/lib/inspircd/data \ |
| 44 | --example-dir /usr/share/inspircd/examples \ |
| 45 | --module-dir /usr/lib/inspircd/modules \ |
| 46 | --script-dir /usr/lib/inspircd/scripts \ |
| 47 | --disable-auto-extras \ |
| 48 | --distribution-label alpine$pkgrel \ |
| 49 | --gid inspircd \ |
| 50 | --uid inspircd \ |
| 51 | --disable-ownership \ |
| 52 | --system |
| 53 | INSPIRCD_DISABLE_RPATH=1 make |
| 54 | } |
| 55 | |
| 56 | package() { |
| 57 | make DESTDIR="$pkgdir" install |
| 58 | |
| 59 | # Instead of relying on the ownership set by the Makefiles use --disable-ownership |
| 60 | # and only grant ownership to directories that need it |
| 61 | install -dm755 -o inspircd -g inspircd \ |
| 62 | "$pkgdir"/var/log/inspircd "$pkgdir"/var/lib/inspircd/data \ |
| 63 | "$pkgdir"/run/inspircd "$pkgdir"/etc/inspircd |
| 64 | |
| 65 | install -D -m755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname |
| 66 | install -D -m644 "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname |
| 67 | } |
| 68 | |
| 69 | sha512sums=" |
| 70 | b3cf0749fbc6192710aee47d3cd6e705a9a1bd3d02c014cfc697f67bb3cbed4dc1b4ecf361ecafa0916e335d3382d8530665dff81f01036f8e5a87f89e677715 inspircd-4.12.1.tar.gz |
| 71 | eee453fc74facbb748623b9155fd20f3c1a4071e46905befa44864e6268d7bb58d546b34acc5d141120f7ba2829226870044c57f2ca21242490bdb7bcabc167a inspircd.initd |
| 72 | 89758f650dca70dfa230a8d449e2af0475fd17d61963e002ac8dc282c950ec56628dc3a8b331975a20af8ac7fe5d992e82311c6d811a12feca635a08f73aaf7b inspircd.confd |
| 73 | " |