summaryrefslogtreecommitdiff
path: root/pcr/xtables-addons/PKGBUILD
blob: f5d4643fd6957bb206ea6619b5a8cb7304d818ac (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Maintainer (AUR): Shalygin Konstantin <k0ste@k0ste.ru>
# Contributor (AUR): Shalygin Konstantin <k0ste@k0ste.ru>
# Maintainer : Aurélien DESBRIÈRES <aurelien@hackers.camp>

pkgname='xtables-addons'
pkgver='3.2'
pkgrel='3'
pkgdesc='Xtables-addons is a set of additional extensions for the Xtables packet filter that is present in the Linux kernel'
arch=('i686' 'x86_64')
license=('GPL2')
url="https://${pkgname}.sourceforge.net/"
depends=('iptables' 'glibc' 'linux')
makedepends=('linux-api-headers' 'linux-headers' 'libtool' 'gcc' 'pkg-config')
source=("https://sourceforge.net/projects/${pkgname}/files/Xtables-addons//${pkgname}-${pkgver}.tar.xz")
sha256sums=('006f4e38bbf4b9a9069b90ca78c93b65800e9ebfd17332b713f1f80292420aaa')

prepare() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  ./autogen.sh
  ./configure \
    --prefix=/usr \
    --sysconfdir=/etc \
    --bindir=/usr/bin \
    --sbindir=/usr/bin \
    --libdir=/usr/lib \
    --mandir=/usr/share/man \
    --docdir=/usr/share/doc \
    --libexecdir=/usr/lib/iptables \
    --with-xtlibdir=/usr/lib/xtables
}

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  make DESTDIR="${pkgdir}" install
  libtool --finish "${pkgdir}/usr/lib"
  mv -f "${pkgdir}"/lib/* "${pkgdir}/usr/lib"
  rmdir "${pkgdir}/lib"
  rm "${pkgdir}"/usr/lib/modules/$(uname -r)/modules.*
}