@@ -1697,29 +1697,24 @@ index 655802980a6ea94d1d4ca1dc63c8c8e905fbb83a..ab1a18a215cb7393310324c6dbcacc66
1697
1697
if 'false' == variables.get('node_shared_libuv'):
1698
1698
subdir_files('deps/uv/include', 'include/node/', action)
1699
1699
diff --git a/tools/js2c.py b/tools/js2c.py
1700
- index 1346b2a87046d3472577875c887b3b44a63280ed..752344d68c3f63b4c5e491b33d4576ed48f8b74f 100755
1700
+ index 4594694a2cab0d878d86127a72714ed60c251b6e..9e9883129bed62c591d23f71d139514c5034ac8d 100755
1701
1701
--- a/tools/js2c.py
1702
1702
+++ b/tools/js2c.py
1703
- @@ -261,10 +261,18 @@ def NormalizeFileName(filename):
1704
- split = ['internal'] + split
1705
- else: # `lib/**/*.js` so drop the 'lib' part
1703
+ @@ -130,6 +130,14 @@ def NormalizeFileName(filename):
1706
1704
split = split[1:]
1707
- +
1708
1705
if len(split):
1709
1706
filename = '/'.join(split)
1710
- - return os.path.splitext(filename)[0]
1711
-
1707
+ +
1712
1708
+ # Electron-specific: when driving the node build from Electron, we generate
1713
1709
+ # config.gypi in a separate directory and pass the absolute path to js2c.
1714
1710
+ # This overrides the absolute path so that the variable names in the
1715
1711
+ # generated C are as if it was in the root node directory.
1716
1712
+ if filename.endswith("/config.gypi"):
1717
1713
+ filename = "config.gypi"
1718
1714
+
1719
- + return os.path.splitext(filename)[0]
1715
+ return os.path.splitext(filename)[0]
1716
+
1720
1717
1721
- def JS2C(source_files, target):
1722
- # Process input from all *macro.py files
1723
1718
diff --git a/tools/tar.py b/tools/tar.py
1724
1719
new file mode 100644
1725
1720
index 0000000000000000000000000000000000000000..eb697be25779db62c829aac45a509804e9fff331
0 commit comments