[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - download.lst external/nss

Jan-Marek Glogowski (via logerrit) logerrit at kemper.freedesktop.org
Wed Aug 19 05:29:29 UTC 2020


 download.lst                                         |    4 -
 external/nss/ExternalProject_nss.mk                  |    6 +-
 external/nss/UnpackedTarball_nss.mk                  |   34 ++++++++--------
 external/nss/nsinstall.py                            |    7 ++-
 external/nss/nss-3.13.5-zlib-werror.patch            |    7 +--
 external/nss/nss-win32-make.patch.1                  |    2 
 external/nss/nss.nspr-parallel-win-debug_build.patch |   40 +++++++++++++++++++
 external/nss/nss.windows.patch                       |    4 -
 8 files changed, 75 insertions(+), 29 deletions(-)

New commits:
commit 97ff5ea60e1b465e33a8a56b748213add5b25b19
Author:     Jan-Marek Glogowski <glogow at fbihome.de>
AuthorDate: Wed Jun 26 18:09:19 2019 +0200
Commit:     Andras Timar <andras.timar at collabora.com>
CommitDate: Wed Aug 19 07:28:56 2020 +0200

    NSS: enable parallel build
    
    Since NSS 3.53, the Makefile based build should be fixed (upstream
    bug 290526). The only missing patch is a minimal NSPR fix for the
    "NSPR, configure + make, parallel, Windows, MS VS, debug" build.
    That patch isn't incuded in the NSPR 4.25 release (but it's already
    in the mercurial repo for NSPR 4.26).
    
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95218
    Tested-by: Jenkins
    Reviewed-by: Jan-Marek Glogowski <glogow at fbihome.de>
    (cherry picked from commit b56e8d6def26a0430853835e997f1be841840a61)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100419
    Reviewed-by: Michael Stahl <michael.stahl at cib.de>
    (cherry picked from commit c1bce55faebd9ad8751d7b6b9a7f77dff7b3d507)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100589
    (cherry picked from commit 3e4dbb1708d4b3b7619602b63602b884a7bb2caa)
    
    Change-Id: I8eaa3792a12bdff734e56ac3f552991478957e23
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100863
    Tested-by: Michael Stahl <michael.stahl at cib.de>
    Reviewed-by: Michael Stahl <michael.stahl at cib.de>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100902
    Tested-by: Andras Timar <andras.timar at collabora.com>
    Reviewed-by: Andras Timar <andras.timar at collabora.com>

diff --git a/download.lst b/download.lst
index 842e98a33dd7..4668fc931810 100644
--- a/download.lst
+++ b/download.lst
@@ -203,8 +203,8 @@ export MYTHES_SHA256SUM := 1e81f395d8c851c3e4e75b568e20fa2fa549354e75ab397f9de4b
 export MYTHES_TARBALL := a8c2c5b8f09e7ede322d5c602ff6a4b6-mythes-1.2.4.tar.gz
 export NEON_SHA256SUM := db0bd8cdec329b48f53a6f00199c92d5ba40b0f015b153718d1b15d3d967fbca
 export NEON_TARBALL := neon-0.30.2.tar.gz
-export NSS_SHA256SUM := 07d4276168f59bb3038c7826dabb5fbfbab8336ddf65e4e6e43bce89ada78c64
-export NSS_TARBALL := nss-3.47.1-with-nspr-4.23.tar.gz
+export NSS_SHA256SUM := 861a4510b7c21516f49a4cfa5b871aa796e4e1ef2dfe949091970e56f9d60cdf
+export NSS_TARBALL := nss-3.53-with-nspr-4.25.tar.gz
 export ODFGEN_SHA256SUM := 2c7b21892f84a4c67546f84611eccdad6259875c971e98ddb027da66ea0ac9c2
 export ODFGEN_VERSION_MICRO := 6
 export ODFGEN_TARBALL := libodfgen-0.1.$(ODFGEN_VERSION_MICRO).tar.bz2
diff --git a/external/nss/ExternalProject_nss.mk b/external/nss/ExternalProject_nss.mk
index 4d175e184da5..6a344da33c83 100644
--- a/external/nss/ExternalProject_nss.mk
+++ b/external/nss/ExternalProject_nss.mk
@@ -19,11 +19,11 @@ ifeq ($(OS),WNT)
 $(call gb_ExternalProject_get_state_target,nss,build): $(call gb_ExternalExecutable_get_dependencies,python)
 	$(call gb_ExternalProject_run,build,\
 		$(if $(MSVC_USE_DEBUG_RUNTIME),USE_DEBUG_RTL=1,BUILD_OPT=1) \
-		MOZ_MSVCVERSION=9 OS_TARGET=WIN95 \
+		OS_TARGET=WIN95 \
 		$(if $(filter X86_64,$(CPUNAME)),USE_64=1) \
 		LIB="$(ILIB)" \
 		XCFLAGS="-arch:SSE $(SOLARINC)" \
-		$(MAKE) -j1 nss_build_all RC="rc.exe $(SOLARINC)" \
+		$(MAKE) nss_build_all RC="rc.exe $(SOLARINC)" \
 			NSINSTALL='$(call gb_ExternalExecutable_get_command,python) $(SRCDIR)/external/nss/nsinstall.py' \
 			NSS_DISABLE_GTESTS=1 \
 	,nss)
