mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-16 04:35:13 +03:00
137 lines
4.1 KiB
Diff
137 lines
4.1 KiB
Diff
--- a/dlbssl.sh
|
|
+++ b/dlbssl.sh
|
|
@@ -29,7 +29,7 @@
|
|
|
|
elif [ ! -f $BSSLDIR/build/ssl/libssl.a ] ; then
|
|
BSSLDIR=boringssl
|
|
- git clone https://github.com/google/boringssl.git
|
|
+ #git clone https://github.com/google/boringssl.git
|
|
|
|
if [ -d "go" ]; then
|
|
PATH=$PWD/go/bin:$PATH
|
|
@@ -37,23 +37,23 @@
|
|
fi
|
|
|
|
cd boringssl
|
|
- git reset --hard
|
|
- git checkout master
|
|
- git pull
|
|
+ #git reset --hard
|
|
+ #git checkout master
|
|
+ #git pull
|
|
|
|
- git checkout 32e59d2d3264e4e104b355ef73663b8b79ac4093
|
|
+ #git checkout cf8d3ad3cea51cf7184307d54f465da62b7d8408
|
|
|
|
rm -rf build
|
|
|
|
detectdlcmd
|
|
- $DLCMD 1.patch https://raw.githubusercontent.com/litespeedtech/third-party/master/patches/boringssl/bssl_inttypes.patch
|
|
- $DLCMD 2.patch https://raw.githubusercontent.com/litespeedtech/third-party/master/patches/boringssl/bssl_max_early_data_sz.patch
|
|
- $DLCMD 3.patch https://raw.githubusercontent.com/litespeedtech/third-party/master/patches/boringssl/bssl_no_eoed.patch
|
|
+ # $DLCMD 1.patch https://raw.githubusercontent.com/litespeedtech/third-party/master/patches/boringssl/bssl_inttypes.patch
|
|
+ # $DLCMD 2.patch https://raw.githubusercontent.com/litespeedtech/third-party/master/patches/boringssl/bssl_max_early_data_sz.patch
|
|
+ # $DLCMD 3.patch https://raw.githubusercontent.com/litespeedtech/third-party/master/patches/boringssl/bssl_no_eoed.patch
|
|
|
|
#patch -p1 < ../bssl_lstls.patch
|
|
- patch -p1 < 1.patch
|
|
- patch -p1 < 2.patch
|
|
- patch -p1 < 3.patch
|
|
+ patch -p1 < $HOME/bssl.patch
|
|
+ # patch -p1 < 2.patch
|
|
+ # patch -p1 < 3.patch
|
|
|
|
mkdir build
|
|
cd build
|
|
@@ -75,6 +75,8 @@
|
|
cp -r $BSSLDIR/include ssl/
|
|
fi
|
|
|
|
+cp boringssl/build/ssl/libssl.a include
|
|
+cp -r boringssl/include/openssl include
|
|
|
|
if [ ! -f ssl/libcrypto.a ] ; then
|
|
echo -e "\033[38;5;148mError: failed to make boringSSL libraries.\033[39m"
|
|
|
|
|
|
--- a/include/lsr/ls_lock.h
|
|
+++ b/include/lsr/ls_lock.h
|
|
@@ -55,16 +55,9 @@
|
|
extern "C" {
|
|
#endif
|
|
|
|
-#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__gnu_linux__) \
|
|
- || defined(__FreeBSD__ ) || defined(__NetBSD__) || defined(__OpenBSD__)
|
|
-#define USE_F_MUTEX
|
|
-#define USE_MUTEX_ADAPTIVE
|
|
-
|
|
-#else
|
|
#undef USE_F_MUTEX
|
|
#define USE_MUTEX_LOCK
|
|
|
|
-#endif
|
|
#define USE_ATOMIC_SPIN
|
|
|
|
#define MAX_FUTEX_SPINCNT 10
|
|
--- a/src/lshpack/lshpack.c
|
|
+++ b/src/lshpack/lshpack.c
|
|
@@ -32,7 +32,7 @@
|
|
#if LS_HPACK_EMIT_TEST_CODE
|
|
#include "lshpack-test.h"
|
|
#endif
|
|
-#include XXH_HEADER_NAME
|
|
+#include "lsr/xxhash.h"
|
|
|
|
#ifndef LS_HPACK_USE_LARGE_TABLES
|
|
#define LS_HPACK_USE_LARGE_TABLES 1
|
|
--- a/src/lsr/ls_lock.c
|
|
+++ b/src/lsr/ls_lock.c
|
|
@@ -124,11 +124,7 @@
|
|
#else /* defined(USE_MUTEX_ADAPTIVE) */
|
|
/* pthread_mutexattr_settype(&myAttr, PTHREAD_MUTEX_NORMAL); */
|
|
pthread_mutexattr_settype(&myAttr,
|
|
-#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__gnu_linux__)
|
|
- PTHREAD_MUTEX_ERRORCHECK_NP
|
|
-#else /* defined(linux) */
|
|
PTHREAD_MUTEX_ERRORCHECK
|
|
-#endif /* defined(linux) */
|
|
);
|
|
#endif /* defined(USE_MUTEX_ADAPTIVE) */
|
|
/* pthread_mutexattr_settype(&myAttr, PTHREAD_MUTEX_RECURSIVE); */
|
|
|
|
|
|
@@ -1854,7 +1854,7 @@
|
|
#if defined(__FreeBSD__ ) || defined(__NetBSD__) || defined(__OpenBSD__) \
|
|
|| defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)
|
|
#include <sys/types.h>
|
|
-#include <sys/sysctl.h>
|
|
+#include <linux/sysctl.h>
|
|
#include <sys/user.h>
|
|
static long getProcessStartTime(int pid)
|
|
{
|
|
|
|
--- a/src/sslpp/sslcontext.cpp
|
|
+++ b/src/sslpp/sslcontext.cpp
|
|
@@ -33,9 +33,9 @@
|
|
#define static_assert(a, b) _Static_assert(a, b)
|
|
#endif
|
|
|
|
-#include <openssl/err.h>
|
|
-#include <openssl/rand.h>
|
|
-#include <openssl/ssl.h>
|
|
+#include <../ssl/include/openssl/err.h>
|
|
+#include <../ssl/include/openssl/rand.h>
|
|
+#include <../ssl/include/openssl/ssl.h>
|
|
|
|
#include <assert.h>
|
|
#include <ctype.h>
|
|
--- a/src/sslpp/sslsesscache.h
|
|
+++ b/src/sslpp/sslsesscache.h
|
|
@@ -25,6 +25,7 @@
|
|
#include <util/tsingleton.h>
|
|
#include <stdint.h>
|
|
#include <unistd.h>
|
|
+#include <time.h>
|
|
|
|
|
|
#define LS_SSLSESSCACHE_DEFAULTSIZE 40*1024
|