summaryrefslogtreecommitdiff
path: root/libre/ipsec-tools-libre/PKGBUILD
blob: 373c839426f5a3b8cc04b560aaaf82907fc3ffba (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
46
47
48
# $Id: PKGBUILD 91859 2013-05-28 17:36:54Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Allan Henriksen <allan.henriksen@gmail.com>
# Maintainer (Parabola): André Silva <emulatorman@parabola.nu>

_pkgname=ipsec-tools
pkgname=ipsec-tools-libre
pkgver=0.8.1
pkgrel=4
pkgdesc="KAME IPSec tools ported to Linux (built for the linux-libre-headers package)"
arch=('i686' 'x86_64' 'mips64el')
url="http://ipsec-tools.sourceforge.net/"
depends=('readline' 'openssl' 'krb5')
makedepends=('linux-libre-headers')
replaces=$_pkgname
conflicts=$_pkgname
provides=$_pkgname=$pkgver
license=('GPL')
options=('!makeflags' '!libtool')
source=(http://downloads.sourceforge.net/sourceforge/ipsec-tools/$_pkgname-$pkgver.tar.bz2
	racoon.service
	ipsec.service
	ipsec-tools-linux-3.7-compat.patch)
md5sums=('d38b39f291ba2962387c3232e7335dd8'
         '3a64a9e3b498c6da90450ffb0b758aea'
         '387a0b0c4f10e42b2bb62282885cdc9c'
         'ae1dd20c83dcfce3dedb46ee73e83613')

build() {
  cd $srcdir/$_pkgname-$pkgver

  patch -p1 <$srcdir/ipsec-tools-linux-3.7-compat.patch
  sed -i 's#-Werror##' configure.ac

  ./bootstrap
  ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var --sbindir=/usr/bin \
	--enable-security-context=no --enable-hybrid --enable-dpd --enable-natt \
	--enable-adminport --enable-gssapi \
	--with-kernel-headers=/lib/modules/`pacman -Q linux-libre-headers | cut -f2 -d\ `-LIBRE/build/include
  make
}

package() {
  cd $srcdir/$_pkgname-$pkgver
  make DESTDIR=$pkgdir install
  install -Dm0644 $srcdir/racoon.service $pkgdir/usr/lib/systemd/system/racoon.service
  install -Dm0644 $srcdir/ipsec.service $pkgdir/usr/lib/systemd/system/ipsec.service
}