diff options
author | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2014-09-04 20:56:26 -0300 |
---|---|---|
committer | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2014-09-04 20:56:26 -0300 |
commit | eaa7dd3c7b19ec07ca6ace686561cf024c293ead (patch) | |
tree | 7238063a6d6d713aea5dc0235785a93611b3f81c /libre/rp-pppoe | |
parent | 4ac32d4cf06625e145fe9b35d65c793192275d09 (diff) | |
download | abslibre-eaa7dd3c7b19ec07ca6ace686561cf024c293ead.tar.gz abslibre-eaa7dd3c7b19ec07ca6ace686561cf024c293ead.tar.bz2 abslibre-eaa7dd3c7b19ec07ca6ace686561cf024c293ead.zip |
rp-pppoe: remove libre suffix and add complex pkgrel
Diffstat (limited to 'libre/rp-pppoe')
-rw-r--r-- | libre/rp-pppoe/PKGBUILD | 52 | ||||
-rw-r--r-- | libre/rp-pppoe/adsl | 35 | ||||
-rw-r--r-- | libre/rp-pppoe/adsl.service | 10 | ||||
-rw-r--r-- | libre/rp-pppoe/kmode.patch | 19 | ||||
-rw-r--r-- | libre/rp-pppoe/libre.patch | 110 | ||||
-rw-r--r-- | libre/rp-pppoe/rp-pppoe.install | 12 |
6 files changed, 238 insertions, 0 deletions
diff --git a/libre/rp-pppoe/PKGBUILD b/libre/rp-pppoe/PKGBUILD new file mode 100644 index 000000000..218591511 --- /dev/null +++ b/libre/rp-pppoe/PKGBUILD @@ -0,0 +1,52 @@ +# $Id: PKGBUILD 220603 2014-08-23 13:00:49Z heftig $ +# Maintainer (Arch): Daniel Isenmann <daniel@archlinux.org> +# Contributor (Arch): orelien <aurelien.foret@wanadoo.fr> +# Maintainer: André Silva <emulatorman@parabola.nu> + +pkgname=rp-pppoe +pkgver=3.11 +pkgrel=7.parabola1 +pkgdesc="Roaring Penguin's Point-to-Point Protocol over Ethernet client, without nonfree ServPoET recommendation" +arch=('i686' 'x86_64' 'mips64el') +url="http://www.roaringpenguin.com/pppoe/" +license=('GPL') +depends=('ppp=2.4.7' 'sh' 'net-tools') +backup=(etc/ppp/pppoe.conf etc/ppp/firewall-standalone etc/ppp/firewall-masq + etc/ppp/pppoe-server-options) +options=('!makeflags') +replaces=('rp-pppoe-libre') +conflicts=('rp-pppoe-libre') +install=rp-pppoe.install +source=(http://www.roaringpenguin.com/files/download/rp-pppoe-$pkgver.tar.gz{,.sig} + adsl.service + kmode.patch + libre.patch) + +prepare() { + cd "$srcdir/$pkgname-$pkgver" + + ## Adding patch to remove nonfree software recommendation (ServPoET) + patch -Np1 -i "$srcdir/libre.patch" + + cd "$srcdir/$pkgname-$pkgver/src" + patch -Np2 -i ../../kmode.patch +} + +build() { + cd "$srcdir/$pkgname-$pkgver/src" + ./configure --prefix=/usr --sbindir=/usr/bin --enable-plugin + make PLUGIN_DIR="/usr/lib/rp-pppoe" all rp-pppoe.so +} + +package() { + cd "$srcdir/$pkgname-$pkgver/src" + make PLUGIN_DIR="/usr/lib/rp-pppoe" DESTDIR="$pkgdir" install + + #install -Dm755 "$srcdir/adsl" "$pkgdir/etc/rc.d/adsl" + install -Dm644 "$srcdir/adsl.service" "$pkgdir/usr/lib/systemd/system/adsl.service" +} +md5sums=('13b5900c56bd602df6cc526e5e520722' + 'SKIP' + '926b00aa2a0c0d3a21970acde9695e47' + 'd38a903a247d689ff0323d7b6caa1c6b' + '3c53d550ac408608abb0b6cd6b76b6c2') diff --git a/libre/rp-pppoe/adsl b/libre/rp-pppoe/adsl new file mode 100644 index 000000000..33bd91839 --- /dev/null +++ b/libre/rp-pppoe/adsl @@ -0,0 +1,35 @@ +#!/bin/bash + +. /etc/rc.conf +. /etc/rc.d/functions + +case "$1" in + start) + stat_busy "Starting ADSL Connection" + /usr/sbin/pppoe-start &>/dev/null + if [ $? -gt 0 ]; then + stat_fail + else + add_daemon adsl + stat_done + fi + ;; + stop) + stat_busy "Stopping ADSL Connection" + /usr/sbin/pppoe-stop &>/dev/null + if [ $? -gt 0 ]; then + stat_fail + else + rm_daemon adsl + stat_done + fi + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "usage: $0 {start|stop|restart}" +esac +exit 0 diff --git a/libre/rp-pppoe/adsl.service b/libre/rp-pppoe/adsl.service new file mode 100644 index 000000000..85ff49287 --- /dev/null +++ b/libre/rp-pppoe/adsl.service @@ -0,0 +1,10 @@ +[Unit] +Description=ADSL Daemon + +[Service] +Type=forking +ExecStart=/usr/bin/pppoe-start +ExecStop=/usr/bin/pppoe-stop + +[Install] +WantedBy=multi-user.target diff --git a/libre/rp-pppoe/kmode.patch b/libre/rp-pppoe/kmode.patch new file mode 100644 index 000000000..37eef58f7 --- /dev/null +++ b/libre/rp-pppoe/kmode.patch @@ -0,0 +1,19 @@ +diff -up rp-pppoe-3.11/src/configure.orig rp-pppoe-3.11/src/configure +--- rp-pppoe-3.11/src/configure.orig 2012-08-17 12:31:25.000000000 -0600 ++++ rp-pppoe-3.11/src/configure 2013-02-11 14:23:05.000000000 -0700 +@@ -3679,6 +3679,7 @@ do : + #include<net/ethernet.h> + #include<linux/if.h> + #include<linux/in.h> ++#include<linux/in6.h> + + " + if test "x$ac_cv_header_linux_if_pppox_h" = x""yes; then : +@@ -4525,6 +4526,7 @@ else + #include <net/ethernet.h> + #include <linux/if.h> + #include <linux/in.h> ++#include <linux/in6.h> + #include <linux/if_pppox.h> + int main() + { diff --git a/libre/rp-pppoe/libre.patch b/libre/rp-pppoe/libre.patch new file mode 100644 index 000000000..9cf16d7d7 --- /dev/null +++ b/libre/rp-pppoe/libre.patch @@ -0,0 +1,110 @@ +diff -Nur rp-pppoe-3.11.orig/rp-pppoe.spec rp-pppoe-3.11/rp-pppoe.spec +--- rp-pppoe-3.11.orig/rp-pppoe.spec 2012-08-17 15:31:25.000000000 -0300 ++++ rp-pppoe-3.11/rp-pppoe.spec 2012-10-05 01:42:29.964508454 -0300 +@@ -55,7 +55,7 @@ + + %files + %defattr(-,root,root) +-%doc doc/CHANGES doc/HOW-TO-CONNECT doc/LICENSE doc/KERNEL-MODE-PPPOE README SERVPOET ++%doc doc/CHANGES doc/HOW-TO-CONNECT doc/LICENSE doc/KERNEL-MODE-PPPOE README + %config(noreplace) /etc/ppp/pppoe.conf + %config(noreplace) /etc/ppp/pppoe-server-options + %config(noreplace) /etc/ppp/firewall-masq +diff -Nur rp-pppoe-3.11.orig/SERVPOET /dev/null +--- rp-pppoe-3.11.orig/SERVPOET 2012-08-17 15:31:25.000000000 -0300 ++++ /dev/null 2012-10-05 01:27:08.580078512 -0300 +@@ -1,18 +0,0 @@ +-# LIC: GPL +- +-ServPoET +--------- +- +-ServPoET is a commercial version of the PPPoE server. While everything +-you received in this package is licensed under the GNU General Public +-License, ServPoET is not free software and is licensed under a traditional +-commercial license. +- +-ServPoET features RADIUS support, support for different realms, +-real-time server status reporting and a friendly curses-based GUI for +-administration. For information on ServPoET: +- +-Contact Fine Point Technologies, Inc. (http://www.finepoint.com/) +- +--- +-David F. Skoll <dfs@roaringpenguin.com> +diff -Nur rp-pppoe-3.11.orig/src/Makefile.in rp-pppoe-3.11/src/Makefile.in +--- rp-pppoe-3.11.orig/src/Makefile.in 2012-08-17 15:31:25.000000000 -0300 ++++ rp-pppoe-3.11/src/Makefile.in 2012-10-05 01:46:13.121336619 -0300 +@@ -44,9 +44,6 @@ + PPPOE_PATH=$(sbindir)/pppoe + PPPD_PATH=@PPPD@ + +-# Include ServPoET version if we're building for ServPoET +-@LIC_MAKEFILE_INCLUDE@ +- + # Kernel-mode plugin gets installed here. + PLUGIN_DIR=/etc/ppp/plugins + PLUGIN_PATH=$(PLUGIN_DIR)/rp-pppoe.so +@@ -152,7 +149,6 @@ + $(install) -m 644 ../doc/HOW-TO-CONNECT $(DESTDIR)$(docdir) + $(install) -m 644 ../doc/LICENSE $(DESTDIR)$(docdir) + $(install) -m 644 ../README $(DESTDIR)$(docdir) +- $(install) -m 644 ../SERVPOET $(DESTDIR)$(docdir) + $(install) -m 644 ../configs/pap-secrets $(DESTDIR)$(docdir) + -mkdir -p $(DESTDIR)$(mandir)/man8 + for i in $(TARGETS) ; do \ +@@ -210,25 +206,15 @@ + @echo "" + @echo "Type 'pppoe-setup' to configure the software." + +-servpoet-tgz: distro-servpoet +- cd .. && tar cvf servpoet-$(VERSION)$(BETA).tar servpoet-$(VERSION)$(BETA) +- gzip -f -v -9 ../servpoet-$(VERSION)$(BETA).tar +- rm -rf ../servpoet-$(VERSION)$(BETA) +- + tgz: distro + cd .. && tar cvf rp-pppoe-$(VERSION)$(BETA).tar rp-pppoe-$(VERSION)$(BETA) + gzip -f -v -9 ../rp-pppoe-$(VERSION)$(BETA).tar + rm -rf ../rp-pppoe-$(VERSION)$(BETA) + +-distro-servpoet: distro +- cp ../servpoet.spec ../rp-pppoe-$(VERSION)$(BETA) +- $(MAKE) -C licensed-only distro VERSION=$(VERSION) BETA=$(BETA) +- mv ../rp-pppoe-$(VERSION)$(BETA) ../servpoet-$(VERSION)$(BETA) +- + distro: + rm -rf ../rp-pppoe-$(VERSION)$(BETA) + mkdir ../rp-pppoe-$(VERSION)$(BETA) +- for i in README SERVPOET go go-gui rp-pppoe.spec ; do \ ++ for i in README go go-gui rp-pppoe.spec ; do \ + cp ../$$i ../rp-pppoe-$(VERSION)$(BETA) || exit 1; \ + done + mkdir ../rp-pppoe-$(VERSION)$(BETA)/gui +@@ -286,10 +272,6 @@ + /usr/src/redhat/RPMS/i386/rp-pppoe-$(VERSION)-1.i386.rpm \ + /usr/src/redhat/RPMS/i386/rp-pppoe-gui-$(VERSION)-1.i386.rpm + +-servpoet-rpms: servpoet-tgz +- cp ../servpoet-$(VERSION).tar.gz /usr/src/redhat/SOURCES +- cd .. && rpm -ba servpoet.spec +- + clean: + rm -f *.o pppoe-relay pppoe pppoe-sniff pppoe-server core rp-pppoe.so plugin/*.o plugin/libplugin.a *~ + test -f licensed-only/Makefile && $(MAKE) -C licensed-only clean || true +@@ -304,15 +286,13 @@ + update-version: + sed -e 's/^Version: .*$$/Version: $(VERSION)/' ../rp-pppoe.spec > ../rp-pppoe.spec.new && mv ../rp-pppoe.spec.new ../rp-pppoe.spec + sed -e 's+^Source: .*$$+Source: http://www.roaringpenguin.com/pppoe/rp-pppoe-$(VERSION).tar.gz+' ../rp-pppoe.spec > ../rp-pppoe.spec.new && mv ../rp-pppoe.spec.new ../rp-pppoe.spec +- test -f ../servpoet.spec && sed -e 's/^Version: .*$$/Version: $(VERSION)/' ../servpoet.spec > ../servpoet.spec.new && mv ../servpoet.spec.new ../servpoet.spec || true +- test -f ../servpoet.spec && sed -e 's+^Source: .*$$+Source: http://www.roaringpenguin.com/pppoe/servpoet-$(VERSION).tar.gz+' ../servpoet.spec > ../servpoet.spec.new && mv ../servpoet.spec.new ../servpoet.spec || true + + # Convenience target for David! Don't try to use this one. + km: + ./configure --enable-plugin=/home/dfs/Archive/PPP/ppp-2.4.0.pppoe4-patched-dfs + + licensed-only: +- $(MAKE) -C licensed-only all VERSION=$(VERSION) SERVPOET_VERSION=$(SERVPOET_VERSION) ++ $(MAKE) -C licensed-only all VERSION=$(VERSION) + + l2tp: libevent/libevent.a + $(MAKE) -C l2tp all diff --git a/libre/rp-pppoe/rp-pppoe.install b/libre/rp-pppoe/rp-pppoe.install new file mode 100644 index 000000000..1d4bccce2 --- /dev/null +++ b/libre/rp-pppoe/rp-pppoe.install @@ -0,0 +1,12 @@ +#arg 1: the new package version +post_install() { +echo ">>> The kernel-mode plugin has a new place." +echo ">>> It's now located under /usr/lib/rp-pppoe/rp-pppoe.so" +echo ">>> Change LINUX_PLUGIN to the new path in your /etc/ppp/pppoe.conf" +} + +# arg 1: the new package version +# arg 2: the old package version +post_upgrade() { + post_install $1 +} |