]> git.pld-linux.org Git - packages/nodejs.git/commitdiff
up to 6.11.5
authorElan Ruusamäe <glen@pld-linux.org>
Thu, 2 Nov 2017 11:36:04 +0000 (13:36 +0200)
committerElan Ruusamäe <glen@pld-linux.org>
Thu, 2 Nov 2017 14:15:51 +0000 (16:15 +0200)
nodejs-lib64path.patch
nodejs-use-system-certs.patch
nodejs.spec

index f5d8d90a7023b410175a6b30a8c746c6caa4a557..8830d513ff37d3eb522d4775007062adb7c9fa15 100644 (file)
@@ -1,13 +1,11 @@
-diff -ur node-v0.9.9-0/lib/module.js node-v0.9.9/lib/module.js
---- node-v0.9.9-0/lib/module.js        2013-02-07 10:11:11.000000000 -0700
-+++ node-v0.9.9/lib/module.js  2013-02-15 21:40:33.000000000 -0700
-@@ -506,7 +506,7 @@
-     var homeDir = process.env.HOME;
+--- node-v6.11.5/lib/module.js~        2017-10-24 22:10:13.000000000 +0300
++++ node-v6.11.5/lib/module.js 2017-11-02 13:32:42.480301417 +0200
+@@ -625,7 +625,7 @@
+   } else {
+     prefixDir = path.resolve(process.execPath, '..', '..');
    }
    }
