From fb2650929269e968be8155d5114e36930d25ff17 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Wed, 24 Apr 2019 08:59:37 -0400 Subject: [PATCH 1/2] Properly replace v8-devel includes with symlinks Signed-off-by: Stephen Gallagher --- nodejs.spec | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/nodejs.spec b/nodejs.spec index 39c9304..de668bb 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -469,7 +469,7 @@ NODE_PATH=%{buildroot}%{_prefix}/lib/node_modules:%{buildroot}%{_prefix}/lib/nod %pretrans -n npm -p -- Remove all of the symlinks from the bundled npm node_modules directory --- This scriptlet can be removed in Fedora 31 +-- Drop this scriptlet when F29 is EOL base_path = "%{_prefix}/lib/node_modules/npm/node_modules/" d_st = posix.stat(base_path) if d_st then @@ -482,6 +482,23 @@ if d_st then end end +%pretrans -n v8-devel -p +-- Replace the v8 libplatform include directory with a symlink +-- Drop this scriptlet when F30 is EOL +path = "%{_includedir}/libplatform" +st = posix.stat(path) +if st and st.type == "directory" then + status = os.rename(path, path .. ".rpmmoved") + if not status then + suffix = 0 + while not status do + suffix = suffix + 1 + status = os.rename(path .. ".rpmmoved", path .. ".rpmmoved." .. suffix) + end + os.rename(path, path .. ".rpmmoved") + end +end + %files %{_bindir}/node %dir %{_prefix}/lib/node_modules @@ -525,6 +542,7 @@ end %{_libdir}/libv8.so %{_libdir}/libv8_libbase.so %{_libdir}/libv8_libplatform.so +%ghost %{_includedir}/libplatform.rpmmoved %files -n npm From ab8672abf9cde5a8152346c285e8365f5039f473 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Wed, 24 Apr 2019 09:02:28 -0400 Subject: [PATCH 2/2] Fix upgrade bug for v8-devel (BZ #1702609) Signed-off-by: Stephen Gallagher --- nodejs.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/nodejs.spec b/nodejs.spec index de668bb..0801aae 100644 --- a/nodejs.spec +++ b/nodejs.spec @@ -17,7 +17,7 @@ %global nodejs_abi %{nodejs_major}.%{nodejs_minor} %global nodejs_soversion 64 %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 @@ -566,6 +566,9 @@ end %{_pkgdocdir}/npm/doc %changelog +* Wed Apr 24 2019 Stephen Gallagher - 1:10.15.3-2 +- Fix upgrade bug for v8-devel (BZ #1702609) + * 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/