summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO4
-rw-r--r--.gitignore1
-rw-r--r--PKGBUILD20
-rw-r--r--sodium-native.patch56
4 files changed, 76 insertions, 5 deletions
diff --git a/.SRCINFO b/.SRCINFO
index d62c51423124..03af810577d8 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = ssb-server
pkgdesc = The gossip and replication server for Secure Scuttlebutt - a distributed social network
pkgver = 15.2.0
- pkgrel = 1
+ pkgrel = 2
url = https://scuttlebut.io
arch = any
license = MIT
@@ -9,7 +9,9 @@ pkgbase = ssb-server
depends = npm
options = !strip
source = https://github.com/ssbc/ssb-server/archive/v15.2.0.tar.gz
+ source = sodium-native.patch
sha256sums = b5c8ae6c87035e70b1e7031ce396e132665bbcb93206f94b910519db2764c138
+ sha256sums = 6c11a25664a5cd723ba27da52bfb32fa85c8eb017a697b56dea63da1aba051df
pkgname = ssb-server
diff --git a/.gitignore b/.gitignore
index 5ac2a18f23b2..e240b54aa78e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,4 @@ pkg/
src/
*.tar.gz
*.pkg.tar.xz
+*.pkg.tar.zst
diff --git a/PKGBUILD b/PKGBUILD
index 200d96eed72a..adcc8a71506b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,18 +2,30 @@
pkgname=ssb-server
pkgver=15.2.0
-pkgrel=1
+pkgrel=2
pkgdesc="The gossip and replication server for Secure Scuttlebutt - a distributed social network"
arch=(any)
url="https://scuttlebut.io"
license=('MIT')
depends=('nodejs' 'npm')
-source=(https://github.com/ssbc/ssb-server/archive/v$pkgver.tar.gz)
+source=(https://github.com/ssbc/ssb-server/archive/v$pkgver.tar.gz
+ sodium-native.patch)
options=(!strip)
+prepare(){
+ cd "$srcdir"
+ pushd "$pkgname-$pkgver"
+ # sodium-native 2.4.2 fails to build with nodejs 14.2.0, so bump to 2.4.9
+ patch -p1 < ../sodium-native.patch
+ popd
+ # rapackage after patching, because we have to install from tarball
+ tar czf v$pkgver.patched.tar.gz "$pkgname-$pkgver/"
+}
+
package(){
- npm install -g --user root --prefix "${pkgdir}/usr" "$srcdir/v${pkgver}.tar.gz"
+ npm install -g --user root --prefix "${pkgdir}/usr" "$srcdir/v${pkgver}.patched.tar.gz"
}
-sha256sums=('b5c8ae6c87035e70b1e7031ce396e132665bbcb93206f94b910519db2764c138')
+sha256sums=('b5c8ae6c87035e70b1e7031ce396e132665bbcb93206f94b910519db2764c138'
+ '6c11a25664a5cd723ba27da52bfb32fa85c8eb017a697b56dea63da1aba051df')
diff --git a/sodium-native.patch b/sodium-native.patch
new file mode 100644
index 000000000000..3ae39f2c3f51
--- /dev/null
+++ b/sodium-native.patch
@@ -0,0 +1,56 @@
+--- a/package.json 2020-05-23 23:08:06.989441562 -0400
++++ b/package.json 2020-05-23 23:08:14.456152175 -0400
+@@ -45,6 +45,7 @@
+ "pull-stream": "^3.6.2",
+ "rimraf": "^2.4.2",
+ "secret-stack": "^6.3.1",
++ "sodium-native": "^2.4.9",
+ "ssb-blobs": "1.2.2",
+ "ssb-caps": "^1.0.1",
+ "ssb-client": "^4.7.9",
+--- a/npm-shrinkwrap.json 2020-05-23 23:22:18.918294887 -0400
++++ b/npm-shrinkwrap.json 2020-05-23 23:23:57.739599148 -0400
+@@ -3178,8 +3178,7 @@
+ "nan": {
+ "version": "2.14.0",
+ "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz",
+- "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==",
+- "optional": true
++ "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg=="
+ },
+ "nanomatch": {
+ "version": "1.2.13",
+@@ -3250,10 +3249,9 @@
+ "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ=="
+ },
+ "node-gyp-build": {
+- "version": "3.9.0",
+- "resolved": "https://registry.npmjs.org/node-gyp-build/-/node-gyp-build-3.9.0.tgz",
+- "integrity": "sha512-zLcTg6P4AbcHPq465ZMFNXx7XpKKJh+7kkN699NiQWisR2uWYOWNWqRHAmbnmKiL4e9aLSlmy5U7rEMUXV59+A==",
+- "optional": true
++ "version": "4.2.2",
++ "resolved": "https://registry.npmjs.org/node-gyp-build/-/node-gyp-build-4.2.2.tgz",
++ "integrity": "sha512-Lqh7mrByWCM8Cf9UPqpeoVBBo5Ugx+RKu885GAzmLBVYjeywScxHXPGLa4JfYNZmcNGwzR0Glu5/9GaQZMFqyA=="
+ },
+ "non-private-ip": {
+ "version": "1.4.4",
+@@ -5931,14 +5929,13 @@
+ "integrity": "sha512-8AVzr9VHueXqfzfkzUA0aXe/Q4XG3UTmhlP6Pt+HQc5bbAPIJFo7ZIMh9tvn+99QuiMcyDJdYumegGAczl0N+g=="
+ },
+ "sodium-native": {
+- "version": "2.4.2",
+- "resolved": "https://registry.npmjs.org/sodium-native/-/sodium-native-2.4.2.tgz",
+- "integrity": "sha512-qwHcUnzFpRSGSm6F49j/h5SnxPFBgSNdDwZkAqjvuAoHQIVBFOXYb+oCUTJV80K5hRqSYCihpbX06vbrtPbilg==",
+- "optional": true,
++ "version": "2.4.9",
++ "resolved": "https://registry.npmjs.org/sodium-native/-/sodium-native-2.4.9.tgz",
++ "integrity": "sha512-mbkiyA2clyfwAyOFIzMvsV6ny2KrKEIhFVASJxWfsmgfUEymgLIS2MLHHcGIQMkrcKhPErRaMR5Dzv0EEn+BWg==",
+ "requires": {
+ "ini": "^1.3.5",
+- "nan": "^2.4.0",
+- "node-gyp-build": "^3.0.0"
++ "nan": "^2.14.0",
++ "node-gyp-build": "^4.1.0"
+ }
+ },
+ "source-map": {