0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
Commit Graph

27 Commits

Author SHA1 Message Date
Timothy Gu
0e10717e43
build: runtime-deprecate requiring deps
PR-URL: https://github.com/nodejs/node/pull/16392
Fixes: https://github.com/nodejs/node/pull/15566#discussion_r146111170
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2017-11-13 10:50:12 -08:00
Ben Noordhuis
c30fc8d495 src: support UTF-8 in compiled-in JS source files
Detect it when source files in lib/ are not ASCII.  Decode them as UTF-8
and store them as UTF-16 in the binary so they can be used as external
string resources without non-ASCII characters getting mangled.

Fixes: https://github.com/nodejs/node/issues/10673
PR-URL: https://github.com/nodejs/node/pull/11129
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
2017-02-13 19:16:14 +01:00
Ben Noordhuis
e4290dec2d src,tools: speed up startup by 2.5%
Use zero-copy external string resources for storing the built-in JS
source code.  Saves a few hundred kilobyte of memory and consistently
speeds up `benchmark/misc/startup.js` by 2.5%.

Everything old is new again!  Commit 74954ce ("Add string class that
uses ExternalAsciiStringResource.") from 2011 did the same thing but
I removed that in 2013 in commit 34b0a36 ("src: don't use NewExternal()
with unaligned strings") because of a limitation in the V8 API.

V8 no longer requires that strings are aligned if they are one-byte
strings so it should be safe to re-enable external strings again.

PR-URL: https://github.com/nodejs/node/pull/5458
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Robert Jefe Lindstaedt <robert.lindstaedt@gmail.com>
2016-10-25 13:16:16 +02:00
Sakthipriyan Vairamani
0e2b25034e tools: remove the minifying logic
As the minifier logic is not used at all, this patch removes the code
necessary for it.

PR-URL: https://github.com/nodejs/node/pull/6636
Reviewed-By: Jackson Tian <shvyo1987@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2016-05-12 20:28:45 +05:30
Ben Noordhuis
33e51fe18c src,tools: remove null sentinel from source array
PR-URL: https://github.com/nodejs/node/pull/5418
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
2016-02-25 13:21:56 +01:00
Ben Noordhuis
96adbe9503 src,tools: drop nul byte from built-in source code
PR-URL: https://github.com/nodejs/node/pull/5418
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
2016-02-25 13:21:53 +01:00
Ben Noordhuis
cdc7e025e0 src,tools: allow utf-8 in built-in js source code
PR-URL: https://github.com/nodejs/node/pull/5418
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
2016-02-25 13:21:27 +01:00
Matt Loring
49440b7ea2 tools: add --prof-process flag to node binary
This change cleans up outstanding comments on #3032. It improves error
handling when no isolate file is provided and adds the --prof-process
flag to the node binary which executes the tick processor on the
provided isolate file.

PR-URL: https://github.com/nodejs/node/pull/4021
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Evan Lucas <evanlucas@me.com>
2015-12-08 02:00:46 +01:00
Michael Dawson
2a17c7f65e build: Updates to enable AIX support
These are the core changes that allow AIX to compile.  There
are still some test failures as there are some patches needed for
libuv and npm that we'll need to contribute through those
communities but this set allows node to be built on AIX and
pass most of the core tests

The change in js2c is because AIX does not support $ in
identifier names.  See the discussion/agreement in
https://github.com/nodejs/node/issues/2272

PR-URL: https://github.com/nodejs/node/pull/2364
Reviewed-By: Ben Noordhuis <ben@strongloop.com>
Reviewed-By: Rod Vagg <r@va.gg>
2015-09-15 13:17:28 -04:00
Ben Noordhuis
36f017afaf js2c: fix module id generation on windows
Fix a regression that was introduced in commit 2db758c ("iojs: introduce
internal modules") where the computed id for "config.gypi" on Windows
was not "config" but an empty string.

With an empty string, the build succeeds but the binary is unusable:
startup.processConfig() in src/node.js chokes on the missing .config
property.

PR-URL: https://github.com/iojs/io.js/pull/1281
Reviewed-By: Vladimir Kurchatkin <vladimir.kurchatkin@gmail.com>
2015-03-27 11:10:25 +01:00
Vladimir Kurchatkin
2db758c562 iojs: introduce internal modules
Internal modules can be used to share private code between
public modules without risk to expose private APIs to the
user.

PR-URL: https://github.com/iojs/io.js/pull/848
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-03-25 22:12:18 +03:00
Ben Noordhuis
457d529241 tools: fix js2c macro expansion bug
If the same macro was used twice in close proximity, the second one
didn't get expanded.
2013-07-24 21:49:34 +02:00
Ben Noordhuis
aa3441ae45 js2c: raise proper Exception, not a string
Fixes the following error message:

  TypeError: exceptions must be old-style classes or derived
  from BaseException, not str

Fixes #4303.
2012-11-24 01:14:09 +01:00
Scott Blomquist
f657ce685d windows: add tracing with performance counters
Patch by Henry Rawas and Scott Blomquist.
2012-11-21 01:21:53 +01:00
Ben Noordhuis
c4fa77a5ec tools: fix missing initializer warning in js2c.py
Fix a -Wmissing-field-initializers style compiler warning in the code that's
generated by js2c.py.
2012-08-24 22:56:28 +02:00
Nathan Rajlich
bea2e15864 js2c: fix to support files other than ones ending with 2 char extensions
Previously this was basically hard-coded for *.js files, but now we
need to include the 'config.gypi' file in there as well.
2012-03-15 17:12:37 -07:00
Tom Hughes
74954ce7d8 Add string class that uses ExternalAsciiStringResource.
Change the natives to use this class instead of creating completely new
strings. Reduces memory usage by about 1 MB.
2011-03-08 13:56:41 -08:00
Bert Belder
3c3d1d31c5 Better way of getting rid of symlinks
Windows, especially msysgit, doesn't like 'em
2010-12-20 23:51:21 +01:00
Tom Hughes
446beebd79 Add cmake build support.
Squashed commit of ca128f7dcd28cbcfba154c8577ed54d4aa71dd02 with
contributions from Mark Constable (markc@renta.net) and Daniel Gröber
(darklord@darkboxed.org).
2010-11-22 13:32:49 -08:00
Ryan Dahl
97c9745063 Back to WAF
Too much instability right now. Hopefully we can revisit autoconf soon.
2010-11-01 16:51:20 -07:00
Ryan Dahl
15594eaf87 Replace WAF with make/autoconf 2010-10-24 18:39:36 -07:00
Ryan Dahl
c4636a578c Dynamically load native scripts 2010-10-12 11:49:41 -07:00
Ryan Dahl
4ccdc501d4 Include lib/ directory in node executable. Compile on demand.
Instead of installing the files in /usr/lib/node/libraries and loading them
from the file system, the files are built-in to the node executable.
However, they are only compiled on demand.

The reasoning is:
  1. Allow for more complex internal javascript. In particular,
  process.stdout and process.stdin can be js implemented streams.

  2. Ease system installs. Loading from disk each time is unnecessary
  overhead. Note that there is no "system" path for modules anymore. Only
  $HOME/.node_libraries.
2010-03-15 08:04:35 -07:00
Ryan Dahl
4234ac53e2 Use Google's jsmin.py so that Node can be used for evil 2010-02-08 13:52:13 -08:00
Ryan Dahl
be2ca1ec80 Fix build.
- Add -f flag to rm on make clean.
- Use old jsmin - the new one seems to be broken.
2009-10-07 15:02:42 +02:00
Ryan Dahl
1f31a7dbfe Upgrade v8 to 1.3.14 2009-10-07 11:53:45 +02:00
Ryan
115c4942db Create tools directory
Users will need to "make distclean" to recompile from scratch since I've
moved a lot of the core build tools around.
2009-06-22 13:08:32 +02:00