Files
haikuports/dev-libs/nss/patches/nss-3.23.patchset
2018-04-27 21:54:33 +02:00

185 lines
4.2 KiB
Plaintext

From 6ef42b03e65f0c2b51361f9bcf8cac760aaa09dd Mon Sep 17 00:00:00 2001
From: Kacper Kasper <kacperkasper@gmail.com>
Date: Sat, 5 Jul 2014 02:12:23 +0200
Subject: Haiku support
diff --git a/coreconf/BeOS.mk b/coreconf/BeOS.mk
index 750696d..b53cfea 100644
--- a/coreconf/BeOS.mk
+++ b/coreconf/BeOS.mk
@@ -7,7 +7,7 @@ include $(CORE_DEPTH)/coreconf/UNIX.mk
XP_DEFINE := $(XP_DEFINE:-DXP_UNIX=-DXP_BEOS)
-USE_PTHREADS =
+USE_PTHREADS = 1
ifeq ($(USE_PTHREADS),1)
IMPL_STRATEGY = _PTH
@@ -27,7 +27,7 @@ else
CPU_ARCH = x86
endif
-MKSHLIB = $(CC) -nostart -Wl,-soname -Wl,$(@:$(OBJDIR)/%.so=%.so)
+MKSHLIB = $(CC) -shared -Wl,-soname -Wl,$(@:$(OBJDIR)/%.so=%.so)
ifdef BUILD_OPT
OPTIMIZER = -O2
endif
diff --git a/coreconf/arch.mk b/coreconf/arch.mk
index 62ba8d5..d515a20 100644
--- a/coreconf/arch.mk
+++ b/coreconf/arch.mk
@@ -40,6 +40,14 @@ else
OS_RELEASE := $(shell uname -r)
endif
+#
+# Force the Haiku machines to use BeOS.
+#
+
+ifeq ($(OS_ARCH),Haiku)
+ OS_ARCH = BeOS
+endif
+
#
# Force the IRIX64 machines to use IRIX.
#
diff --git a/lib/dbm/include/mcom_db.h b/lib/dbm/include/mcom_db.h
index 0a4f6dc..09a6061 100644
--- a/lib/dbm/include/mcom_db.h
+++ b/lib/dbm/include/mcom_db.h
@@ -60,7 +60,7 @@ typedef PRUint32 uint32;
#include <sys/byteorder.h>
#endif
-#if defined(__linux) || defined(__BEOS__)
+#if defined(__linux) || defined(BEOS)
#include <endian.h>
#ifndef BYTE_ORDER
#define BYTE_ORDER __BYTE_ORDER
--
2.16.2
From 6473ce45ba7fdbc3540d1eeb0dcb5dc5abf0ece4 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Thu, 25 Sep 2014 13:09:35 +0000
Subject: define RTLD_NOLOAD
diff --git a/lib/freebl/stubs.c b/lib/freebl/stubs.c
index ed2b643..99a9609 100644
--- a/lib/freebl/stubs.c
+++ b/lib/freebl/stubs.c
@@ -605,6 +605,10 @@ freebl_InitNSSUtil(void *lib)
return SECSuccess;
}
+#ifndef RTLD_NOLOAD
+ #define RTLD_NOLOAD 0
+#endif
+
/*
* fetch the library if it's loaded. For NSS it should already be loaded
*/
--
2.16.2
From b9f37c9372cb256d72f882db3be942131607020a Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Thu, 25 Sep 2014 13:40:13 +0000
Subject: skip optionally the signing part
diff --git a/cmd/shlibsign/Makefile b/cmd/shlibsign/Makefile
index 83f90fa..8934439 100644
--- a/cmd/shlibsign/Makefile
+++ b/cmd/shlibsign/Makefile
@@ -95,5 +95,7 @@ else
endif
endif
+ifndef SKIP_SHLIBSIGN
libs install :: $(CHECKLOC)
+endif
diff --git a/coreconf/BeOS.mk b/coreconf/BeOS.mk
index b53cfea..51fe162 100644
--- a/coreconf/BeOS.mk
+++ b/coreconf/BeOS.mk
@@ -45,3 +45,5 @@ ARCH = beos
DSO_CFLAGS = -fPIC
DSO_LDOPTS =
+
+SKIP_SHLIBSIGN=1
--
2.16.2
From a8b3d9367ad80b2c537622240c94ade5aaf880b2 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Thu, 25 Sep 2014 14:14:26 +0000
Subject: use system libs
diff --git a/coreconf/BeOS.mk b/coreconf/BeOS.mk
index 51fe162..fe54580 100644
--- a/coreconf/BeOS.mk
+++ b/coreconf/BeOS.mk
@@ -47,3 +47,6 @@ DSO_CFLAGS = -fPIC
DSO_LDOPTS =
SKIP_SHLIBSIGN=1
+USE_SYSTEM_ZLIB = 1
+ZLIB_LIBS = -lz
+NSS_USE_SYSTEM_SQLITE=1
--
2.16.2
From 030f82d941b36e67949b9796b5697304eab3f91f Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Tue, 24 Nov 2015 19:12:08 +0000
Subject: avoid some tests.
diff --git a/coreconf/BeOS.mk b/coreconf/BeOS.mk
index fe54580..3bc0ce3 100644
--- a/coreconf/BeOS.mk
+++ b/coreconf/BeOS.mk
@@ -50,3 +50,4 @@ SKIP_SHLIBSIGN=1
USE_SYSTEM_ZLIB = 1
ZLIB_LIBS = -lz
NSS_USE_SYSTEM_SQLITE=1
+NSS_DISABLE_GTESTS=1
--
2.16.2
From f05a1c872745baa9382bff6fe2b23a9a1a9f6fa1 Mon Sep 17 00:00:00 2001
From: Kacper Kasper <kacperkasper@gmail.com>
Date: Fri, 27 Apr 2018 21:38:56 +0200
Subject: Enable -Bsymbolic for BeOS target
* Fixes infinite loop in RNG_RNGInit.
diff --git a/lib/freebl/Makefile b/lib/freebl/Makefile
index 4d1860b..f6b1f43 100644
--- a/lib/freebl/Makefile
+++ b/lib/freebl/Makefile
@@ -277,7 +277,7 @@ endif
# to bind the blapi function references in FREEBLVector vector
# (ldvector.c) to the blapi functions defined in the freebl
# shared libraries.
-ifeq (,$(filter-out BSD_OS FreeBSD Linux NetBSD OpenBSD, $(OS_TARGET)))
+ifeq (,$(filter-out BSD_OS FreeBSD Linux NetBSD OpenBSD BeOS, $(OS_TARGET)))
MKSHLIB += -Wl,-Bsymbolic
endif
--
2.16.2