@@ -46,7 +46,7 @@ $(call gb_ExternalProject_get_state_target,nss,build): $(call gb_ExternalExecuta
 			$(if $(filter iOS-ARM,$(OS)-$(CPUNAME)),CPU_ARCH=arm) \
 			NSPR_CONFIGURE_OPTS="--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)") \
 		NSDISTMODE=copy \
-		$(MAKE) -j1 AR="$(AR)" \
+		$(MAKE) AR="$(AR)" \
 			RANLIB="$(RANLIB)" \
 			NMEDIT="$(NM)edit" \
 			COMMA=$(COMMA) \
diff --git a/external/nss/UnpackedTarball_nss.mk b/external/nss/UnpackedTarball_nss.mk
index 9783b1928097..92902b2da6bf 100644
--- a/external/nss/UnpackedTarball_nss.mk
+++ b/external/nss/UnpackedTarball_nss.mk
@@ -12,32 +12,32 @@ $(eval $(call gb_UnpackedTarball_UnpackedTarball,nss))
 $(eval $(call gb_UnpackedTarball_set_tarball,nss,$(NSS_TARBALL)))
 
 $(eval $(call gb_UnpackedTarball_add_patches,nss,\
-	external/nss/nss.patch \
-	external/nss/nss.aix.patch \
-	external/nss/nss-3.13.5-zlib-werror.patch \
-	external/nss/nss_macosx.patch \
-	external/nss/nss-win32-make.patch.1 \
-	$(if $(filter WNT,$(OS)),external/nss/nss.windows.patch \
-        external/nss/nss.nowerror.patch \
-		external/nss/nss.vs2015.patch) \
+    external/nss/nss.patch \
+    external/nss/nss.aix.patch \
+    external/nss/nss-3.13.5-zlib-werror.patch \
+    external/nss/nss_macosx.patch \
+    external/nss/nss-win32-make.patch.1 \
     external/nss/ubsan.patch.0 \
     external/nss/clang-cl.patch.0 \
+    external/nss/nss.vs2015.patch \
+    external/nss/nss.vs2015.pdb.patch \
+    external/nss/nss.nspr-parallel-win-debug_build.patch \
     $(if $(filter iOS,$(OS)), \
         external/nss/nss-ios.patch) \
-	$(if $(filter MSC-INTEL,$(COM)-$(CPUNAME)), \
-		external/nss/nss.cygwin64.in32bit.patch) \
-	$(if $(filter WNT,$(OS)), \
-		external/nss/nss.vs2015.pdb.patch) \
-	$(if $(filter WNT,$(OS)), \
-    	external/nss/nss.utf8bom.patch.1) \
-	$(if $(filter ANDROID,$(OS)), \
-		external/nss/nss-android.patch.1) \
+    $(if $(filter ANDROID,$(OS)), \
+        external/nss/nss-android.patch.1) \
+    $(if $(filter MSC-INTEL,$(COM)-$(CPUNAME)), \
+        external/nss/nss.cygwin64.in32bit.patch) \
+    $(if $(filter WNT,$(OS)), \
+        external/nss/nss.windows.patch \
+        external/nss/nss.nowerror.patch \
+        external/nss/nss.utf8bom.patch.1) \
 ))
 
 ifeq ($(COM_IS_CLANG),TRUE)
 ifneq ($(filter -fsanitize=%,$(CC)),)
 $(eval $(call gb_UnpackedTarball_add_patches,nss,\
-	external/nss/asan.patch.1 \
+    external/nss/asan.patch.1 \
 ))
 endif
 endif
diff --git a/external/nss/nsinstall.py b/external/nss/nsinstall.py
index 31b3de3450c5..80e9c1679373 100644
--- a/external/nss/nsinstall.py
+++ b/external/nss/nsinstall.py
@@ -155,7 +155,12 @@ def nsinstall(argv):
   target = args.pop()
   # ensure target directory
   if not os.path.isdir(target):
-    os.makedirs(target)
+    try:
+      os.makedirs(target)
+    except FileExistsError:
+      if not os.path.isdir(target):
+        sys.stderr.write('nsinstall: ' + target + ' is not a directoy!\n')
+        return 1
 
   copy_all_entries(args, target)
   return 0
diff --git a/external/nss/nss-3.13.5-zlib-werror.patch b/external/nss/nss-3.13.5-zlib-werror.patch
index 6cda50023f1b..0cdbf7808f81 100644
--- a/external/nss/nss-3.13.5-zlib-werror.patch
+++ b/external/nss/nss-3.13.5-zlib-werror.patch
@@ -1,9 +1,10 @@
 --- a/a/nss/lib/zlib/gzguts.h	2010-08-22 03:07:03.000000000 +0200
 +++ b/b/nss/lib/zlib/gzguts.h	2012-07-17 08:52:14.821552788 +0200
