summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author Eric Hameleers <alien@slackware.com>2021-01-08 17:56:18 +0000
committer Eric Hameleers <alien@slackware.com>2021-01-08 17:56:18 +0000
commitf3f42b1dbd24488e01bcfc87af5c81ef2dacd3fa (patch)
tree7efeaa109b7a08e4444c318f4f5d74e217963faa
parent19a4f62555c40e0df205d12f6e26d6f7513698d0 (diff)
downloadasb-f3f42b1dbd24488e01bcfc87af5c81ef2dacd3fa.tar.gz
asb-f3f42b1dbd24488e01bcfc87af5c81ef2dacd3fa.tar.xz
mbedtls: update to 2.25.0
-rwxr-xr-xmbedtls/build/mbedtls.SlackBuild16
1 files changed, 14 insertions, 2 deletions
diff --git a/mbedtls/build/mbedtls.SlackBuild b/mbedtls/build/mbedtls.SlackBuild
index 73b090d1..dcf1c7c7 100755
--- a/mbedtls/build/mbedtls.SlackBuild
+++ b/mbedtls/build/mbedtls.SlackBuild
@@ -1,6 +1,6 @@
#!/bin/sh
# $Id$
-# Copyright 2020 Eric Hameleers, Eindhoven, NL
+# Copyright 2020, 2021 Eric Hameleers, Eindhoven, NL
# All rights reserved.
#
# Permission to use, copy, modify, and distribute this software for
@@ -33,6 +33,8 @@
# Changelog:
# 2.24.0-1: 05/Oct/2020 by Eric Hameleers <alien@slackware.com>
# * Initial build.
+# 2.25.0-1: 08/jan/2021 by Eric Hameleers <alien@slackware.com>
+# * Initial build.
#
# Run 'sh mbedtls.SlackBuild' to build a Slackware package.
# The package (.t?z) and .txt file as well as build logs are created in /tmp .
@@ -41,7 +43,7 @@
# -----------------------------------------------------------------------------
PRGNAM=mbedtls
-VERSION=${VERSION:-2.24.0}
+VERSION=${VERSION:-2.25.0}
BUILD=${BUILD:-1}
NUMJOBS=${NUMJOBS:-" -j$(nproc) "}
TAG=${TAG:-alien}
@@ -152,6 +154,16 @@ cd ${PRGNAM}-${VERSION}
# Enable those features in the header files that we want to use,
sed -i 's|//\(#define MBEDTLS_ZLIB_SUPPORT\)|\1|' include/mbedtls/config.h
+sed -i 's|//\(#define MBEDTLS_THREADING_C\)|\1|' include/mbedtls/config.h
+sed -i 's|//\(#define MBEDTLS_THREADING_PTHREAD\)|\1|' include/mbedtls/config.h
+
+# Use temporary Arch Linux fix for incompatibilities with GCC 10,
+# which surfaced when I enabled threading above:
+sed -i 's/thread_id, -ret/thread_id, (unsigned int)(-ret)/' programs/ssl/ssl_pthread_server.c
+sed -i 's/thread_id, ret/thread_id, (unsigned int)ret/' programs/ssl/ssl_pthread_server.c
+sed -i 's/ -ret );/ (unsigned int)(-ret) );/' programs/ssl/ssl_pthread_server.c
+sed -i 's/ -ret, error_buf/ (unsigned int)(-ret), error_buf/' programs/ssl/ssl_pthread_server.c
+sed -i 's/04x\\n", ret /04x\\n", (unsigned int)ret /' programs/ssl/ssl_pthread_server.c
chown -R root:root .
chmod -R u+w,go+r-w,a+rX-st .