aboutsummaryrefslogtreecommitdiffstats
path: root/unmaintained
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2020-01-21 08:19:11 +0100
committerNatanael Copa <ncopa@alpinelinux.org>2020-01-21 09:46:03 +0000
commit062a09c7a0f6a00a111287462ad1d6dd93fe67ef (patch)
tree709aa7e8e929f6d04482f109daead0303c845764 /unmaintained
parent27a8fe38c7b36c997b538316edbcac97f4bfaf8f (diff)
downloadaports-062a09c7a0f6a00a111287462ad1d6dd93fe67ef.tar.bz2
aports-062a09c7a0f6a00a111287462ad1d6dd93fe67ef.tar.xz
unmaintained/cjdns: move from main
Requires python2 Upstream issue: https://github.com/hyperboria/bugs/issues/194
Diffstat (limited to 'unmaintained')
-rw-r--r--unmaintained/cjdns/APKBUILD51
-rw-r--r--unmaintained/cjdns/cjdns.post-install5
-rw-r--r--unmaintained/cjdns/no-march-flag.patch13
3 files changed, 69 insertions, 0 deletions
diff --git a/unmaintained/cjdns/APKBUILD b/unmaintained/cjdns/APKBUILD
new file mode 100644
index 0000000000..894b6e5605
--- /dev/null
+++ b/unmaintained/cjdns/APKBUILD
@@ -0,0 +1,51 @@
+# Maintainer: kpcyrd <git@rxv.cc>
+# Contributor: kpcyrd <git@rxv.cc>
+# Contributor: Bartłomiej Piotrowski <bpiotrowski@alpinelinux.org>
+
+pkgname=cjdns
+pkgver=20.4
+pkgrel=0
+pkgdesc="A routing engine designed for security, scalability, speed and ease of use"
+url="https://github.com/cjdelisle/cjdns"
+arch="all !x86 !s390x"
+license="GPL-3.0-or-later"
+makedepends="nodejs python2 linux-headers libseccomp-dev"
+install="$pkgname.post-install"
+subpackages="$pkgname-doc $pkgname-openrc"
+source="$pkgname-$pkgver.tar.gz::https://github.com/cjdelisle/cjdns/archive/cjdns-v$pkgver.tar.gz
+ no-march-flag.patch"
+
+builddir="$srcdir/$pkgname-$pkgname-v$pkgver"
+
+build() {
+ cd "$builddir"
+ export CJDNS_RELEASE_VERSION="$pkgver"
+ node ./node_build/make.js
+}
+
+check() {
+ cd "$builddir"
+ ./cjdroute --help >/dev/null
+}
+
+package() {
+ cd "$builddir"
+ install -Dm755 cjdroute "$pkgdir/usr/sbin/cjdroute"
+ install -Dm755 contrib/openrc/cjdns "$pkgdir/etc/init.d/cjdns"
+ install -Dm644 doc/man/cjdroute.conf.5 \
+ "$pkgdir/usr/share/man/man5/cjdroute.conf.5"
+ install -Dm 644 README.md "$pkgdir/usr/share/doc/$pkgname/README.md"
+ install -Dm644 -t "$pkgdir/usr/share/doc/$pkgname" \
+ doc/admin-api.md \
+ doc/configure.md \
+ doc/djc_layer_model.md \
+ doc/nat-gateway.md \
+ doc/network-services.md \
+ doc/non-root-user.md \
+ doc/security_specification.md \
+ doc/shorewall_and_vpn_gateway_howto.md \
+ doc/tunnel.md
+}
+
+sha512sums="5a6bd36b2edd07fa883efa4b14dd8a7ba0189bf43404e27ab6ae3b0c2f1e63ce738c52b34416f51f93c9752f6654ea95eac2c71897d2a1e19f4a6d1ca3bad46d cjdns-20.4.tar.gz
+0c487a46609b75408d83cee954fc49f47997f0e9ee2bb8f64c3edc7e67273e5e90b4b2028847e09faa4bd1310b82f1a86fa7d0d0c42f18510cc9dcd4bccb8808 no-march-flag.patch"
diff --git a/unmaintained/cjdns/cjdns.post-install b/unmaintained/cjdns/cjdns.post-install
new file mode 100644
index 0000000000..0e091e941c
--- /dev/null
+++ b/unmaintained/cjdns/cjdns.post-install
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+umask 007
+[ ! -f /etc/cjdroute.conf ] && \
+ cjdroute --genconf > /etc/cjdroute.conf
diff --git a/unmaintained/cjdns/no-march-flag.patch b/unmaintained/cjdns/no-march-flag.patch
new file mode 100644
index 0000000000..aaec16c2ed
--- /dev/null
+++ b/unmaintained/cjdns/no-march-flag.patch
@@ -0,0 +1,13 @@
+diff --git a/node_build/make.js b/node_build/make.js
+index b3ae15d..b86e07f 100644
+--- a/node_build/make.js
++++ b/node_build/make.js
+@@ -29,7 +29,7 @@ var GCC = process.env['CC'];
+ var CFLAGS = process.env['CFLAGS'];
+ var LDFLAGS = process.env['LDFLAGS'];
+
+-var NO_MARCH_FLAG = ['arm', 'ppc', 'ppc64'];
++var NO_MARCH_FLAG = ['arm', 'arm64', 'mips', 'mips64', 'mips64el', 'mipsel', 'ppc', 'ppc64'];
+
+ if (GCC) {
+ // Already specified.