Files
nodejs10/nodejs-sle11-python26-check_output.patch
Adam Majer 20a701d2db - New upstream release 10.1.0:
* console: make console.table() use colored inspect
  * fs: move fs/promises to fs.promises
  * http: added aborted property to request
  * n-api: initialize a module via a special symbol
  * src: add public API to expose the main V8 Platform
- Changes in version 10.0.0:
  * Assert:
    + Calling assert.fail() with more than one argument is deprecated.
    + Calling assert.ok() with no arguments will now throw.
    + Calling assert.ifError() will now throw with any argument
      other than undefined or null. Previously the method would throw
      with any truthy value.
  * Async_hooks:
    + Older experimental async_hooks APIs have been removed.
  * Buffer:
    + Uses of new Buffer() and Buffer() outside of the node_modules
      directory will now emit a runtime deprecation warning.
    + Buffer.isEncoding() now returns undefined for falsy values,
      including an empty string.
    + Buffer.fill() will throw if an attempt is made to fill with
      an empty Buffer.
  * Child Process: Undefined properties of env are ignored.
  * console: console.table() method has been added.
  * crypto:
    + The crypto.createCipher() and crypto.createDecipher() methods
      have been deprecated. Please use crypto.createCipheriv() and
      crypto.createDecipheriv() instead.
    + The decipher.finaltol() method has been deprecated.
    + The crypto.DEFAULT_ENCODING property has been deprecated.
    + The ECDH.convertKey() method has been added.
    + The crypto.fips property has been deprecated.
  * deps:
    + V8 has been updated to 6.6
    + npm upgraded to 5.8.0
  * EventEmitter:
    + The EventEmitter.prototype.off() method has been added as
      an alias for EventEmitter.prototype.removeListener().
  * File System:
    + The fs/promises API provides experimental promisified
      versions of the fs functions.
    + Invalid path errors are now thrown synchronously.
    + fs.readFile() method now partitions reads to avoid thread
      pool exhaustion.
  * http:
    + Processing of HTTP Status codes 100, 102-199 has been improved.
    + Multi-byte characters in URL paths are now forbidden.
  * N-API: The n-api is no longer experimental.
  * net: The 'close' event will be emitted after 'end'.
  * perf_hooks:
    + The PerformanceObserver class is now an AsyncResource and can
      be monitored using async_hooks.
    + Trace events are now emitted for performance events.
    + The performance API has been simplified.
    + Performance milestone marks will be emitted as trace events.
  * process:
    + Using non-string values for process.env is deprecated.
    + The process.assert() method is deprecated.
  * repl:
    + REPL now experimentally supports top-level await when using
      the --experimental-repl-await flag.
    + The previously deprecated "magic mode" has been removed.
    + The previously deprecated NODE_REPL_HISTORY_FILE environment
      variable has been removed.
    + Proxy objects are shown as Proxy objects when inspected.
  * streams:
    + The 'readable' event is now always deferred with nextTick.
    + A new pipeline() method has been provided for building
      end-to-data stream pipelines.
    + support for async for-await has been added to stream.Readable
  * timers: The enroll() and unenroll() methods have been deprecated
  * tls:
    + The tls.convertNPNProtocols() method has been deprecated.
    + Support for NPN (next protocol negotiation) has been dropped.
    + The ecdhCurve default is now 'auto'.
  * Trace Events:
    + A new trace_events top-level module allows trace event
      categories to be enabled/disabled at runtime.
  * URL: The WHATWG URL API is now a global.
  * Util:
    + util.types.is[…] type checks have been added.
    + Support for bigint formatting has been added to util.inspect().

OBS-URL: https://build.opensuse.org/package/show/devel:languages:nodejs/nodejs10?expand=0&rev=1
2018-05-11 14:21:06 +00:00

34 lines
1.3 KiB
Diff

Index: node-v9.3.0/configure
===================================================================
--- node-v9.3.0.orig/configure
+++ node-v9.3.0/configure
@@ -38,6 +38,28 @@ import string
# If not run from node/, cd to node/.
os.chdir(os.path.dirname(__file__) or '.')
+# http://stackoverflow.com/questions/28904750/python-check-output-workaround-in-2-6
+if "check_output" not in dir( subprocess ): # duck punch it in!
+ def check_output(*popenargs, **kwargs):
+ r"""Run command with arguments and return its output as a byte string.
+ Backported from Python 2.7 as it's implemented as pure python on stdlib.
+
+ >>> check_output(['/usr/bin/python', '--version'])
+ Python 2.6.2+ """
+ process = subprocess.Popen(stdout=subprocess.PIPE, *popenargs, **kwargs)
+ output, unused_err = process.communicate()
+ retcode = process.poll()
+ if retcode:
+ cmd = kwargs.get("args")
+ if cmd is None:
+ cmd = popenargs[0]
+ error = subprocess.CalledProcessError(retcode, cmd)
+ error.output = output
+ raise error
+ return output
+
+ subprocess.check_output = check_output
+
# gcc and g++ as defaults matches what GYP's Makefile generator does,
# except on OS X.
CC = os.environ.get('CC', 'cc' if sys.platform == 'darwin' else 'gcc')