summaryrefslogtreecommitdiff
path: root/community/freeradius/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/freeradius/PKGBUILD')
-rw-r--r--community/freeradius/PKGBUILD51
1 files changed, 51 insertions, 0 deletions
diff --git a/community/freeradius/PKGBUILD b/community/freeradius/PKGBUILD
new file mode 100644
index 000000000..6ecba36c1
--- /dev/null
+++ b/community/freeradius/PKGBUILD
@@ -0,0 +1,51 @@
+# $Id: PKGBUILD 91902 2013-05-29 10:03:34Z spupykin $
+# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
+# Contributor: Jason R Begley (jayray@digitalgoat.com>
+
+pkgname=freeradius
+pkgver=2.2.0
+pkgrel=8
+pkgdesc="The premier open source RADIUS server"
+arch=('i686' 'x86_64')
+url="http://www.freeradius.org/"
+license=('GPL')
+depends=('krb5' 'pth' 'net-snmp' 'postgresql-libs' 'libmariadbclient')
+makedepends=('libpcap' 'unixodbc' 'python2')
+optdepends=('libpcap' 'unixodbc' 'python2')
+options=('!libtool' '!makeflags')
+install=$pkgname.install
+source=("ftp://ftp.freeradius.org/pub/radius/freeradius-server-$pkgver.tar.bz2"{,.sig}
+ freeradius.tmpfiles
+ freeradius.service
+ krb5-build-fix.patch)
+md5sums=('0fb333fe6a64eb2b1dd6ef67f7bca119'
+ 'SKIP'
+ 'f959e89812bedfc9f8308076f78cd74e'
+ 'e3f18e3a25df3b692e59f60605354708'
+ 'c6a61de7576933f59154a53bfc12a2d2')
+
+build() {
+ cd $srcdir/freeradius-server-$pkgver
+ export CFLAGS="$CFLAGS -fno-strict-aliasing"
+ sed -i 's/ -DKRB5_DEPRECATED//' src/modules/rlm_krb5/Makefile.in
+ patch -p1 <$srcdir/krb5-build-fix.patch
+ ./configure --with-system-libtool --with-system-libltdl \
+ --prefix=/usr --enable-heimdal-krb5 \
+ --localstatedir=/var \
+ --sysconfdir=/etc \
+ --sbindir=/usr/bin \
+ --libdir=/usr/lib/freeradius \
+ --with-udpfromto
+ make
+}
+
+package() {
+ cd $srcdir/freeradius-server-$pkgver
+ make install R=$pkgdir
+ chmod o+r $pkgdir/etc/raddb/*
+ mv $pkgdir/etc/raddb $pkgdir/etc/raddb.default
+ rm -rf $pkgdir/var/run
+
+ install -Dm0644 $srcdir/$pkgname.service $pkgdir/usr/lib/systemd/system/$pkgname.service
+ install -Dm0644 $srcdir/$pkgname.tmpfiles $pkgdir/usr/lib/tmpfiles.d/$pkgname.conf
+}