Patches for aports can be sent to this list

1

[alpine-aports] [PATCH 1/2] main/bearssl: new APKBUILD (bearssl-0.5)

Laurent Bercot
Details
Message ID
<20180225130204.14376-1-ska-devel@skarnet.org>
Sender timestamp
1519563723
DKIM signature
missing
Download raw message
Patch: +53 -0
---
 main/bearssl/APKBUILD                    | 40 ++++++++++++++++++++++++++++++++
 main/bearssl/bearssl-brssl-dynamic.patch | 13 +++++++++++
 2 files changed, 53 insertions(+)
 create mode 100644 main/bearssl/APKBUILD
 create mode 100644 main/bearssl/bearssl-brssl-dynamic.patch

diff --git a/main/bearssl/APKBUILD b/main/bearssl/APKBUILD
new file mode 100644
index 0000000000..b4867d3ad3
--- /dev/null
+++ b/main/bearssl/APKBUILD
@@ -0,0 +1,40 @@
+# Maintainer: Laurent Bercot <ska-devel@skarnet.org>
+# Contributor: Laurent Bercot <ska-devel@skarnet.org>
+pkgname=bearssl
+pkgver=0.5
+pkgrel=0
+pkgdesc="The BearSSL implementation of the SSL/TLS protocol"
+url="https://bearssl.org/"
+arch="all"
+license="MIT"
+subpackages="$pkgname-dev"
+source="https://bearssl.org/$pkgname-$pkgver.tar.gz bearssl-brssl-dynamic.patch"
+builddir="$srcdir/$pkgname-$pkgver"
+
+build() {
+	cd "$builddir"
+	make \
+	  CC=gcc \
+	  LD=gcc \
+	  LDDLL=gcc \
+	  LDDLLFLAGS="-shared -Wl,-soname,libbearssl.so.${pkgver%%.*}" \
+	  D=".so.$pkgver"
+}
+
+package() {
+	mkdir -p -m 0755 -- "$pkgdir"/bin "$pkgdir"/lib "$pkgdir"/usr/include "$pkgdir"/usr/lib
+	cp -f "$builddir/build/brssl" "$pkgdir/bin/"
+	cp -f "$builddir"/inc/* "$pkgdir/usr/include/"
+	cp -f "$builddir/build/libbearssl.a" "$pkgdir/usr/lib/"
+	cp -f "$builddir/build/libbearssl.so.$pkgver" "$pkgdir/lib/"
+	ln -sf "libbearssl.so.$pkgver" "$pkgdir/lib/libbearssl.so.${pkgver%%.*}"
+	ln -sf "libbearssl.so.${pkgver%%.*}" "$pkgdir/lib/libbearssl.so"
+}
+
+check() {
+	cd "$builddir/build"
+	./testx509 && ./testcrypto all
+}
+
+sha512sums="1bd510f62f36620cda5317509e72bd0c6f3538c30aca2695e80c26d1ea7270d174ed3fbb6d690b3ced5d51ce3f6bfc776d78a196492900296a452bc4c8185e45  bearssl-0.5.tar.gz
+f5fe047862eb355a662ccb1b95c2ca4a870ac0f8d3f4cada5396d2f6a6635647db53fbeb038f9a7651b84d6cda32b6415ce0f69a8da92636d3b3b76578114d5c  bearssl-brssl-dynamic.patch"
diff --git a/main/bearssl/bearssl-brssl-dynamic.patch b/main/bearssl/bearssl-brssl-dynamic.patch
new file mode 100644
index 0000000000..e41bb138ee
--- /dev/null
+++ b/main/bearssl/bearssl-brssl-dynamic.patch
@@ -0,0 +1,13 @@
+--- bearssl-0.5.old/mk/Rules.mk
+@@ -49,8 +49,8 @@
+ $(BEARSSLDLL): $(OBJDIR) $(OBJ)
+ 	$(LDDLL) $(LDDLLFLAGS) $(LDDLLOUT)$(BEARSSLDLL) $(OBJ)
+ 
+-$(BRSSL): $(BEARSSLLIB) $(OBJBRSSL)
+-	$(LD) $(LDFLAGS) $(LDOUT)$(BRSSL) $(OBJBRSSL) $(BEARSSLLIB)
++$(BRSSL): $(BEARSSLDLL) $(OBJBRSSL)
++	$(LD) $(LDFLAGS) $(LDOUT)$(BRSSL) $(OBJBRSSL) $(BEARSSLDLL)
+ 
+ $(TESTCRYPTO): $(BEARSSLLIB) $(OBJTESTCRYPTO)
+ 	$(LD) $(LDFLAGS) $(LDOUT)$(TESTCRYPTO) $(OBJTESTCRYPTO) $(BEARSSLLIB)
-- 
2.15.0



---
Unsubscribe:  alpine-aports+unsubscribe@lists.alpinelinux.org
Help:         alpine-aports+help@lists.alpinelinux.org
---

[alpine-aports] [PATCH 2/2] main/s6-networking: change dependency from libressl to bearssl

Laurent Bercot
Details
Message ID
<20180225130204.14376-2-ska-devel@skarnet.org>
In-Reply-To
<20180225130204.14376-1-ska-devel@skarnet.org> (view parent)
Sender timestamp
1519563724
DKIM signature
missing
Download raw message
Patch: +3 -3
---
 main/s6-networking/APKBUILD | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/main/s6-networking/APKBUILD b/main/s6-networking/APKBUILD
index b3d0664c91..866d26a80e 100644
--- a/main/s6-networking/APKBUILD
+++ b/main/s6-networking/APKBUILD
@@ -2,13 +2,13 @@
 # Contributor: John Regan <john@jrjrtech.com>
 pkgname=s6-networking
 pkgver=2.3.0.2
-pkgrel=1
+pkgrel=2
 pkgdesc="skarnet.org's UCSPI Unix and TCP tools, access control tools, and network time management utilities."
 url="http://skarnet.org/software/$pkgname/"
 arch="all"
 license="ISC"
 options="!check"
-makedepends="skalibs-dev execline-dev s6-dev s6-dns-dev libressl libressl-dev"
+makedepends="skalibs-dev execline-dev s6-dev s6-dns-dev bearssl bearssl-dev"
 subpackages="$pkgname-dev $pkgname-doc"
 source="http://skarnet.org/software/$pkgname/$pkgname-$pkgver.tar.gz"
 builddir="$srcdir/$pkgname-$pkgver"
@@ -22,7 +22,7 @@ build() {
 		--prefix=/usr \
 		--libexecdir="/usr/lib/$pkgname" \
 		--with-dynlib=/lib \
-		--enable-ssl=libressl
+		--enable-ssl=bearssl
 	make
 }
 
-- 
2.15.0



---
Unsubscribe:  alpine-aports+unsubscribe@lists.alpinelinux.org
Help:         alpine-aports+help@lists.alpinelinux.org
---