Commit Graph

75 Commits

Author SHA1 Message Date
Fedora Release Engineering
d504fbf5e5 Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild 2024-07-18 19:38:12 +00:00
Yaakov Selkowitz
4299cf9076 Fix build with rpm 4.20
rpm 4.20 now uses a build-specific %_builddir (previously %_topdir/BUILD),
but this directory change occurs by default even in older versions.

https://github.com/rpm-software-management/rpm/issues/2078
2024-06-21 15:18:06 -04:00
Fedora Release Engineering
72cb54ec6a Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-25 09:10:06 +00:00
Fedora Release Engineering
945b0837ce Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-21 09:48:26 +00:00
Stephen Gallagher
9b4f2a673f Restrict autoprovides and requires to top-level
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2023-10-26 10:04:04 -04:00
Stephen Gallagher
7e46ce796e Get autoprovides from any package.json
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2023-10-24 08:35:12 -04:00
Fedora Release Engineering
53bdaf5b75 Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-20 16:47:03 +00:00
Stephen Gallagher
aacfe2f12b
Drop instructions for upgrading node pkg
It is out of date as of
https://www.fedoraproject.org/wiki/Changes/NodejsRepackaging and we now
have packaging instructions included in the README.md of the individual
Node.js interpreter packaging repositories.

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2023-04-27 11:44:13 -04:00
Stephen Gallagher
5c3231171a
Update version and switch to rpmautospec
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2023-03-10 10:57:08 -05:00
Stephen Gallagher
1998d72b1a
Set correct %nodejs_sitelib path
Resolves: rhbz#2177117

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2023-03-10 10:37:32 -05:00
Stephen Gallagher
0cd3fed400
The Node.js ABI version is now represented by the NODE_MODULE_VERSION
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2023-03-10 10:09:57 -05:00
Stephen Gallagher
5079b893be
Bundler: Update to modern npm arguments
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2023-03-10 09:44:24 -05:00
Fedora Release Engineering
abc52b1e7b Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-19 21:42:02 +00:00
Stephen Gallagher
2a08691cf3
Move native module building tools here from Node.js
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2022-10-20 10:00:18 -04:00
Davide Cavalca
53057fc311 nodejs-packaging-bundler: recursively bundle modules for all packages found 2022-10-18 19:54:26 -07:00
Fedora Release Engineering
3c8da6aa4e Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-07-22 00:41:14 +00:00
Davide Cavalca
1e45404676 nodejs-packaging-bundler: optionally use a local tarball instead of npm 2022-07-02 09:08:17 -07:00
Stephen Gallagher
4847810bc1
NPM bundler: also find namespaced bundled dependencies
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2022-01-20 08:09:32 -05:00
Jan Staněk
e24e7dff07
nodejs.prov: find namespaced bundled dependencies
The previous behaviour assumed that in a bundled package path,
there is always `node_modules` directory on each other spot – i.e.:

npm/node_modules/<dep1>/node_modules/<subdep>
    ^                   ^

With namespaced bundled packages, this is no longer necessary the truth:

npm/node_modules/@nmcli/<dep1>/node_modules/…
    ^                   ! – expected node_modules

---

The previous implementation considered any directory not named
`node_modules` as a package directory, and tried to process it as such.
Among other things, it pruned the list of subdirectories to be processed
to just another `node_modules` subdir, if that existed.
With namespaced packages, this pruning in essence happened too soon,
and so they were skipped altogether.

With this patch applied, only directories that directly contain
the `package.json` file are processed as package directories,
meaning that the walk should correctly descend into namespaces
(even nested ones, if they appear).

Resolves: rhbz#2029904
2022-01-20 12:24:09 +01:00
josef radinger
b1c10eec41 fix typos 2022-01-02 19:51:00 +00:00
Fedora Release Engineering
d814f7439e - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-22 16:13:42 +00:00
Stephen Gallagher
abab55a363
Fix hard-coded output directory in the bundler
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2021-06-22 12:28:17 -04:00
Benjamin A. Beasley
fb332bd0ea In nodejs-packaging-bundler, use %{_sourcedir} for output
Fixes RHBZ#1974709
2021-06-22 07:52:40 -04:00
Benjamin A. Beasley
5385bed950 Actually use the value of OUTPUT_DIR when copying bundled sources in nodejs-packaging-bundler 2021-06-22 07:50:42 -04:00
Stephen Gallagher
bef475468a
Update to 2021.06
bundler: Handle archaic license metadata
bundler: Warn about bundled dependencies with no license metadata

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2021-06-02 14:21:55 -04:00
Stephen Gallagher
2ab3684dd6 Spec: fix line-length for rpmlint
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2021-06-02 18:17:12 +00:00
Stephen Gallagher
e7b09b6fec bundler: Add warning for deps missing license tag
Resolves: rhbz#1920223

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2021-06-02 18:17:12 +00:00
Stephen Gallagher
7aed687bf8 bundler: Handle deprecated license metadata
Adds support for archaic forms of the license metadata in
package.json where the license field is an object rather than a
string.

