From 233eace07d8f98572b543a73c02f6d84af283552 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Thu, 29 Nov 2018 13:27:16 -0500 Subject: [PATCH 01/10] Update to 10.14.1 - https://nodejs.org/en/blog/release/v10.14.0/ - https://nodejs.org/en/blog/release/v10.14.1/ Signed-off-by: Stephen Gallagher --- nodejs.spec | 13 +++++++++++-- sources | 2 +- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/nodejs.spec b/nodejs.spec index 2a8fed3..bc42ef2 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -20,8 +20,8 @@ # than a Fedora release lifecycle. %global nodejs_epoch 1 %global nodejs_major 10 -%global nodejs_minor 13 -%global nodejs_patch 0 +%global nodejs_minor 14 +%global nodejs_patch 1 %global nodejs_abi %{nodejs_major}.%{nodejs_minor} %global nodejs_version %{nodejs_major}.%{nodejs_minor}.%{nodejs_patch} %global nodejs_release 1 @@ -412,6 +412,10 @@ find %{buildroot}%{_prefix}/lib/node_modules/npm \ -executable -type f \ -exec chmod -x {} \; +# The above command is a little overzealous. Add a few permissions back. +chmod 0755 %{buildroot}%{_prefix}/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin/node-gyp +chmod 0755 %{buildroot}%{_prefix}/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js + %check # Fail the build if the versions don't match @@ -494,6 +498,11 @@ end %{_pkgdocdir}/npm/doc %changelog +* Thu Nov 29 2018 Stephen Gallagher - 1:10.14.1-1 +- Update to 10.14.1 +- https://nodejs.org/en/blog/release/v10.14.0/ +- https://nodejs.org/en/blog/release/v10.14.1/ + * Thu Nov 01 2018 Stephen Gallagher - 1:10.13.0-1 - Update to 10.13.0 - https://nodejs.org/en/blog/release/v10.13.0/ diff --git a/sources b/sources index 3ecaf54..9ac5811 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (node-v10.13.0-stripped.tar.gz) = 2df0905571768b7f1e37ebb2446ce355f1913e56254ba06d566d7e0f3cb5a104c26a9f2fd9bf449f6910628ed785bf81c04569d6701cc1adf1be9b18cc55f22c +SHA512 (node-v10.14.1-stripped.tar.gz) = cbb6f3e6f55b61c52ba0afd7c2f781dfcd024eb81d35778fd9032357578f8f5735e08d9831b985b8c0374dc7b9eb7d689bb00568802a01af1345e5bd5fe2e8de From 494dea3b5f6e1c879f996f229ca6ae2400c8850d Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Wed, 2 Jan 2019 15:18:52 -0500 Subject: [PATCH 02/10] Update to 10.15.0 https://nodejs.org/en/blog/release/v10.15.0/ Signed-off-by: Stephen Gallagher --- nodejs.spec | 16 ++++++++++------ sources | 2 +- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/nodejs.spec b/nodejs.spec index bc42ef2..a169682 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -20,8 +20,8 @@ # than a Fedora release lifecycle. %global nodejs_epoch 1 %global nodejs_major 10 -%global nodejs_minor 14 -%global nodejs_patch 1 +%global nodejs_minor 15 +%global nodejs_patch 0 %global nodejs_abi %{nodejs_major}.%{nodejs_minor} %global nodejs_version %{nodejs_major}.%{nodejs_minor}.%{nodejs_patch} %global nodejs_release 1 @@ -39,7 +39,7 @@ # c-ares - from deps/cares/include/ares_version.h # https://github.com/nodejs/node/pull/9332 %global c_ares_major 1 -%global c_ares_minor 14 +%global c_ares_minor 15 %global c_ares_patch 0 %global c_ares_version %{c_ares_major}.%{c_ares_minor}.%{c_ares_patch} @@ -61,7 +61,7 @@ %global nghttp2_patch 0 %global nghttp2_version %{nghttp2_major}.%{nghttp2_minor}.%{nghttp2_patch} -# ICU - from configure.py in the configure_intl() function +# ICU - from tools/icu/current_ver.dep %global icu_major 62 %global icu_minor 1 %global icu_version %{icu_major}.%{icu_minor} @@ -138,8 +138,8 @@ Provides: bundled(nghttp2) = %{nghttp2_version} %else BuildRequires: nodejs-packaging BuildRequires: systemtap-sdt-devel -BuildRequires: http-parser-devel >= 2.7.0 -Requires: http-parser >= 2.7.0 +BuildRequires: http-parser-devel >= 2.9.0 +Requires: http-parser >= 2.9.0 BuildRequires: libuv-devel >= 1:%{libuv_version} Requires: libuv >= 1:%{libuv_version} BuildRequires: libnghttp2-devel >= %{nghttp2_version} @@ -498,6 +498,10 @@ end %{_pkgdocdir}/npm/doc %changelog +* Wed Jan 02 2019 Stephen Gallagher - 1:10.15.0-1 +- Update to 10.15.0 +- https://nodejs.org/en/blog/release/v10.15.0/ + * Thu Nov 29 2018 Stephen Gallagher - 1:10.14.1-1 - Update to 10.14.1 - https://nodejs.org/en/blog/release/v10.14.0/ diff --git a/sources b/sources index 9ac5811..6b9800b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (node-v10.14.1-stripped.tar.gz) = cbb6f3e6f55b61c52ba0afd7c2f781dfcd024eb81d35778fd9032357578f8f5735e08d9831b985b8c0374dc7b9eb7d689bb00568802a01af1345e5bd5fe2e8de +SHA512 (node-v10.15.0-stripped.tar.gz) = 7f1529852ebd0d374dd7efe8f8cee30c3277d061004965daba7ed14f3e91bdd7c8a71db7953b2043b8eef89a2eab7ab98f5357424b340ac6ff328ff921edec76 From 89005563c3dd09a3f761c87f0ab98e79d5d9615d Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Fri, 1 Mar 2019 13:02:24 -0500 Subject: [PATCH 03/10] Update to 10.15.2 - https://nodejs.org/en/blog/release/v10.15.1/ - https://nodejs.org/en/blog/release/v10.15.2/ Signed-off-by: Stephen Gallagher --- 0001-Disable-running-gyp-on-shared-deps.patch | 8 +- ...ess-NPM-message-to-run-global-update.patch | 6 +- 0003-deps-V8-cherry-pick-d0468de.patch | 118 ++++++++++++++++++ nodejs.spec | 22 ++-- sources | 2 +- 5 files changed, 137 insertions(+), 19 deletions(-) create mode 100644 0003-deps-V8-cherry-pick-d0468de.patch diff --git a/0001-Disable-running-gyp-on-shared-deps.patch b/0001-Disable-running-gyp-on-shared-deps.patch index 79cbc7e..9eaaca4 100644 --- a/0001-Disable-running-gyp-on-shared-deps.patch +++ b/0001-Disable-running-gyp-on-shared-deps.patch @@ -1,14 +1,14 @@ -From def28d29f907050d8bcd94ed2e341d128ffa3fa6 Mon Sep 17 00:00:00 2001 +From 443fef828092b315a207a194f5fe74e52e451996 Mon Sep 17 00:00:00 2001 From: Zuzana Svetlikova Date: Thu, 27 Apr 2017 14:25:42 +0200 -Subject: [PATCH 1/2] Disable running gyp on shared deps +Subject: [PATCH 1/3] Disable running gyp on shared deps --- Makefile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile -index 5fc2bb0c58f5532044a14e9f9595b2316f562726..f1c1545caa220d7442d6d92c49412ec7554de123 100644 +index 3a343301d640bc7fd41e9680c74455bb260a950d..d2b9c13ee3e53d957ed32476e40fb09e41fcfded 100644 --- a/Makefile +++ b/Makefile @@ -121,14 +121,13 @@ with-code-cache: @@ -30,5 +30,5 @@ index 5fc2bb0c58f5532044a14e9f9595b2316f562726..f1c1545caa220d7442d6d92c49412ec7 @if [ -x config.status ]; then \ ./config.status; \ -- -2.19.0 +2.20.1 diff --git a/0002-Suppress-NPM-message-to-run-global-update.patch b/0002-Suppress-NPM-message-to-run-global-update.patch index fd54ee2..ceb2723 100644 --- a/0002-Suppress-NPM-message-to-run-global-update.patch +++ b/0002-Suppress-NPM-message-to-run-global-update.patch @@ -1,7 +1,7 @@ -From ab6c18fd9aba942bee3f2f8030273c846b6025a6 Mon Sep 17 00:00:00 2001 +From 0fd4649d1943f45cb06bda6febdc7ffa7d5859b2 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 1 May 2018 08:05:30 -0400 -Subject: [PATCH 2/2] Suppress NPM message to run global update +Subject: [PATCH 2/3] Suppress NPM message to run global update Signed-off-by: Stephen Gallagher --- @@ -83,5 +83,5 @@ index 6f76b23828531e7af98a7e3cd7d5abfaac09b40c..98edb6f45fe073e03794a2ae6e7aa7f5 !err && npm.config.get('ham-it-up') && -- -2.19.0 +2.20.1 diff --git a/0003-deps-V8-cherry-pick-d0468de.patch b/0003-deps-V8-cherry-pick-d0468de.patch new file mode 100644 index 0000000..4fe73a7 --- /dev/null +++ b/0003-deps-V8-cherry-pick-d0468de.patch @@ -0,0 +1,118 @@ +From 7108faf1bbcd1e542cd4c34bb57e76432da754f4 Mon Sep 17 00:00:00 2001 +From: Milad Farazmand +Date: Wed, 30 Jan 2019 19:08:06 +0000 +Subject: [PATCH 3/3] deps: V8: cherry-pick d0468de + +Original commit message: + + [heap] Fix StoreBuffer setup. + + - Solves a problem for PPC in a configuration where commit page size + is 64K. https://chromium-review.googlesource.com/c/v8/v8/+/1149515 + - Uses existing VM allocation code to get properly aligned memory. + - Makes sure the size for SetPermissions is a multiple of system page + size. + + Bug:chromium:756050 + + Change-Id: Ib3799ab7a3bb44b0091c234234c1cc47938379c2 + Reviewed-on: https://chromium-review.googlesource.com/1161210 + Commit-Queue: Bill Budge + Reviewed-by: Michael Lippautz + Reviewed-by: Michael Starzinger + Cr-Commit-Position: refs/heads/master@{#54930} + +Refs: https://github.com/v8/v8/commit/d0468dede05fcd57b5a96d0fbfa117a76795fa58 +--- + common.gypi | 2 +- + deps/v8/src/heap/store-buffer.cc | 28 +++++++++++++++++----------- + 2 files changed, 18 insertions(+), 12 deletions(-) + +diff --git a/common.gypi b/common.gypi +index 0a4ed881a5b92514d3df88ffc74555931eb71b7c..1405183bf61dfbab8c8b18a6233a08a7a1ad62ec 100644 +--- a/common.gypi ++++ b/common.gypi +@@ -31,11 +31,11 @@ + # Default to -O0 for debug builds. + 'v8_optimized_debug%': 0, + + # Reset this number to 0 on major V8 upgrades. + # Increment by one for each non-official patch applied to deps/v8. +- 'v8_embedder_string': '-node.12', ++ 'v8_embedder_string': '-node.13', + + # Enable disassembler for `--print-code` v8 options + 'v8_enable_disassembler': 1, + + # Don't bake anything extra into the snapshot. +diff --git a/deps/v8/src/heap/store-buffer.cc b/deps/v8/src/heap/store-buffer.cc +index d73e3235c158df27756eb719643f81822d2bd015..657aa9212a6153f3bd1c44e519a3c8c7064c62b4 100644 +--- a/deps/v8/src/heap/store-buffer.cc ++++ b/deps/v8/src/heap/store-buffer.cc +@@ -28,46 +28,52 @@ StoreBuffer::StoreBuffer(Heap* heap) + insertion_callback = &InsertDuringRuntime; + deletion_callback = &DeleteDuringRuntime; + } + + void StoreBuffer::SetUp() { +- // Allocate 3x the buffer size, so that we can start the new store buffer +- // aligned to 2x the size. This lets us use a bit test to detect the end of +- // the area. ++ const size_t requested_size = kStoreBufferSize * kStoreBuffers; ++ // Allocate buffer memory aligned at least to kStoreBufferSize. This lets us ++ // use a bit test to detect the ends of the buffers. ++ const size_t alignment = ++ std::max(kStoreBufferSize, AllocatePageSize()); ++ void* hint = AlignedAddress(heap_->GetRandomMmapAddr(), alignment); + VirtualMemory reservation; +- if (!AllocVirtualMemory(kStoreBufferSize * 3, heap_->GetRandomMmapAddr(), +- &reservation)) { ++ if (!AlignedAllocVirtualMemory(requested_size, alignment, hint, ++ &reservation)) { + heap_->FatalProcessOutOfMemory("StoreBuffer::SetUp"); + } ++ + Address start = reservation.address(); +- start_[0] = reinterpret_cast(::RoundUp(start, kStoreBufferSize)); ++ const size_t allocated_size = reservation.size(); ++ ++ start_[0] = reinterpret_cast(start); + limit_[0] = start_[0] + (kStoreBufferSize / kPointerSize); + start_[1] = limit_[0]; + limit_[1] = start_[1] + (kStoreBufferSize / kPointerSize); + +- Address* vm_limit = reinterpret_cast(start + reservation.size()); +- ++ // Sanity check the buffers. ++ Address* vm_limit = reinterpret_cast(start + allocated_size); + USE(vm_limit); + for (int i = 0; i < kStoreBuffers; i++) { + DCHECK(reinterpret_cast
(start_[i]) >= reservation.address()); + DCHECK(reinterpret_cast
(limit_[i]) >= reservation.address()); + DCHECK(start_[i] <= vm_limit); + DCHECK(limit_[i] <= vm_limit); + DCHECK_EQ(0, reinterpret_cast
(limit_[i]) & kStoreBufferMask); + } + +- if (!reservation.SetPermissions(reinterpret_cast
(start_[0]), +- kStoreBufferSize * kStoreBuffers, ++ // Set RW permissions only on the pages we use. ++ const size_t used_size = RoundUp(requested_size, CommitPageSize()); ++ if (!reservation.SetPermissions(start, used_size, + PageAllocator::kReadWrite)) { + heap_->FatalProcessOutOfMemory("StoreBuffer::SetUp"); + } + current_ = 0; + top_ = start_[current_]; + virtual_memory_.TakeControl(&reservation); + } + +- + void StoreBuffer::TearDown() { + if (virtual_memory_.IsReserved()) virtual_memory_.Free(); + top_ = nullptr; + for (int i = 0; i < kStoreBuffers; i++) { + start_[i] = nullptr; +-- +2.20.1 + diff --git a/nodejs.spec b/nodejs.spec index a169682..57c5e7c 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -1,11 +1,5 @@ %global with_debug 1 -# PowerPC and s390x segfault during Debug builds -# https://github.com/nodejs/node/issues/20642 -%ifarch %{power64} s390x -%global with_debug 0 -%endif - # bundle dependencies that are not available as Fedora modules # %%{!?_with_bootstrap: %%global bootstrap 1} # use bcond for building modules @@ -21,7 +15,7 @@ %global nodejs_epoch 1 %global nodejs_major 10 %global nodejs_minor 15 -%global nodejs_patch 0 +%global nodejs_patch 2 %global nodejs_abi %{nodejs_major}.%{nodejs_minor} %global nodejs_version %{nodejs_major}.%{nodejs_minor}.%{nodejs_patch} %global nodejs_release 1 @@ -124,6 +118,10 @@ Patch1: 0001-Disable-running-gyp-on-shared-deps.patch # This does bad things on an RPM-managed npm. Patch2: 0002-Suppress-NPM-message-to-run-global-update.patch + +# Upstream patch to fix debug generation on PowerPC +Patch3: 0003-deps-V8-cherry-pick-d0468de.patch + BuildRequires: python2-devel BuildRequires: python3-devel BuildRequires: zlib-devel @@ -273,14 +271,11 @@ The API documentation for the Node.js JavaScript runtime. %prep -%setup -q -n node-v%{nodejs_version} +%autosetup -p1 -n node-v%{nodejs_version} # remove bundled dependencies that we aren't building -%patch1 -p1 rm -rf deps/zlib -%patch2 -p1 - # Replace any instances of unversioned python' with python2 pathfix.py -i %{__python2} -pn $(find -type f) find . -type f -exec sed -i "s~/usr\/bin\/env python~/usr/bin/python2~" {} \; @@ -498,6 +493,11 @@ end %{_pkgdocdir}/npm/doc %changelog +* Fri Mar 01 2019 Stephen Gallagher - 1:10.15.2-1 +- Update to 10.15.2 +- https://nodejs.org/en/blog/release/v10.15.1/ +- https://nodejs.org/en/blog/release/v10.15.2/ + * Wed Jan 02 2019 Stephen Gallagher - 1:10.15.0-1 - Update to 10.15.0 - https://nodejs.org/en/blog/release/v10.15.0/ diff --git a/sources b/sources index 6b9800b..23724af 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (node-v10.15.0-stripped.tar.gz) = 7f1529852ebd0d374dd7efe8f8cee30c3277d061004965daba7ed14f3e91bdd7c8a71db7953b2043b8eef89a2eab7ab98f5357424b340ac6ff328ff921edec76 +SHA512 (node-v10.15.2-stripped.tar.gz) = f7971cbeb94bc7079bca090546b30608f333a95b3e82c7fccd581a84ebc21496fd5ee595ce66abce0fdf484d6a2f9d818a2d7110833adec8daa73b885108a19f From ed1e3b3c9814b76fac5c60d9d39b855d8ac911e0 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Fri, 1 Mar 2019 13:09:05 -0500 Subject: [PATCH 04/10] Update package.cfg post-branch Signed-off-by: Stephen Gallagher --- package.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.cfg b/package.cfg index 832eaab..77d2a9c 100644 --- a/package.cfg +++ b/package.cfg @@ -1,2 +1,2 @@ [koji] -targets = master f29 +targets = master f30 f29 From f8ff2da483b777a9489233b66b78d72fb7e51a86 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Thu, 14 Mar 2019 04:52:06 +0000 Subject: [PATCH 05/10] Drop the debug executable. --- nodejs.spec | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) diff --git a/nodejs.spec b/nodejs.spec index 57c5e7c..5797775 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -1,5 +1,3 @@ -%global with_debug 1 - # bundle dependencies that are not available as Fedora modules # %%{!?_with_bootstrap: %%global bootstrap 1} # use bcond for building modules @@ -18,7 +16,7 @@ %global nodejs_patch 2 %global nodejs_abi %{nodejs_major}.%{nodejs_minor} %global nodejs_version %{nodejs_major}.%{nodejs_minor}.%{nodejs_patch} -%global nodejs_release 1 +%global nodejs_release 2 # == Bundled Dependency Versions == # v8 - from deps/v8/include/v8-version.h @@ -330,12 +328,7 @@ export LDFLAGS="%{build_ldflags}" --openssl-use-def-ca-store %endif -%if %{?with_debug} == 1 -# Setting BUILDTYPE=Debug builds both release and debug binaries -make BUILDTYPE=Debug %{?_smp_mflags} -%else make BUILDTYPE=Release %{?_smp_mflags} -%endif %install @@ -346,11 +339,6 @@ rm -rf %{buildroot} # Set the binary permissions properly chmod 0755 %{buildroot}/%{_bindir}/node -%if %{?with_debug} == 1 -# Install the debug binary and set its permissions -install -Dpm0755 out/Debug/node %{buildroot}/%{_bindir}/node_g -%endif - # own the sitelib directory mkdir -p %{buildroot}%{_prefix}/lib/node_modules @@ -464,9 +452,6 @@ end %files devel -%if %{?with_debug} == 1 -%{_bindir}/node_g -%endif %{_includedir}/node %{_datadir}/node/common.gypi %{_pkgdocdir}/gdbinit @@ -493,6 +478,9 @@ end %{_pkgdocdir}/npm/doc %changelog +* Thu Mar 14 2019 Elliott Sales de Andrade - 1:10.15.2-2 +- Drop debug executable + * Fri Mar 01 2019 Stephen Gallagher - 1:10.15.2-1 - Update to 10.15.2 - https://nodejs.org/en/blog/release/v10.15.1/ From 3dd1c93fd4881e468d717b8df28e7370b78ee84b Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Wed, 20 Mar 2019 03:25:48 +0000 Subject: [PATCH 06/10] Build with a shared library. --- ...Install-both-binaries-and-use-libdir.patch | 87 +++++++++++++++++++ nodejs.spec | 26 ++++-- 2 files changed, 108 insertions(+), 5 deletions(-) create mode 100644 0001-Install-both-binaries-and-use-libdir.patch diff --git a/0001-Install-both-binaries-and-use-libdir.patch b/0001-Install-both-binaries-and-use-libdir.patch new file mode 100644 index 0000000..23dcb31 --- /dev/null +++ b/0001-Install-both-binaries-and-use-libdir.patch @@ -0,0 +1,87 @@ +From c38964d69ebb93e2273eca4bdcc4370fa26926f8 Mon Sep 17 00:00:00 2001 +From: Elliott Sales de Andrade +Date: Tue, 19 Mar 2019 23:22:40 -0400 +Subject: [PATCH] Install both binaries and use libdir. + +This allows us to build with a shared library for other users while +still providing the normal executable. + +Signed-off-by: Elliott Sales de Andrade +--- + configure.py | 7 +++++++ + tools/install.py | 31 ++++++++++++++----------------- + 2 files changed, 21 insertions(+), 17 deletions(-) + +diff --git a/configure.py b/configure.py +index b62be2302c..0924fa96dc 100755 +--- a/configure.py ++++ b/configure.py +@@ -552,6 +552,12 @@ parser.add_option('--shared', + help='compile shared library for embedding node in another project. ' + + '(This mode is not officially supported for regular applications)') + ++parser.add_option('--libdir', ++ action='store', ++ dest='libdir', ++ default='lib', ++ help='a directory to install the shared library into') ++ + parser.add_option('--without-v8-platform', + action='store_true', + dest='without_v8_platform', +@@ -1094,6 +1100,7 @@ def configure_node(o): + if options.code_cache_path: + o['variables']['node_code_cache_path'] = options.code_cache_path + o['variables']['node_shared'] = b(options.shared) ++ o['variables']['libdir'] = options.libdir + node_module_version = getmoduleversion.get_version() + + if sys.platform == 'darwin': +diff --git a/tools/install.py b/tools/install.py +index ce9ceeee1d..5ac67b714e 100755 +--- a/tools/install.py ++++ b/tools/install.py +@@ -116,26 +116,23 @@ def subdir_files(path, dest, action): + + def files(action): + is_windows = sys.platform == 'win32' +- output_file = 'node' + output_prefix = 'out/Release/' ++ output_libprefix = output_prefix + +- if 'false' == variables.get('node_shared'): +- if is_windows: +- output_file += '.exe' ++ if is_windows: ++ output_bin = 'node.exe' ++ output_lib = 'node.dll' + else: +- if is_windows: +- output_file += '.dll' +- else: +- output_file = 'lib' + output_file + '.' + variables.get('shlib_suffix') +- # GYP will output to lib.target except on OS X, this is hardcoded +- # in its source - see the _InstallableTargetInstallPath function. +- if sys.platform != 'darwin': +- output_prefix += 'lib.target/' +- +- if 'false' == variables.get('node_shared'): +- action([output_prefix + output_file], 'bin/' + output_file) +- else: +- action([output_prefix + output_file], 'lib/' + output_file) ++ output_bin = 'node' ++ output_lib = 'libnode.' + variables.get('shlib_suffix') ++ # GYP will output to lib.target except on OS X, this is hardcoded ++ # in its source - see the _InstallableTargetInstallPath function. ++ if sys.platform != 'darwin': ++ output_libprefix += 'lib.target/' ++ ++ action([output_prefix + output_bin], 'bin/' + output_bin) ++ if 'true' == variables.get('node_shared'): ++ action([output_libprefix + output_lib], variables.get('libdir') + '/' + output_lib) + + if 'true' == variables.get('node_use_dtrace'): + action(['out/Release/node.d'], 'lib/dtrace/node.d') +-- +2.20.1 + diff --git a/nodejs.spec b/nodejs.spec index 5797775..b80f0fa 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -15,6 +15,7 @@ %global nodejs_minor 15 %global nodejs_patch 2 %global nodejs_abi %{nodejs_major}.%{nodejs_minor} +%global nodejs_soversion 64 %global nodejs_version %{nodejs_major}.%{nodejs_minor}.%{nodejs_patch} %global nodejs_release 2 @@ -120,11 +121,15 @@ Patch2: 0002-Suppress-NPM-message-to-run-global-update.patch # Upstream patch to fix debug generation on PowerPC Patch3: 0003-deps-V8-cherry-pick-d0468de.patch +# Patch to install both node and libnode.so, using the correct libdir +Patch5: 0001-Install-both-binaries-and-use-libdir.patch + BuildRequires: python2-devel BuildRequires: python3-devel BuildRequires: zlib-devel BuildRequires: gcc >= 4.9.4 BuildRequires: gcc-c++ >= 4.9.4 +BuildRequires: chrpath #%if ! 0%%{?bootstrap} %if %{with bootstrap} @@ -309,6 +314,8 @@ export LDFLAGS="%{build_ldflags}" #%if ! 0%%{?bootstrap} %if %{with bootstrap} ./configure --prefix=%{_prefix} \ + --shared \ + --libdir=%{_lib} \ --shared-openssl \ --shared-zlib \ --without-dtrace \ @@ -317,6 +324,8 @@ export LDFLAGS="%{build_ldflags}" --openssl-use-def-ca-store %else ./configure --prefix=%{_prefix} \ + --shared \ + --libdir=%{_lib} \ --shared-openssl \ --shared-zlib \ --shared-libuv \ @@ -338,6 +347,10 @@ rm -rf %{buildroot} # Set the binary permissions properly chmod 0755 %{buildroot}/%{_bindir}/node +chrpath --delete %{buildroot}%{_bindir}/node + +# Install library symlink +ln -s %{_libdir}/libnode.so.%{nodejs_soversion} %{buildroot}%{_libdir}/libnode.so # own the sitelib directory mkdir -p %{buildroot}%{_prefix}/lib/node_modules @@ -402,15 +415,15 @@ chmod 0755 %{buildroot}%{_prefix}/lib/node_modules/npm/node_modules/node-gyp/bin %check # Fail the build if the versions don't match -%{buildroot}/%{_bindir}/node -e "require('assert').equal(process.versions.node, '%{nodejs_version}')" -%{buildroot}/%{_bindir}/node -e "require('assert').equal(process.versions.v8.replace(/-node\.\d+$/, ''), '%{v8_version}')" -%{buildroot}/%{_bindir}/node -e "require('assert').equal(process.versions.ares.replace(/-DEV$/, ''), '%{c_ares_version}')" +LD_LIBRARY_PATH=%{buildroot}%{_libdir} %{buildroot}/%{_bindir}/node -e "require('assert').equal(process.versions.node, '%{nodejs_version}')" +LD_LIBRARY_PATH=%{buildroot}%{_libdir} %{buildroot}/%{_bindir}/node -e "require('assert').equal(process.versions.v8.replace(/-node\.\d+$/, ''), '%{v8_version}')" +LD_LIBRARY_PATH=%{buildroot}%{_libdir} %{buildroot}/%{_bindir}/node -e "require('assert').equal(process.versions.ares.replace(/-DEV$/, ''), '%{c_ares_version}')" # Ensure we have punycode and that the version matches -%{buildroot}/%{_bindir}/node -e "require(\"assert\").equal(require(\"punycode\").version, '%{punycode_version}')" +LD_LIBRARY_PATH=%{buildroot}%{_libdir} %{buildroot}/%{_bindir}/node -e "require(\"assert\").equal(require(\"punycode\").version, '%{punycode_version}')" # Ensure we have npm and that the version matches -NODE_PATH=%{buildroot}%{_prefix}/lib/node_modules:%{buildroot}%{_prefix}/lib/node_modules/npm/node_modules %{buildroot}/%{_bindir}/node -e "require(\"assert\").equal(require(\"npm\").version, '%{npm_version}')" +NODE_PATH=%{buildroot}%{_prefix}/lib/node_modules:%{buildroot}%{_prefix}/lib/node_modules/npm/node_modules LD_LIBRARY_PATH=%{buildroot}%{_libdir} %{buildroot}/%{_bindir}/node -e "require(\"assert\").equal(require(\"npm\").version, '%{npm_version}')" %pretrans -n npm -p @@ -430,6 +443,7 @@ end %files %{_bindir}/node +%{_libdir}/libnode.so.%{nodejs_soversion} %dir %{_prefix}/lib/node_modules %dir %{_datadir}/node %dir %{_datadir}/systemtap @@ -453,6 +467,7 @@ end %files devel %{_includedir}/node +%{_libdir}/libnode.so %{_datadir}/node/common.gypi %{_pkgdocdir}/gdbinit @@ -480,6 +495,7 @@ end %changelog * Thu Mar 14 2019 Elliott Sales de Andrade - 1:10.15.2-2 - Drop debug executable +- Build with a shared library * Fri Mar 01 2019 Stephen Gallagher - 1:10.15.2-1 - Update to 10.15.2 From d3df05b0b2224ba3a2a5aee2b4f3e1dce85951a0 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Wed, 20 Mar 2019 04:54:52 +0000 Subject: [PATCH 07/10] Add v8 compatibility subpackage. --- nodejs.spec | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 51 insertions(+), 1 deletion(-) diff --git a/nodejs.spec b/nodejs.spec index b80f0fa..3a0e62c 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -157,6 +157,22 @@ BuildRequires: openssl-devel # we need the system certificate store Requires: ca-certificates +# Compatibility for obsolete v8 package +%ifarch %{ix86} x86_64 %{arm} +%ifarch x86_64 +Provides: libv8.so.%{v8_major}()(64bit) +Provides: libv8_libbase.so.%{v8_major}()(64bit) +Provides: libv8_libplatform.so.%{v8_major}()(64bit) +%else +Provides: libv8.so.%{v8_major} +Provides: libv8_libbase.so.%{v8_major} +Provides: libv8_libplatform.so.%{v8_major} +%endif +Provides: v8 = %{epoch}:%{v8_version}-%{nodejs_release}%{?dist} +Provides: v8%{?_isa} = %{epoch}:%{v8_version}-%{nodejs_release}%{?dist} +Obsoletes: v8 < 1:6.7.17-10 +%endif + #we need ABI virtual provides where SONAMEs aren't enough/not present so deps #break when binary compatibility is broken Provides: nodejs(abi) = %{nodejs_abi} @@ -237,6 +253,14 @@ Requires: libuv-devel%{?_isa} %description devel Development headers for the Node.js JavaScript runtime. +%package -n v8-devel +Summary: v8 - development headers +Version: %{v8_version} +Requires: %{name}-devel%{?_isa} = %{epoch}:%{nodejs_version}-%{nodejs_release}%{?dist} + +%description -n v8-devel +Development headers for the v8 runtime. + %package -n npm Summary: Node.js Package Manager Epoch: %{npm_epoch} @@ -352,6 +376,18 @@ chrpath --delete %{buildroot}%{_bindir}/node # Install library symlink ln -s %{_libdir}/libnode.so.%{nodejs_soversion} %{buildroot}%{_libdir}/libnode.so +# Install v8 compatibility symlinks +for header in %{buildroot}%{_includedir}/node/libplatform %{buildroot}%{_includedir}/node/v8*.h; do + header=$(basename ${header}) + ln -s %{_includedir}/node/${header} %{buildroot}%{_includedir}/${header} +done +for soname in libv8 libv8_libbase libv8_libplatform; do + ln -s %{_libdir}/libnode.so.%{nodejs_soversion} %{buildroot}%{_libdir}/${soname}.so +%ifarch %{ix86} x86_64 %{arm} + ln -s %{_libdir}/libnode.so.%{nodejs_soversion} %{buildroot}%{_libdir}/${soname}.so.%{v8_major} +%endif +done + # own the sitelib directory mkdir -p %{buildroot}%{_prefix}/lib/node_modules @@ -444,6 +480,11 @@ end %files %{_bindir}/node %{_libdir}/libnode.so.%{nodejs_soversion} +%ifarch %{ix86} x86_64 %{arm} +%{_libdir}/libv8.so.%{v8_major} +%{_libdir}/libv8_libbase.so.%{v8_major} +%{_libdir}/libv8_libplatform.so.%{v8_major} +%endif %dir %{_prefix}/lib/node_modules %dir %{_datadir}/node %dir %{_datadir}/systemtap @@ -472,6 +513,14 @@ end %{_pkgdocdir}/gdbinit +%files -n v8-devel +%{_includedir}/libplatform +%{_includedir}/v8*.h +%{_libdir}/libv8.so +%{_libdir}/libv8_libbase.so +%{_libdir}/libv8_libplatform.so + + %files -n npm %{_bindir}/npm %{_bindir}/npx @@ -493,9 +542,10 @@ end %{_pkgdocdir}/npm/doc %changelog -* Thu Mar 14 2019 Elliott Sales de Andrade - 1:10.15.2-2 +* Sun Mar 17 2019 Elliott Sales de Andrade - 1:10.15.2-2 - Drop debug executable - Build with a shared library +- Add v8 compatibility subpackage * Fri Mar 01 2019 Stephen Gallagher - 1:10.15.2-1 - Update to 10.15.2 From c29f89eb9a8997c8e167316c9c835355622f9377 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 9 Apr 2019 10:40:26 -0400 Subject: [PATCH 08/10] Split libnode into a nodejs-libs subpackage Clean up provides and epoch Signed-off-by: Stephen Gallagher --- nodejs.spec | 63 +++++++++++++++++++++++++++++++++-------------------- 1 file changed, 39 insertions(+), 24 deletions(-) diff --git a/nodejs.spec b/nodejs.spec index 3a0e62c..f42933a 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -17,10 +17,12 @@ %global nodejs_abi %{nodejs_major}.%{nodejs_minor} %global nodejs_soversion 64 %global nodejs_version %{nodejs_major}.%{nodejs_minor}.%{nodejs_patch} -%global nodejs_release 2 +%global nodejs_release 3 # == Bundled Dependency Versions == # v8 - from deps/v8/include/v8-version.h +# Epoch is set to ensure clean upgrades from the old v8 package +%global v8_epoch 1 %global v8_major 6 %global v8_minor 8 %global v8_build 275 @@ -157,21 +159,8 @@ BuildRequires: openssl-devel # we need the system certificate store Requires: ca-certificates -# Compatibility for obsolete v8 package -%ifarch %{ix86} x86_64 %{arm} -%ifarch x86_64 -Provides: libv8.so.%{v8_major}()(64bit) -Provides: libv8_libbase.so.%{v8_major}()(64bit) -Provides: libv8_libplatform.so.%{v8_major}()(64bit) -%else -Provides: libv8.so.%{v8_major} -Provides: libv8_libbase.so.%{v8_major} -Provides: libv8_libplatform.so.%{v8_major} -%endif -Provides: v8 = %{epoch}:%{v8_version}-%{nodejs_release}%{?dist} -Provides: v8%{?_isa} = %{epoch}:%{v8_version}-%{nodejs_release}%{?dist} -Obsoletes: v8 < 1:6.7.17-10 -%endif +Requires: nodejs-libs%{?_isa} = %{epoch}:%{nodejs_version}-%{nodejs_release}%{?dist} + #we need ABI virtual provides where SONAMEs aren't enough/not present so deps #break when binary compatibility is broken @@ -253,8 +242,30 @@ Requires: libuv-devel%{?_isa} %description devel Development headers for the Node.js JavaScript runtime. +%package libs +Summary: Node.js and v8 libraries + +# Compatibility for obsolete v8 package +%if 0%{?__isa_bits} == 64 +Provides: libv8.so.%{v8_major}()(64bit) +Provides: libv8_libbase.so.%{v8_major}()(64bit) +Provides: libv8_libplatform.so.%{v8_major}()(64bit) +%else # 32-bits +Provides: libv8.so.%{v8_major} +Provides: libv8_libbase.so.%{v8_major} +Provides: libv8_libplatform.so.%{v8_major} +%endif + +Provides: v8 = %{v8_epoch}:%{v8_version}-%{nodejs_release}%{?dist} +Provides: v8%{?_isa} = %{v8_epoch}:%{v8_version}-%{nodejs_release}%{?dist} +Obsoletes: v8 < 1:6.7.17-10 + +%description libs +Libraries to support Node.js and provide stable v8 interfaces. + %package -n v8-devel Summary: v8 - development headers +Epoch: %{v8_epoch} Version: %{v8_version} Requires: %{name}-devel%{?_isa} = %{epoch}:%{nodejs_version}-%{nodejs_release}%{?dist} @@ -383,9 +394,7 @@ for header in %{buildroot}%{_includedir}/node/libplatform %{buildroot}%{_include done for soname in libv8 libv8_libbase libv8_libplatform; do ln -s %{_libdir}/libnode.so.%{nodejs_soversion} %{buildroot}%{_libdir}/${soname}.so -%ifarch %{ix86} x86_64 %{arm} ln -s %{_libdir}/libnode.so.%{nodejs_soversion} %{buildroot}%{_libdir}/${soname}.so.%{v8_major} -%endif done # own the sitelib directory @@ -479,12 +488,6 @@ end %files %{_bindir}/node -%{_libdir}/libnode.so.%{nodejs_soversion} -%ifarch %{ix86} x86_64 %{arm} -%{_libdir}/libv8.so.%{v8_major} -%{_libdir}/libv8_libbase.so.%{v8_major} -%{_libdir}/libv8_libplatform.so.%{v8_major} -%endif %dir %{_prefix}/lib/node_modules %dir %{_datadir}/node %dir %{_datadir}/systemtap @@ -513,6 +516,13 @@ end %{_pkgdocdir}/gdbinit +%files libs +%{_libdir}/libnode.so.%{nodejs_soversion} +%{_libdir}/libv8.so.%{v8_major} +%{_libdir}/libv8_libbase.so.%{v8_major} +%{_libdir}/libv8_libplatform.so.%{v8_major} + + %files -n v8-devel %{_includedir}/libplatform %{_includedir}/v8*.h @@ -542,6 +552,11 @@ end %{_pkgdocdir}/npm/doc %changelog +* Tue Apr 09 2019 Stephen Gallagher - 1:10.15.2-3 +- Separate nodejs-libs out to its own subpackage +- Clean up compatibility virtual Provides +- Set epoch for v8-devel to maintain upgrade path + * Sun Mar 17 2019 Elliott Sales de Andrade - 1:10.15.2-2 - Drop debug executable - Build with a shared library From b8917d838d8629286107553226d3286d3012beb8 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 9 Apr 2019 20:38:40 -0400 Subject: [PATCH 09/10] Update to 10.15.3 https://nodejs.org/en/blog/release/v10.15.3/ Signed-off-by: Stephen Gallagher --- nodejs.spec | 8 ++++++-- sources | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/nodejs.spec b/nodejs.spec index f42933a..9701af7 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -13,11 +13,11 @@ %global nodejs_epoch 1 %global nodejs_major 10 %global nodejs_minor 15 -%global nodejs_patch 2 +%global nodejs_patch 3 %global nodejs_abi %{nodejs_major}.%{nodejs_minor} %global nodejs_soversion 64 %global nodejs_version %{nodejs_major}.%{nodejs_minor}.%{nodejs_patch} -%global nodejs_release 3 +%global nodejs_release 1 # == Bundled Dependency Versions == # v8 - from deps/v8/include/v8-version.h @@ -552,6 +552,10 @@ end %{_pkgdocdir}/npm/doc %changelog +* Tue Apr 09 2019 Stephen Gallagher - 1:10.15.3-1 +- Update to 10.15.3 +- https://nodejs.org/en/blog/release/v10.15.3/ + * Tue Apr 09 2019 Stephen Gallagher - 1:10.15.2-3 - Separate nodejs-libs out to its own subpackage - Clean up compatibility virtual Provides diff --git a/sources b/sources index 23724af..fd84937 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (node-v10.15.2-stripped.tar.gz) = f7971cbeb94bc7079bca090546b30608f333a95b3e82c7fccd581a84ebc21496fd5ee595ce66abce0fdf484d6a2f9d818a2d7110833adec8daa73b885108a19f +SHA512 (node-v10.15.3-stripped.tar.gz) = 1f7f38e59cfe370855022f9333a89ecfd99152ec901d1cd600c3915fff310b021f7f75dfde8949350edb6af0ab9f191e665b5829d820c29229b7a8dcd0d966df From 1fa28cdbc461114b4cf649cf81bd0ba5f6c896aa Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 9 Apr 2019 21:23:05 -0400 Subject: [PATCH 10/10] Rebase patches for 10.15.3 Signed-off-by: Stephen Gallagher --- 0001-Disable-running-gyp-on-shared-deps.patch | 6 +-- ...ess-NPM-message-to-run-global-update.patch | 4 +- ...Install-both-binaries-and-use-libdir.patch | 43 ++++++++++++------- nodejs.spec | 7 +-- 4 files changed, 34 insertions(+), 26 deletions(-) rename 0001-Install-both-binaries-and-use-libdir.patch => 0003-Install-both-binaries-and-use-libdir.patch (73%) diff --git a/0001-Disable-running-gyp-on-shared-deps.patch b/0001-Disable-running-gyp-on-shared-deps.patch index 9eaaca4..ba4c437 100644 --- a/0001-Disable-running-gyp-on-shared-deps.patch +++ b/0001-Disable-running-gyp-on-shared-deps.patch @@ -1,4 +1,4 @@ -From 443fef828092b315a207a194f5fe74e52e451996 Mon Sep 17 00:00:00 2001 +From 223cfda05cf681b8dfe6f24fbb7d5360d1bfdeee Mon Sep 17 00:00:00 2001 From: Zuzana Svetlikova Date: Thu, 27 Apr 2017 14:25:42 +0200 Subject: [PATCH 1/3] Disable running gyp on shared deps @@ -8,7 +8,7 @@ Subject: [PATCH 1/3] Disable running gyp on shared deps 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile -index 3a343301d640bc7fd41e9680c74455bb260a950d..d2b9c13ee3e53d957ed32476e40fb09e41fcfded 100644 +index 4e7263924cf19ac3a3a3670d28d835b21820fd6c..78ffc37bf1a39ad8f8a430a507a2fbffb9029a20 100644 --- a/Makefile +++ b/Makefile @@ -121,14 +121,13 @@ with-code-cache: @@ -30,5 +30,5 @@ index 3a343301d640bc7fd41e9680c74455bb260a950d..d2b9c13ee3e53d957ed32476e40fb09e @if [ -x config.status ]; then \ ./config.status; \ -- -2.20.1 +2.21.0 diff --git a/0002-Suppress-NPM-message-to-run-global-update.patch b/0002-Suppress-NPM-message-to-run-global-update.patch index ceb2723..fed3000 100644 --- a/0002-Suppress-NPM-message-to-run-global-update.patch +++ b/0002-Suppress-NPM-message-to-run-global-update.patch @@ -1,4 +1,4 @@ -From 0fd4649d1943f45cb06bda6febdc7ffa7d5859b2 Mon Sep 17 00:00:00 2001 +From 945b762887c65c2c70024de259e27db8a0a31859 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 1 May 2018 08:05:30 -0400 Subject: [PATCH 2/3] Suppress NPM message to run global update @@ -83,5 +83,5 @@ index 6f76b23828531e7af98a7e3cd7d5abfaac09b40c..98edb6f45fe073e03794a2ae6e7aa7f5 !err && npm.config.get('ham-it-up') && -- -2.20.1 +2.21.0 diff --git a/0001-Install-both-binaries-and-use-libdir.patch b/0003-Install-both-binaries-and-use-libdir.patch similarity index 73% rename from 0001-Install-both-binaries-and-use-libdir.patch rename to 0003-Install-both-binaries-and-use-libdir.patch index 23dcb31..7b92718 100644 --- a/0001-Install-both-binaries-and-use-libdir.patch +++ b/0003-Install-both-binaries-and-use-libdir.patch @@ -1,7 +1,7 @@ -From c38964d69ebb93e2273eca4bdcc4370fa26926f8 Mon Sep 17 00:00:00 2001 +From ec52fb7c987b3fe68560ae878b4b0f522f01f8a5 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Tue, 19 Mar 2019 23:22:40 -0400 -Subject: [PATCH] Install both binaries and use libdir. +Subject: [PATCH 3/3] Install both binaries and use libdir. This allows us to build with a shared library for other users while still providing the normal executable. @@ -9,14 +9,16 @@ still providing the normal executable. Signed-off-by: Elliott Sales de Andrade --- configure.py | 7 +++++++ - tools/install.py | 31 ++++++++++++++----------------- - 2 files changed, 21 insertions(+), 17 deletions(-) + tools/install.py | 29 +++++++++++++---------------- + 2 files changed, 20 insertions(+), 16 deletions(-) diff --git a/configure.py b/configure.py -index b62be2302c..0924fa96dc 100755 +index 0ad986ab82e29fdc436794b7f24e49afe1239dca..a58420fc618fe9ad79dcdc27bb6758f34ffaa481 100755 --- a/configure.py +++ b/configure.py -@@ -552,6 +552,12 @@ parser.add_option('--shared', +@@ -550,10 +550,16 @@ parser.add_option('--shared', + action='store_true', + dest='shared', help='compile shared library for embedding node in another project. ' + '(This mode is not officially supported for regular applications)') @@ -29,7 +31,11 @@ index b62be2302c..0924fa96dc 100755 parser.add_option('--without-v8-platform', action='store_true', dest='without_v8_platform', -@@ -1094,6 +1100,7 @@ def configure_node(o): + default=False, + help='do not initialize v8 platform during node.js startup. ' + +@@ -1093,10 +1099,11 @@ def configure_node(o): + + o['variables']['node_no_browser_globals'] = b(options.no_browser_globals) if options.code_cache_path: o['variables']['node_code_cache_path'] = options.code_cache_path o['variables']['node_shared'] = b(options.shared) @@ -37,11 +43,15 @@ index b62be2302c..0924fa96dc 100755 node_module_version = getmoduleversion.get_version() if sys.platform == 'darwin': + shlib_suffix = '%s.dylib' + elif sys.platform.startswith('aix'): diff --git a/tools/install.py b/tools/install.py -index ce9ceeee1d..5ac67b714e 100755 +index 028c32ecbbdf9625238dfcc2baef66df9408b539..bf443c4d15a3b3ebf1e10a5dd802e9c5999691e5 100755 --- a/tools/install.py +++ b/tools/install.py -@@ -116,26 +116,23 @@ def subdir_files(path, dest, action): +@@ -115,30 +115,27 @@ def subdir_files(path, dest, action): + for subdir, files in ret.items(): + action(files, subdir + '/') def files(action): is_windows = sys.platform == 'win32' @@ -64,24 +74,25 @@ index ce9ceeee1d..5ac67b714e 100755 - # in its source - see the _InstallableTargetInstallPath function. - if sys.platform != 'darwin': - output_prefix += 'lib.target/' -- -- if 'false' == variables.get('node_shared'): -- action([output_prefix + output_file], 'bin/' + output_file) -- else: -- action([output_prefix + output_file], 'lib/' + output_file) + output_bin = 'node' + output_lib = 'libnode.' + variables.get('shlib_suffix') + # GYP will output to lib.target except on OS X, this is hardcoded + # in its source - see the _InstallableTargetInstallPath function. + if sys.platform != 'darwin': + output_libprefix += 'lib.target/' -+ + +- if 'false' == variables.get('node_shared'): +- action([output_prefix + output_file], 'bin/' + output_file) +- else: +- action([output_prefix + output_file], 'lib/' + output_file) + action([output_prefix + output_bin], 'bin/' + output_bin) + if 'true' == variables.get('node_shared'): + action([output_libprefix + output_lib], variables.get('libdir') + '/' + output_lib) if 'true' == variables.get('node_use_dtrace'): action(['out/Release/node.d'], 'lib/dtrace/node.d') + + # behave similarly for systemtap -- -2.20.1 +2.21.0 diff --git a/nodejs.spec b/nodejs.spec index 9701af7..39c9304 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -119,12 +119,8 @@ Patch1: 0001-Disable-running-gyp-on-shared-deps.patch # This does bad things on an RPM-managed npm. Patch2: 0002-Suppress-NPM-message-to-run-global-update.patch - -# Upstream patch to fix debug generation on PowerPC -Patch3: 0003-deps-V8-cherry-pick-d0468de.patch - # Patch to install both node and libnode.so, using the correct libdir -Patch5: 0001-Install-both-binaries-and-use-libdir.patch +Patch3: 0003-Install-both-binaries-and-use-libdir.patch BuildRequires: python2-devel BuildRequires: python3-devel @@ -555,6 +551,7 @@ end * Tue Apr 09 2019 Stephen Gallagher - 1:10.15.3-1 - Update to 10.15.3 - https://nodejs.org/en/blog/release/v10.15.3/ +- Drop upstreamed patch * Tue Apr 09 2019 Stephen Gallagher - 1:10.15.2-3 - Separate nodejs-libs out to its own subpackage