--  var paths = [path.resolve(process.execPath, '..', '..', 'lib', 'node')];
-+  var paths = ["/usr/lib64/node", "/usr/lib/node", "/usr/lib/node_modules"];
+-  var paths = [path.resolve(prefixDir, 'lib', 'node')];
++  var paths = ["/usr/lib64/node", "/usr/lib/node", "/usr/lib/node_modules", path.resolve(prefixDir, 'lib', 'node')];
  
    if (homeDir) {
      paths.unshift(path.resolve(homeDir, '.node_libraries'));
  
    if (homeDir) {
      paths.unshift(path.resolve(homeDir, '.node_libraries'));
-Only in node-v0.9.9/lib: module.js~
index ea34b0be933ac16ac8d15cc72569b9cc39b85a7c..06262c99f281398b22a8975c3ec1f735d2eec088 100644 (file)
@@ -4,51 +4,48 @@ Forwarded: https://github.com/nodejs/node/issues/3159
 Author: Jérémy Lal <kapouer@melix.org>
 Modified 2014-08-11 by Elan Ruusamäe <glen@delfi.ee> with the correct path for PLD
 Modified 2015-10-17 by Elan Ruusamäe <glen@delfi.ee> updated for node 4.2.1-LTS
 Author: Jérémy Lal <kapouer@melix.org>
 Modified 2014-08-11 by Elan Ruusamäe <glen@delfi.ee> with the correct path for PLD
 Modified 2015-10-17 by Elan Ruusamäe <glen@delfi.ee> updated for node 4.2.1-LTS
---- nodejs-4.5.0/src/node_crypto.cc.orig       2016-08-16 17:09:50.000000000 +0200
-+++ nodejs-4.5.0/src/node_crypto.cc    2016-09-09 23:40:11.959456422 +0200
-@@ -117,7 +117,6 @@
- static uv_mutex_t* locks;
+Modified 2017-11-02 by Elan Ruusamäe <glen@delfi.ee> updated for node 6.11.5-LTS
+--- node-v6.11.5/src/node_crypto.cc~   2017-10-24 22:10:14.000000000 +0300
++++ node-v6.11.5/src/node_crypto.cc    2017-11-02 13:38:45.435760247 +0200
+@@ -121,8 +121,6 @@
+ static Mutex* mutexes;
  
  
- const char* const root_certs[] = {
static const char* const root_certs[] = {
 -#include "node_root_certs.h"  // NOLINT(build/include_order)
 -#include "node_root_certs.h"  // NOLINT(build/include_order)
- };
+-};
  
  
- X509_STORE* root_cert_store;
-@@ -754,29 +753,18 @@
-   CHECK_EQ(sc->ca_store_, nullptr);
+ static std::string extra_root_certs_file;  // NOLINT(runtime/string)
+@@ -850,24 +848,18 @@
+   (void) &clear_error_on_return;  // Silence compiler warning.
  
    if (!root_cert_store) {
  
    if (!root_cert_store) {
--    root_cert_store = X509_STORE_new();
--
--    for (size_t i = 0; i < arraysize(root_certs); i++) {
--      BIO* bp = NodeBIO::NewFixed(root_certs[i], strlen(root_certs[i]));
--      if (bp == nullptr) {
--        return;
--      }
+-    root_cert_store = NewRootCertStore();
 -
 -
--      X509 *x509 = PEM_read_bio_X509(bp, nullptr, CryptoPemCallback, nullptr);
--      if (x509 == nullptr) {
--        BIO_free_all(bp);
--        return;
+-    if (!extra_root_certs_file.empty()) {
+-      unsigned long err = AddCertsFromFile(  // NOLINT(runtime/int)
+-                                           root_cert_store,
+-                                           extra_root_certs_file.c_str());
+-      if (err) {
+-        ProcessEmitWarning(sc->env(),
+-                           "Ignoring extra certs from `%s`, load failed: %s\n",
+-                           extra_root_certs_file.c_str(),
+-                           ERR_error_string(err, nullptr));
 -      }
 -      }
--
--      X509_STORE_add_cert(root_cert_store, x509);
--
--      BIO_free_all(bp);
--      X509_free(x509);
-+    if (SSL_CTX_load_verify_locations(sc->ctx_, "/etc/certs/ca-certificates.crt", NULL) == 1) {
-+      root_cert_store = SSL_CTX_get_cert_store(sc->ctx_);
-+    } else {
-+      // new empty store
-+      root_cert_store = X509_STORE_new();
-     }
-+  } else {
-+    SSL_CTX_set_cert_store(sc->ctx_, root_cert_store);
+-    }
++     if (SSL_CTX_load_verify_locations(sc->ctx_, "/etc/certs/ca-certificates.crt", NULL) == 1) {
++       root_cert_store = SSL_CTX_get_cert_store(sc->ctx_);
++     } else {
++       // new empty store
++       root_cert_store = NewRootCertStore();
++     }
++   } else {
++     SSL_CTX_set_cert_store(sc->ctx_, root_cert_store);
    }
  
    }
  
-+
-   sc->ca_store_ = root_cert_store;
--  SSL_CTX_set_cert_store(sc->ctx_, sc->ca_store_);
+   // Increment reference count so global store is not deleted along with CTX.
+   X509_STORE_up_ref(root_cert_store);
+-  SSL_CTX_set_cert_store(sc->ctx_, root_cert_store);
  }
  
  
  }
  
  
index d61f710e88d72d1a07cc7cd8f8b9442ed4cf24af..db65ba5a5e807be0d77cd45aa587d80619a88859 100644 (file)
 Summary:       Asynchronous JavaScript Engine
 Summary(pl.UTF-8):     Asynchroniczny silnik JavaScriptu
 Name:          nodejs
 Summary:       Asynchronous JavaScript Engine
 Summary(pl.UTF-8):     Asynchroniczny silnik JavaScriptu
 Name:          nodejs
-# 6.9 is LTS, Active LTS: 2018-04-18, EOL: 2019-04-18
-# https://github.com/nodejs/LTS
-Version:       6.9.4
-Release:       1
+# 6.x LTS - https://github.com/nodejs/LTS:
+# Active start: 2016-10-18
+# Maintenance start: April 2018
+# Maintenance end: April 2019
+Version:       6.11.5
+Release:       0.1
 License:       BSD and MIT and Apache v2.0 and GPL v3
 Group:         Development/Languages
 Source0:       https://nodejs.org/dist/v%{version}/node-v%{version}.tar.gz
 License:       BSD and MIT and Apache v2.0 and GPL v3
 Group:         Development/Languages
 Source0:       https://nodejs.org/dist/v%{version}/node-v%{version}.tar.gz
-# Source0-md5: 3795199b5950b25179248847b1a5fc86
+# Source0-md5: 7a3159a3245a45ff6e6f546ffdfa1160
 Patch1:                %{name}-shared.patch
 # force node to use /usr/lib/node as the systemwide module directory
 Patch2:                %{name}-libpath.patch
 Patch1:                %{name}-shared.patch
 # force node to use /usr/lib/node as the systemwide module directory
 Patch2:                %{name}-libpath.patch
@@ -138,8 +140,8 @@ Sondy systemtap/dtrace dla Node.js.
 %else
 %patch2 -p1
 %endif
 %else
 %patch2 -p1
 %endif
-%patch4 -p1
-%{__rm} src/node_root_certs.h
+#%patch4 -p1
+#%{__rm} src/node_root_certs.h
 #%{?with_system_uv:%patch5 -p1}
 
 grep -r '#!.*env python' -l . | xargs %{__sed} -i -e '1 s,#!.*env python,#!%{__python},'
 #%{?with_system_uv:%patch5 -p1}
 
 grep -r '#!.*env python' -l . | xargs %{__sed} -i -e '1 s,#!.*env python,#!%{__python},'
@@ -236,7 +238,7 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
 
 %files
 %defattr(644,root,root,755)
-%doc README.md AUTHORS CHANGELOG.md ROADMAP.md LICENSE
+%doc README.md AUTHORS CHANGELOG.md LICENSE
 %attr(755,root,root) %{_bindir}/node
 %attr(755,root,root) %{_bindir}/nodejs
 %if %{with shared}
 %attr(755,root,root) %{_bindir}/node
 %attr(755,root,root) %{_bindir}/nodejs
 %if %{with shared}
This page took 0.090637 seconds and 4 git commands to generate.