summaryrefslogtreecommitdiff
path: root/pcr/suricata/PKGBUILD
diff options
context:
space:
mode:
authorAndré Fabian Silva Delgado <emulatorman@parabola.nu>2016-03-28 02:48:23 -0300
committerAndré Fabian Silva Delgado <emulatorman@parabola.nu>2016-03-28 02:48:58 -0300
commita69e43e17d55e6bd2c2af1d7ce9e35c2e1d2b989 (patch)
tree68f7029995e818898666da824ad6abc649375506 /pcr/suricata/PKGBUILD
parent8b3a098fa48e33aa3580752ca3532f76d0541aca (diff)
downloadabslibre-a69e43e17d55e6bd2c2af1d7ce9e35c2e1d2b989.tar.gz
abslibre-a69e43e17d55e6bd2c2af1d7ce9e35c2e1d2b989.tar.bz2
abslibre-a69e43e17d55e6bd2c2af1d7ce9e35c2e1d2b989.zip
suricata: add new package to [pcr]
Diffstat (limited to 'pcr/suricata/PKGBUILD')
-rw-r--r--pcr/suricata/PKGBUILD45
1 files changed, 45 insertions, 0 deletions
diff --git a/pcr/suricata/PKGBUILD b/pcr/suricata/PKGBUILD
new file mode 100644
index 000000000..2f887a4c9
--- /dev/null
+++ b/pcr/suricata/PKGBUILD
@@ -0,0 +1,45 @@
+# Maintainer (Arch): Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
+# Maintainer: André Silva <emulatorman@parabola.nu>
+
+pkgname=suricata
+pkgver=3.0
+pkgrel=1
+pkgdesc="A Free Software Next Generation Intrusion Detection and Prevention Engine"
+arch=('i686' 'x86_64' 'armv7h')
+url="http://suricata-ids.org/"
+license=('GPL2')
+depends=('libcap-ng' 'libnet' 'libpcap' 'libyaml' 'pcre')
+optdepends=('snort: suricata can use rulesets provided by snort')
+backup=('etc/suricata/suricata.yaml')
+source=(http://openinfosecfoundation.org/download/$pkgname-$pkgver.tar.gz)
+sha256sums=('4b8feb398a0800c955fe24aa31ca446c539e79492155717e826473f902c8e65a')
+
+prepare() {
+ cd "${srcdir}"/$pkgname-$pkgver
+
+ # remove Open Source term
+ sed -i 's|Open Source|Free Software|;
+ ' $(grep -ril 'open source')
+}
+
+build() {
+ cd "${srcdir}"/$pkgname-$pkgver
+
+ ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
+ make
+}
+
+package() {
+ cd "${srcdir}"/$pkgname-$pkgver
+
+ make DESTDIR="${pkgdir}" install
+
+ install -d "${pkgdir}"/var/log/$pkgname
+
+ install -Dm644 $pkgname.yaml "${pkgdir}"/etc/$pkgname/$pkgname.yaml
+ install -Dm644 classification.config "${pkgdir}"/etc/$pkgname/classification.config
+ install -Dm644 reference.config "${pkgdir}"/etc/$pkgname/reference.config
+
+ install -d "${pkgdir}"/etc/$pkgname/rules
+ install -Dm644 rules/*.rules "${pkgdir}"/etc/$pkgname/rules/
+}