[arch-commits] Commit in arptables/repos (4 files)

Felix Yan felixonmars at archlinux.org
Tue May 19 07:57:07 UTC 2020


    Date: Tuesday, May 19, 2020 @ 07:57:07
  Author: felixonmars
Revision: 386080

archrelease: copy trunk to staging-x86_64

Added:
  arptables/repos/staging-x86_64/
  arptables/repos/staging-x86_64/PKGBUILD
    (from rev 386078, arptables/trunk/PKGBUILD)
  arptables/repos/staging-x86_64/arptables.service
    (from rev 386078, arptables/trunk/arptables.service)
  arptables/repos/staging-x86_64/arptables.systemd
    (from rev 386078, arptables/trunk/arptables.systemd)

-------------------+
 PKGBUILD          |   48 ++++++++++++++++++++++++++++++++++++++++++++++++
 arptables.service |   13 +++++++++++++
 arptables.systemd |   21 +++++++++++++++++++++
 3 files changed, 82 insertions(+)

Copied: arptables/repos/staging-x86_64/PKGBUILD (from rev 386078, arptables/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD	                        (rev 0)
+++ staging-x86_64/PKGBUILD	2020-05-19 07:57:07 UTC (rev 386080)
@@ -0,0 +1,48 @@
+# Maintainer: Sébastien Luttringer
+# Contributor: Daniel Micay <danielmicay at gmail.com>
+# Contributor: Michal Soltys <soltys at ziu.info>
+
+pkgname=arptables
+pkgver=0.0.4
+pkgrel=6
+pkgdesc='ARP filtering utility'
+arch=('x86_64')
+url='https://ebtables.netfilter.org/'
+depends=('glibc' 'perl' 'bash')
+license=('GPL')
+backup=("etc/$pkgname.conf")
+source=("ftp://ftp.netfilter.org/pub/arptables/arptables-v$pkgver.tar.gz"
+        "$pkgname.systemd"
+        "$pkgname.service")
+md5sums=('c2e99c3aa9d78c9dfa30710ca3168182'
+         'e54342a833c52b2bc67e7985e8f8fdfd'
+         '7e908fd77ef05bc7a9a05b6e877cd2bf')
+
+build() {
+  cd $pkgname-v${pkgver//_/-}
+  make
+}
+
+package() {
+  pushd $pkgname-v${pkgver//_/-}
+  make install \
+    DESTDIR="$pkgdir" \
+    PREFIX=/usr \
+    LIBDIR=/usr/lib/arptables \
+    BINDIR=/usr/bin \
+    MANDIR=/usr/share/man \
+    INITDIR=/etc/rc.d \
+    SYSCONFIGDIR=/etc
+  popd
+  # systemd
+  install -Dm 755 $pkgname.systemd \
+    "$pkgdir/usr/lib/systemd/scripts/$pkgname"
+  install -Dm 644 $pkgname.service \
+    "$pkgdir/usr/lib/systemd/system/$pkgname.service"
+  # default config file
+  install -Dm 644 /dev/null "$pkgdir/etc/$pkgname.conf"
+  # remove upstream rc
+  rm -rf "$pkgdir/etc/rc.d"
+}
+
+# vim:set ts=2 sw=2 et:

Copied: arptables/repos/staging-x86_64/arptables.service (from rev 386078, arptables/trunk/arptables.service)
===================================================================
--- staging-x86_64/arptables.service	                        (rev 0)
+++ staging-x86_64/arptables.service	2020-05-19 07:57:07 UTC (rev 386080)
@@ -0,0 +1,13 @@
+[Unit]
+Description=ARP Tables
+Before=network-pre.target
+Wants=network-pre.target
+
+[Service]
+Type=oneshot
+RemainAfterExit=yes
+ExecStart=/usr/lib/systemd/scripts/arptables start
+ExecStop=/usr/lib/systemd/scripts/arptables stop
+
+[Install]
+WantedBy=multi-user.target

Copied: arptables/repos/staging-x86_64/arptables.systemd (from rev 386078, arptables/trunk/arptables.systemd)
===================================================================
--- staging-x86_64/arptables.systemd	                        (rev 0)
+++ staging-x86_64/arptables.systemd	2020-05-19 07:57:07 UTC (rev 386080)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+CONFIG_FILE='/etc/arptables.conf'
+
+case $1 in
+  start)
+    arptables-restore < "$CONFIG_FILE"
+  ;;
+  stop)
+    arptables-restore < /dev/null
+  ;;
+  save)
+    arptables-save > "$CONFIG_FILE"
+  ;;
+  *)
+    echo "usage: ${0##*/} {start|stop|save}" >&2
+    exit 1
+  ;;
+esac
+
+# vim:set ts=2 sw=2 ft=sh et:



More information about the arch-commits mailing list