Also removes the need to post-process the 'null' entries.

Resolves: rhbz#1920206

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2021-06-02 18:17:12 +00:00
Stephen Gallagher
9074f546bf Fix incorrect flag for fedpkg scratch-build 2021-04-20 19:48:39 +00:00
Fedora Release Engineering
ed5219fd68 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-01-26 21:36:55 +00:00
Stephen Gallagher
a21e3d16f8
nodejs-packaging-bundler improvements to handle uncommon characters
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2021-01-20 09:19:40 -05:00
Michel Alexandre Salim
7d1699cedc
nodejs-packaging-bundler: sanitize package name
The NPM package name might contain invalid characters, e.g.
`@bitwarden/cli`.

Normalize the generated bundles by converting `/` to `-`.

```
specs/nodejs on  master
❯ ~/src/fedora/pkgs-others/nodejs-packaging/nodejs-packaging-bundler @bitwarden/cli
...
    Successful dev dependences download
'@bitwarden-cli-1.13.3-bundled-licenses.txt' -> '/home/michel/rpmbuild/SOURCES/@bitwarden-cli-1.13.3-bundled-licenses.txt'
'@bitwarden-cli-1.13.3-nm-dev.tgz' -> '/home/michel/rpmbuild/SOURCES/@bitwarden-cli-1.13.3-nm-dev.tgz'
'@bitwarden-cli-1.13.3-nm-prod.tgz' -> '/home/michel/rpmbuild/SOURCES/@bitwarden-cli-1.13.3-nm-prod.tgz'
```

Signed-off-by: Michel Alexandre Salim <michel@michel-slm.name>
2021-01-18 09:39:00 -08:00
Troy Dawson
05a9e58997 Fix null when there is no .licenses found.
Signed-off-by: Troy Dawson <tdawson@redhat.com>
2021-01-11 13:54:15 -08:00
Troy Dawson
5b7b3fce5d Add nodejs-packaging-bundler file
Add nodejs-packaging-bundler subpackage in spec file
Update README.md with comments about nodejs-packaging-bundler
  and an example spec file that uses bundling

Signed-off-by: Troy Dawson <tdawson@redhat.com>
2021-01-08 09:39:42 -08:00
Stephen Gallagher
8de3f914f4 Make dist-git the upstream repo
Since the scripts and tools in this package are really Fedora
(and derivatives) specific, it doesn't really make a lot of
sense to maintain them in a separate upstream with tarball
releases.

This moves all the files into dist-git and builds the RPM from
there.

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2020-09-18 15:50:14 -04:00
Stephen Gallagher
c68c968e27
Fix incorrect bundled library detection for Requires
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2020-09-02 10:52:07 -04:00
Stephen Gallagher
372df431ef
Check node_modules_prod for bundled dependencies
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2020-09-01 10:46:37 -04:00
Fedora Release Engineering
3ee96cddfd - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-07-28 10:55:05 +00:00
Stephen Gallagher
021f0badab
Drop Requires: nodejs(engine)
This is no longer needed (Fedora and EPEL are both well past 0.10
at this point). It was also incorrect to begin with. It should have
been `Conflicts: nodejs(engine) < 0.10.13` since it was only intended
to force the upgrade if it was currently installed, not to force
nodejs itself to be brought in.

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2020-06-03 09:25:32 -04:00
Fedora Release Engineering
06eeb0e699 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-01-29 17:45:01 +00:00
Tom Hughes
f3e8a0485d Ensure nodejs(engine) is required for packages with no dependencies 2019-10-31 10:06:29 +00:00
Fedora Release Engineering
47235c6094 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-07-25 21:14:55 +00:00
Tom Hughes
9875fea47c Refactor nodejs.req in more idiomatic Python
Also treat only external dependency links as un-bundled.
2019-07-02 18:14:32 +01:00
Tom Hughes
0af8638afd Refactor nodejs.prov in more idiomatic Python 2019-06-10 15:33:14 +01:00
Fedora Release Engineering
82f548aa25 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-02-01 15:00:05 +00:00
Tom Hughes
3b49842408 Fix handling of ^ dependencies for multiversion modules 2019-01-05 12:26:48 +00:00
Tom Hughes
d4c27e1ef4 Handle =, >= and <= dependencies for multiversion modules 2019-01-03 17:24:12 +00:00
Fedora Release Engineering
fefb4a0eae - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2018-07-13 13:29:19 +00:00
Tom Hughes
682ccaa773 Fix version comparators with a space after the operator 2018-05-03 08:51:04 +01:00
Tom Hughes
9983689c06 Add BR for python3 2018-05-02 01:01:02 +01:00