-@@ -26,6 +26,9 @@
- #  include <limits.h>
+@@ -26,6 +26,10 @@
+ #  define write _write
+ #  define close _close
  #endif
- #include <fcntl.h>
++
 +#ifndef _WIN32
 +#include <unistd.h>
 +#endif
diff --git a/external/nss/nss-win32-make.patch.1 b/external/nss/nss-win32-make.patch.1
index bc5a759275e2..7ba3df451ee6 100644
--- a/external/nss/nss-win32-make.patch.1
+++ b/external/nss/nss-win32-make.patch.1
@@ -1,7 +1,7 @@
 --- nss/nss/coreconf/rules.mk.orig2	2014-06-03 15:30:01.667200000 +0200
 +++ nss/nss/coreconf/rules.mk	2014-06-03 15:30:14.537200000 +0200
 @@ -259,7 +259,7 @@
- 	@$(MAKE_OBJDIR)
+ $(LIBRARY): $(OBJS) | $$(@D)/d
  	rm -f $@
  ifeq (,$(filter-out _WIN%,$(NS_USE_GCC)_$(OS_TARGET)))
 -	$(AR) $(subst /,\\,$(OBJS))
diff --git a/external/nss/nss.nspr-parallel-win-debug_build.patch b/external/nss/nss.nspr-parallel-win-debug_build.patch
new file mode 100644
index 000000000000..86b55e1ccf7f
--- /dev/null
+++ b/external/nss/nss.nspr-parallel-win-debug_build.patch
@@ -0,0 +1,40 @@
+Änderung:        4866:23940b78e965
+Nutzer:          Jan-Marek Glogowski <glogow at fbihome.de>
+Datum:           Fri May 01 22:50:55 2020 +0000
+Dateien:         pr/tests/Makefile.in
+Beschreibung:
+Bug 290526 Write separate PDBs for test OBJs r=glandium
+
+Quite often when running a parallel NSS build, I get the following
+compiler error message, resulting in a build failure, despite
+compiling with the -FS flag:
+
+.../nss/nspr/pr/tests/zerolen.c: fatal error C1041:
+Programmdatenbank "...\nss\nspr\out\pr\tests\vc140.pdb" kann nicht
+ge<94>ffnet werden; verwenden Sie /FS, wenn mehrere CL.EXE in
+dieselbe .PDB-Datei schreiben.
+
+The failing source file is always one of the last test object
+files. But the actual problem is not the compiler accessing the
+PDB file, but the linker already linking the first test
+executables accessing the shared PDB; at least that's my guess.
+
+So instead of using a shared PDB for all test object files, this
+uses -Fd$(@:.$(OBJ_SUFFIX)=.pdb) to write a separate PDB for every
+test's object file. The linker works fine with the shared OBJ PDB.
+
+Differential Revision: https://phabricator.services.mozilla.com/D68693
+
+
+diff -r 219d131499d5 -r 23940b78e965 nss/nspr/pr/tests/Makefile.in
+--- a/nss/nspr/pr/tests/Makefile.in	Mon Feb 10 20:58:42 2020 +0000
++++ b/nss/nspr/pr/tests/Makefile.in	Fri May 01 22:50:55 2020 +0000
+@@ -211,6 +211,7 @@
+ else
+   EXTRA_LIBS += ws2_32.lib
+   LDOPTS = -NOLOGO -DEBUG -DEBUGTYPE:CV -INCREMENTAL:NO
++  CFLAGS += -Fd$(@:.$(OBJ_SUFFIX)=.pdb)
+   ifdef PROFILE
+     LDOPTS += -PROFILE -MAP
+   endif # profile
+
diff --git a/external/nss/nss.windows.patch b/external/nss/nss.windows.patch
index 9dbeaa946520..901846e7bc1f 100644
--- a/external/nss/nss.windows.patch
+++ b/external/nss/nss.windows.patch
@@ -18,8 +18,8 @@
 -core_abspath = '$(if $(findstring :,$(1)),$(1),$(if $(filter /%,$(1)),$(1),$(PWD)/$(1)))'
 +core_abspath = '$(if $(findstring :,$(1)),$(1),$(if $(filter /%,$(shell cygpath -m $(1))),$(1),$(shell cygpath -m $(PWD)/$(1))))'
  
- $(OBJDIR)/$(PROG_PREFIX)%$(OBJ_SUFFIX): %.c
- 	@$(MAKE_OBJDIR)
+ $(OBJDIR)/$(PROG_PREFIX)%$(OBJ_SUFFIX): %.c | $$(@D)/d
+ ifdef USE_NT_C_SYNTAX
 --- a/a/nspr/pr/include/md/_win95.h
 +++ b/b/nspr/pr/include/md/_win95.h
 @@ -312,7 +312,7 @@


More information about the Libreoffice-commits mailing list