Update to 3.10.4

epel9
Troy Dawson 4 years ago
parent ba72a7e6b8
commit 62038941c7

1
.gitignore vendored

@ -6,3 +6,4 @@
/uglify-js-2.7.0.tar.gz
/uglify-js-2.8.17.tar.gz
/uglify-js-2.8.22.tar.gz
/uglify-js-3.10.4.tgz

@ -1 +1 @@
SHA512 (uglify-js-2.8.22.tar.gz) = d881d226f6c17c3c49c20a765d16f09e8c23e413368e7e03fb6e6a9f39aa3686f45dcba9642f9c137f5a2ac6ac56ae5e4cff456b2eacba528776c5c36c01e63a
SHA512 (uglify-js-3.10.4.tgz) = 901153dd4e03723e3fa49e76bdf8c249fc8bcaf1bd55862e1983e6acfbc0c51c3f8bbc47893e15bc27affae88431c1048aee94341e8a816986b5251821649c6f

@ -1,23 +0,0 @@
commit 2c6570391beeda550f86500e3f7c6eaa992a05b7
Author: Tom Hughes <tom@compton.nu>
Date: Wed Feb 10 18:16:53 2016 +0000
Patch out tests that require esfuzz
diff --git a/test/run-tests.js b/test/run-tests.js
index 3ec04fd..96c0613 100755
--- a/test/run-tests.js
+++ b/test/run-tests.js
@@ -19,12 +19,6 @@ if (failures) {
var run_sourcemaps_tests = require('./sourcemaps');
run_sourcemaps_tests();
-var run_ast_conversion_tests = require("./mozilla-ast");
-
-run_ast_conversion_tests({
- iterations: 1000
-});
-
/* -----[ utils ]----- */
function tmpl() {

@ -4,29 +4,25 @@
%bcond_with tests
Name: uglify-js
Version: 2.8.22
Release: 10%{?dist}
Version: 3.10.4
Release: 1%{?dist}
Summary: JavaScript parser, mangler/compressor and beautifier toolkit
License: BSD
URL: https://github.com/mishoo/UglifyJS2
Source0: https://github.com/mishoo/UglifyJS2/archive/v%{version}/uglify-js-%{version}.tar.gz
Patch0: uglify-js-esfuzz.patch
URL: https://github.com/mishoo/UglifyJS
Source0: http://registry.npmjs.org/%{name}/-/%{name}-%{version}.tgz
BuildArch: noarch
ExclusiveArch: %{nodejs_arches} noarch
Provides: nodejs-uglify-js = %{version}-%{release}
BuildRequires: nodejs
BuildRequires: nodejs-packaging
BuildRequires: web-assets-devel
BuildRequires: npm(source-map)
%if %{with tests}
BuildRequires: npm(acorn)
BuildRequires: npm(async)
BuildRequires: npm(mocha)
BuildRequires: npm(optimist)
BuildRequires: npm(source-map)
BuildRequires: npm(semver)
%endif
Requires: js-uglify = %{version}-%{release}
@ -54,40 +50,37 @@ This package ships a JavaScript library suitable for use by any JavaScript
runtime.
%prep
%autosetup -p 1 -n UglifyJS2-%{version}
%autosetup -n package
%nodejs_fixdep async "^1.5.0"
%nodejs_fixdep yargs "^3.2.1"
%nodejs_fixdep source-map ">=0.5.1"
chmod 0755 bin/uglifyjs
%build
#nothing to do
%install
rm -rf %buildroot
mkdir -p %{buildroot}%{_jsdir}/%{name}-2
cp -pr lib/* %{buildroot}%{_jsdir}/%{name}-2
ln -sf %{name}-2 %{buildroot}%{_jsdir}/%{name}
mkdir -p %{buildroot}%{_jsdir}/%{name}-3
cp -pr lib/* %{buildroot}%{_jsdir}/%{name}-3
ln -sf %{name}-3 %{buildroot}%{_jsdir}/%{name}
#compat symlink
mkdir -p %{buildroot}%{_datadir}
ln -sf javascript/%{name} %{buildroot}%{_datadir}/%{name}
mkdir -p %{buildroot}%{nodejs_sitelib}/uglify-js@2
cp -pr bin tools package.json %{buildroot}%{nodejs_sitelib}/uglify-js@2
ln -sf %{_jsdir}/%{name} %{buildroot}%{nodejs_sitelib}/uglify-js@2/lib
mkdir -p %{buildroot}%{nodejs_sitelib}/uglify-js@3
cp -pr bin tools package.json %{buildroot}%{nodejs_sitelib}/uglify-js@3
ln -sf %{_jsdir}/%{name} %{buildroot}%{nodejs_sitelib}/uglify-js@3/lib
# Fix for rpmlint.
sed -i -e 's|^#! */usr/bin/env node|#!/usr/bin/node|' \
%{buildroot}%{nodejs_sitelib}/uglify-js@2/bin/*
%{buildroot}%{nodejs_sitelib}/uglify-js@3/bin/*
chmod 755 %{buildroot}%{nodejs_sitelib}/uglify-js@3/bin/uglifyjs
mkdir -p %{buildroot}%{_bindir}
ln -sf ../lib/node_modules/uglify-js@2/bin/uglifyjs %{buildroot}%{_bindir}/uglifyjs
ln -sf ../lib/node_modules/uglify-js@3/bin/uglifyjs %{buildroot}%{_bindir}/uglifyjs
%nodejs_symlink_deps
ln -sf uglify-js@2 %{buildroot}%{nodejs_sitelib}/uglify-js
ln -sf uglify-js@3 %{buildroot}%{nodejs_sitelib}/uglify-js
%check
@ -118,12 +111,12 @@ end
%files
%{nodejs_sitelib}/uglify-js
%{nodejs_sitelib}/uglify-js@2
%{nodejs_sitelib}/uglify-js@3
%{_bindir}/uglifyjs
%files -n js-uglify
%{_jsdir}/%{name}-2
%{_jsdir}/%{name}-3
%{_jsdir}/%{name}
%{_datadir}/%{name}
%doc README.md
@ -131,6 +124,9 @@ end
%changelog
* Fri Sep 18 2020 Troy Dawson <tdawson@redhat.com> - 3.10.4-1
- Update to 3.10.4
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.8.22-10
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild

Loading…
Cancel
Save