# $Id: PKGBUILD 135812 2015-06-24 07:26:51Z alucryd $
# Maintainer: Maxime Gauduin <alucryd@archlinux.org>
# Contributor: unikum <unikum.pm@gmail.com>
# Contributor: speed145a <jonathan@tagchapter.com>

pkgname=firewalld
pkgver=0.3.14.2
pkgrel=1
pkgdesc='A dynamic firewall daemon with a D-BUS interface'
arch=('any')
url='http://fedorahosted.org/firewalld'
license=('GPL2')
depends=('dbus-glib' 'ebtables' 'iptables' 'python-slip')
makedepends=('intltool' 'docbook-xsl')
optdepends=('gtk3: firewall-config'
            'libnm-glib: firewall-config and firewall-applet'
            'libnotify: firewall-applet'
            'python-pyqt4: firewall-applet')
backup=('etc/conf.d/firewalld'
        'etc/firewalld/firewalld.conf')
install='firewalld.install'
source=("https://fedorahosted.org/released/firewalld/firewalld-${pkgver}.tar.bz2"
        'firewalld-paths.patch')
sha256sums=('4b6c3e1deab41b6002b8dc25639e466085941c98a6c14a56bef4f621a5651567'
            '41591c5358c5ad8d43b29d72f42c331fcfc25e3d38c0ba5b3c818fc757ceef2f')

prepare() {
  cd firewalld-${pkgver}

  patch -Np1 -i ../firewalld-paths.patch
}

build() {
  cd firewalld-${pkgver}

  ./configure \
    --prefix='/usr'\
    --localstatedir='/var' \
    --sbindir='/usr/bin' \
    --sysconfdir='/etc' \
    --disable-schemas-compile
  make
}

package() {
  cd firewalld-${pkgver}

  make DESTDIR="${pkgdir}" install
  #chmod 755 "${pkgdir}"/usr/bin/firewall-applet
}

# vim: ts=2 sw=2 et:
