Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: nodejs/node-gyp
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v9.2.0
Choose a base ref
...
head repository: nodejs/node-gyp
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v9.3.0
Choose a head ref
  • 4 commits
  • 17 files changed
  • 3 contributors

Commits on Oct 8, 2022

  1. Copy the full SHA
    7d0c83d View commit details
  2. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    131d1a4 View commit details

Commits on Oct 10, 2022

  1. Copy the full SHA
    713b8dc View commit details

Commits on Oct 11, 2022

  1. chore: release 9.3.0

    github-actions[bot] authored and rvagg committed Oct 11, 2022
    Copy the full SHA
    2cc72be View commit details
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# Changelog

## [9.3.0](https://www.github.com/nodejs/node-gyp/compare/v9.2.0...v9.3.0) (2022-10-10)


### Features

* **gyp:** update gyp to v0.14.0 ([#2749](https://www.github.com/nodejs/node-gyp/issues/2749)) ([713b8dc](https://www.github.com/nodejs/node-gyp/commit/713b8dcdbf44532ca9453a127da266386cc737f8))
* remove support for VS2015 in Node.js >=19 ([#2746](https://www.github.com/nodejs/node-gyp/issues/2746)) ([131d1a4](https://www.github.com/nodejs/node-gyp/commit/131d1a463baf034a04154bcda753a8295f112a34))
* support IBM Open XL C/C++ on z/OS ([#2743](https://www.github.com/nodejs/node-gyp/issues/2743)) ([7d0c83d](https://www.github.com/nodejs/node-gyp/commit/7d0c83d2a95aca743dff972826d0da26203acfc4))

## [9.2.0](https://www.github.com/nodejs/node-gyp/compare/v9.1.0...v9.2.0) (2022-10-02)


38 changes: 26 additions & 12 deletions addon.gypi
Original file line number Diff line number Diff line change
@@ -109,21 +109,35 @@
],
}],
[ 'OS=="zos"', {
'cflags': [
'-q64',
'-Wc,DLL',
'-qlonglong',
'-qenum=int',
'-qxclang=-fexec-charset=ISO8859-1'
'conditions': [
[ '"<!(echo $CC)" != "clang" and \
"<!(echo $CC)" != "ibm-clang64" and \
"<!(echo $CC)" != "ibm-clang"', {
'cflags': [
'-q64',
'-Wc,DLL',
'-qlonglong',
'-qenum=int',
'-qxclang=-fexec-charset=ISO8859-1'
],
'ldflags': [
'-q64',
'<(node_exp_file)',
],
}, {
'cflags': [
'-m64',
],
'ldflags': [
'-m64',
'<(node_exp_file)',
],
}],
],
'defines': [
'_ALL_SOURCE=1',
'_ALL_SOURCE',
'MAP_FAILED=-1',
'_UNIX03_SOURCE=1'
],
'ldflags': [
'-q64',
'<(node_exp_file)'
'_UNIX03_SOURCE',
],
}],
[ 'OS=="win"', {
16 changes: 11 additions & 5 deletions gyp/.github/workflows/Python_tests.yml
Original file line number Diff line number Diff line change
@@ -2,7 +2,12 @@
# TODO: Enable pytest --doctest-modules

name: Python_tests
on: [push, pull_request]
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:
jobs:
Python_tests:
runs-on: ${{ matrix.os }}
@@ -11,17 +16,18 @@ jobs:
max-parallel: 8
matrix:
os: [macos-latest, ubuntu-latest] # , windows-latest]
python-version: ["3.7", "3.8", "3.9", "3.10"]
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11-dev"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements_dev.txt
python -m pip install --upgrade pip setuptools
pip install --editable ".[dev]"
- run: ./gyp -V && ./gyp --version && gyp -V && gyp --version
- name: Lint with flake8
run: flake8 . --ignore=E203,W503 --max-complexity=101 --max-line-length=88 --show-source --statistics
- name: Test with pytest
13 changes: 8 additions & 5 deletions gyp/.github/workflows/node-gyp.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
name: node-gyp integration

on: [push, pull_request]

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:
jobs:
test:
integration:
strategy:
fail-fast: false
matrix:
@@ -24,7 +27,7 @@ jobs:
- uses: actions/setup-node@v3
with:
node-version: 14.x
- uses: actions/setup-python@v3
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Install dependencies
9 changes: 7 additions & 2 deletions gyp/.github/workflows/nodejs-windows.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
name: Node.js Windows integration

on: [push, pull_request]
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:

jobs:
build-windows:
runs-on: windows-latest
runs-on: windows-2019
steps:
- name: Clone gyp-next
uses: actions/checkout@v3
4 changes: 2 additions & 2 deletions gyp/.github/workflows/release-please.yml
Original file line number Diff line number Diff line change
@@ -8,9 +8,9 @@ jobs:
release-please:
runs-on: ubuntu-latest
steps:
- uses: GoogleCloudPlatform/release-please-action@v2
- uses: google-github-actions/release-please-action@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
release-type: python
package-name: gyp-next
bump-minor-pre-major: Yes
bump-minor-pre-major: true
16 changes: 16 additions & 0 deletions gyp/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
# Changelog

## [0.14.0](https://github.com/nodejs/gyp-next/compare/v0.13.0...v0.14.0) (2022-10-08)


### Features

* Add command line argument for `gyp --version` ([#164](https://github.com/nodejs/gyp-next/issues/164)) ([5c9f4d0](https://github.com/nodejs/gyp-next/commit/5c9f4d05678dd855e18ed2327219e5d18e5374db))
* ninja build for iOS ([#174](https://github.com/nodejs/gyp-next/issues/174)) ([b6f2714](https://github.com/nodejs/gyp-next/commit/b6f271424e0033d7ed54d437706695af2ba7a1bf))
* **zos:** support IBM Open XL C/C++ & PL/I compilers on z/OS ([#178](https://github.com/nodejs/gyp-next/issues/178)) ([43a7211](https://github.com/nodejs/gyp-next/commit/43a72110ae3fafb13c9625cc7a969624b27cda47))


### Bug Fixes

* lock windows env ([#163](https://github.com/nodejs/gyp-next/issues/163)) ([44bd0dd](https://github.com/nodejs/gyp-next/commit/44bd0ddc93ea0b5770a44dd326a2e4ae62c21442))
* move configuration information into pyproject.toml ([#176](https://github.com/nodejs/gyp-next/issues/176)) ([d69d8ec](https://github.com/nodejs/gyp-next/commit/d69d8ece6dbff7af4f2ea073c9fd170baf8cb7f7))
* node.js debugger adds stderr (but exit code is 0) -> shouldn't throw ([#179](https://github.com/nodejs/gyp-next/issues/179)) ([1a457d9](https://github.com/nodejs/gyp-next/commit/1a457d9ed08cfd30c9fa551bc5cf0d90fb583787))

## [0.13.0](https://www.github.com/nodejs/gyp-next/compare/v0.12.1...v0.13.0) (2022-05-11)


12 changes: 12 additions & 0 deletions gyp/pylib/gyp/__init__.py
Original file line number Diff line number Diff line change
@@ -15,6 +15,7 @@
import traceback
from gyp.common import GypError


# Default debug modes for GYP
debug = {}

@@ -463,8 +464,19 @@ def gyp_main(args):
metavar="TARGET",
help="include only TARGET and its deep dependencies",
)
parser.add_argument(
"-V",
"--version",
dest="version",
action="store_true",
help="Show the version and exit.",
)

options, build_files_arg = parser.parse_args(args)
if options.version:
import pkg_resources
print(f"v{pkg_resources.get_distribution('gyp-next').version}")
return 0
build_files = build_files_arg

# Set up the configuration directory (defaults to ~/.gyp)
1 change: 1 addition & 0 deletions gyp/pylib/gyp/common.py
Original file line number Diff line number Diff line change
@@ -470,6 +470,7 @@ def CopyTool(flavor, out_path, generator_flags={}):
"os400": "flock",
"solaris": "flock",
"mac": "mac",
"ios": "mac",
"win": "win",
}.get(flavor, None)
if not prefix:
46 changes: 40 additions & 6 deletions gyp/pylib/gyp/generator/make.py
Original file line number Diff line number Diff line change
@@ -101,6 +101,7 @@ def CalculateVariables(default_variables, params):
default_variables.setdefault("SHARED_LIB_SUFFIX", ".a")
elif flavor == "zos":
default_variables.setdefault("SHARED_LIB_SUFFIX", ".x")
COMPILABLE_EXTENSIONS.update({".pli": "pli"})
else:
default_variables.setdefault("SHARED_LIB_SUFFIX", ".so")
default_variables.setdefault("SHARED_LIB_DIR", "$(builddir)/lib.$(TOOLSET)")
@@ -318,7 +319,7 @@ def CalculateGeneratorInputInfo(params):
cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS)
quiet_cmd_solink = SOLINK($(TOOLSET)) $@
cmd_solink = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -Wl,DLL -o $(patsubst %.x,%.so,$@) $(LD_INPUTS) $(LIBS) && if [ -f $(notdir $@) ]; then /bin/cp $(notdir $@) $@; else true; fi
cmd_solink = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS)
quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
cmd_solink_module = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(filter-out FORCE_DO_CMD, $^) $(LIBS)
@@ -378,6 +379,7 @@ def CalculateGeneratorInputInfo(params):
LINK.target ?= %(LINK.target)s
LDFLAGS.target ?= $(LDFLAGS)
AR.target ?= $(AR)
PLI.target ?= %(PLI.target)s
# C++ apps need to be linked with g++.
LINK ?= $(CXX.target)
@@ -391,6 +393,7 @@ def CalculateGeneratorInputInfo(params):
LINK.host ?= %(LINK.host)s
LDFLAGS.host ?= $(LDFLAGS_host)
AR.host ?= %(AR.host)s
PLI.host ?= %(PLI.host)s
# Define a dir function that can handle spaces.
# http://www.gnu.org/software/make/manual/make.html#Syntax-of-Functions
@@ -628,6 +631,15 @@ def WriteRootHeaderSuffixRules(writer):
writer.write("\n")


SHARED_HEADER_OS390_COMMANDS = """
PLIFLAGS.target ?= -qlp=64 -qlimits=extname=31 $(PLIFLAGS)
PLIFLAGS.host ?= -qlp=64 -qlimits=extname=31 $(PLIFLAGS)
quiet_cmd_pli = PLI($(TOOLSET)) $@
cmd_pli = $(PLI.$(TOOLSET)) $(GYP_PLIFLAGS) $(PLIFLAGS.$(TOOLSET)) -c $< && \
if [ -f $(notdir $@) ]; then /bin/cp $(notdir $@) $@; else true; fi
"""

SHARED_HEADER_SUFFIX_RULES_COMMENT1 = """\
# Suffix rules, putting all outputs into $(obj).
"""
@@ -2450,10 +2462,12 @@ def CalculateMakefilePath(build_file, base_name):
"AR.target": GetEnvironFallback(("AR_target", "AR"), "$(AR)"),
"CXX.target": GetEnvironFallback(("CXX_target", "CXX"), "$(CXX)"),
"LINK.target": GetEnvironFallback(("LINK_target", "LINK"), "$(LINK)"),
"PLI.target": GetEnvironFallback(("PLI_target", "PLI"), "pli"),
"CC.host": GetEnvironFallback(("CC_host", "CC"), "gcc"),
"AR.host": GetEnvironFallback(("AR_host", "AR"), "ar"),
"CXX.host": GetEnvironFallback(("CXX_host", "CXX"), "g++"),
"LINK.host": GetEnvironFallback(("LINK_host", "LINK"), "$(CXX.host)"),
"PLI.host": GetEnvironFallback(("PLI_host", "PLI"), "pli"),
}
if flavor == "mac":
flock_command = "./gyp-mac-tool flock"
@@ -2469,16 +2483,36 @@ def CalculateMakefilePath(build_file, base_name):
header_params.update({"link_commands": LINK_COMMANDS_ANDROID})
elif flavor == "zos":
copy_archive_arguments = "-fPR"
makedep_arguments = "-qmakedep=gcc"
CC_target = GetEnvironFallback(("CC_target", "CC"), "njsc")
makedep_arguments = "-MMD"
if CC_target == "clang":
CC_host = GetEnvironFallback(("CC_host", "CC"), "clang")
CXX_target = GetEnvironFallback(("CXX_target", "CXX"), "clang++")
CXX_host = GetEnvironFallback(("CXX_host", "CXX"), "clang++")
elif CC_target == "ibm-clang64":
CC_host = GetEnvironFallback(("CC_host", "CC"), "ibm-clang64")
CXX_target = GetEnvironFallback(("CXX_target", "CXX"), "ibm-clang++64")
CXX_host = GetEnvironFallback(("CXX_host", "CXX"), "ibm-clang++64")
elif CC_target == "ibm-clang":
CC_host = GetEnvironFallback(("CC_host", "CC"), "ibm-clang")
CXX_target = GetEnvironFallback(("CXX_target", "CXX"), "ibm-clang++")
CXX_host = GetEnvironFallback(("CXX_host", "CXX"), "ibm-clang++")
else:
# Node.js versions prior to v18:
makedep_arguments = "-qmakedep=gcc"
CC_host = GetEnvironFallback(("CC_host", "CC"), "njsc")
CXX_target = GetEnvironFallback(("CXX_target", "CXX"), "njsc++")
CXX_host = GetEnvironFallback(("CXX_host", "CXX"), "njsc++")
header_params.update(
{
"copy_archive_args": copy_archive_arguments,
"makedep_args": makedep_arguments,
"link_commands": LINK_COMMANDS_OS390,
"CC.target": GetEnvironFallback(("CC_target", "CC"), "njsc"),
"CXX.target": GetEnvironFallback(("CXX_target", "CXX"), "njsc++"),
"CC.host": GetEnvironFallback(("CC_host", "CC"), "njsc"),
"CXX.host": GetEnvironFallback(("CXX_host", "CXX"), "njsc++"),
"extra_commands": SHARED_HEADER_OS390_COMMANDS,
"CC.target": CC_target,
"CXX.target": CXX_target,
"CC.host": CC_host,
"CXX.host": CXX_host,
}
)
elif flavor == "solaris":
4 changes: 2 additions & 2 deletions gyp/pylib/gyp/generator/ninja.py
Original file line number Diff line number Diff line change
@@ -1583,7 +1583,7 @@ def WriteTarget(self, spec, config_name, config, link_deps, compile_deps):
elif spec["type"] == "static_library":
self.target.binary = self.ComputeOutput(spec)
if (
self.flavor not in ("mac", "openbsd", "netbsd", "win")
self.flavor not in ("ios", "mac", "netbsd", "openbsd", "win")
and not self.is_standalone_static_library
):
self.ninja.build(
@@ -2496,7 +2496,7 @@ def GenerateOutputForConfig(target_list, target_dicts, data, params, config_name
),
)

if flavor != "mac" and flavor != "win":
if flavor not in ("ios", "mac", "win"):
master_ninja.rule(
"alink",
description="AR $out",
2 changes: 1 addition & 1 deletion gyp/pylib/gyp/xcodeproj_file.py
Original file line number Diff line number Diff line change
@@ -2990,7 +2990,7 @@ def AddOrGetProjectReference(self, other_pbxproject):
# Xcode seems to sort this list case-insensitively
self._properties["projectReferences"] = sorted(
self._properties["projectReferences"],
key=lambda x: x["ProjectRef"].Name().lower
key=lambda x: x["ProjectRef"].Name().lower()
)
else:
# The link already exists. Pull out the relevnt data.
41 changes: 41 additions & 0 deletions gyp/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
[build-system]
requires = ["setuptools>=61.0"]
build-backend = "setuptools.build_meta"

[project]
name = "gyp-next"
version = "0.14.0"
authors = [
{ name="Node.js contributors", email="ryzokuken@disroot.org" },
]
description = "A fork of the GYP build system for use in the Node.js projects"
readme = "README.md"
license = { file="LICENSE" }
requires-python = ">=3.6"
classifiers = [
"Development Status :: 3 - Alpha",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Natural Language :: English",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
]

[project.optional-dependencies]
dev = ["flake8", "pytest"]

[project.scripts]
gyp = "gyp:script_main"

[project.urls]
"Homepage" = "https://github.com/nodejs/gyp-next"

[tool.setuptools]
package-dir = {"" = "pylib"}
packages = ["gyp", "gyp.generator"]
2 changes: 0 additions & 2 deletions gyp/requirements_dev.txt

This file was deleted.

Loading