|
|
@ -3,35 +3,22 @@
|
|
|
|
#enable/disable tests in case the deps aren't there
|
|
|
|
#enable/disable tests in case the deps aren't there
|
|
|
|
%global enable_tests 1
|
|
|
|
%global enable_tests 1
|
|
|
|
|
|
|
|
|
|
|
|
%if 0%{?fedora}
|
|
|
|
|
|
|
|
%global installdir %{_jsdir}
|
|
|
|
|
|
|
|
%else
|
|
|
|
|
|
|
|
%global installdir %{_datadir}/javascript
|
|
|
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Name: uglify-js
|
|
|
|
Name: uglify-js
|
|
|
|
Version: 2.8.22
|
|
|
|
Version: 2.8.22
|
|
|
|
Release: 7%{?dist}
|
|
|
|
Release: 8%{?dist}
|
|
|
|
Summary: JavaScript parser, mangler/compressor and beautifier toolkit
|
|
|
|
Summary: JavaScript parser, mangler/compressor and beautifier toolkit
|
|
|
|
License: BSD
|
|
|
|
License: BSD
|
|
|
|
URL: https://github.com/mishoo/UglifyJS2
|
|
|
|
URL: https://github.com/mishoo/UglifyJS2
|
|
|
|
Source0: https://github.com/mishoo/UglifyJS2/archive/v%{version}/uglify-js-%{version}.tar.gz
|
|
|
|
Source0: https://github.com/mishoo/UglifyJS2/archive/v%{version}/uglify-js-%{version}.tar.gz
|
|
|
|
Patch0: uglify-js-esfuzz.patch
|
|
|
|
Patch0: uglify-js-esfuzz.patch
|
|
|
|
|
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
BuildArch: noarch
|
|
|
|
%if 0%{?fedora} >= 19
|
|
|
|
|
|
|
|
ExclusiveArch: %{nodejs_arches} noarch
|
|
|
|
ExclusiveArch: %{nodejs_arches} noarch
|
|
|
|
%else
|
|
|
|
|
|
|
|
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
|
|
|
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Provides: nodejs-uglify-js = %{version}-%{release}
|
|
|
|
Provides: nodejs-uglify-js = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
|
|
BuildRequires: nodejs-packaging
|
|
|
|
BuildRequires: nodejs-packaging
|
|
|
|
|
|
|
|
|
|
|
|
%if 0%{?fedora}
|
|
|
|
|
|
|
|
BuildRequires: web-assets-devel
|
|
|
|
BuildRequires: web-assets-devel
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%if 0%{?enable_tests}
|
|
|
|
%if 0%{?enable_tests}
|
|
|
|
BuildRequires: npm(acorn)
|
|
|
|
BuildRequires: npm(acorn)
|
|
|
@ -79,9 +66,9 @@ runtime.
|
|
|
|
%install
|
|
|
|
%install
|
|
|
|
rm -rf %buildroot
|
|
|
|
rm -rf %buildroot
|
|
|
|
|
|
|
|
|
|
|
|
mkdir -p %{buildroot}%{installdir}/%{name}-2
|
|
|
|
mkdir -p %{buildroot}%{_jsdir}/%{name}-2
|
|
|
|
cp -pr lib/* %{buildroot}%{installdir}/%{name}-2
|
|
|
|
cp -pr lib/* %{buildroot}%{_jsdir}/%{name}-2
|
|
|
|
ln -sf %{name}-2 %{buildroot}%{installdir}/%{name}
|
|
|
|
ln -sf %{name}-2 %{buildroot}%{_jsdir}/%{name}
|
|
|
|
|
|
|
|
|
|
|
|
#compat symlink
|
|
|
|
#compat symlink
|
|
|
|
mkdir -p %{buildroot}%{_datadir}
|
|
|
|
mkdir -p %{buildroot}%{_datadir}
|
|
|
@ -89,7 +76,7 @@ ln -sf javascript/%{name} %{buildroot}%{_datadir}/%{name}
|
|
|
|
|
|
|
|
|
|
|
|
mkdir -p %{buildroot}%{nodejs_sitelib}/uglify-js@2
|
|
|
|
mkdir -p %{buildroot}%{nodejs_sitelib}/uglify-js@2
|
|
|
|
cp -pr bin tools package.json %{buildroot}%{nodejs_sitelib}/uglify-js@2
|
|
|
|
cp -pr bin tools package.json %{buildroot}%{nodejs_sitelib}/uglify-js@2
|
|
|
|
ln -sf %{installdir}/%{name} %{buildroot}%{nodejs_sitelib}/uglify-js@2/lib
|
|
|
|
ln -sf %{_jsdir}/%{name} %{buildroot}%{nodejs_sitelib}/uglify-js@2/lib
|
|
|
|
# Fix for rpmlint.
|
|
|
|
# Fix for rpmlint.
|
|
|
|
sed -i -e 's|^#! */usr/bin/env node|#!/usr/bin/node|' \
|
|
|
|
sed -i -e 's|^#! */usr/bin/env node|#!/usr/bin/node|' \
|
|
|
|
%{buildroot}%{nodejs_sitelib}/uglify-js@2/bin/*
|
|
|
|
%{buildroot}%{nodejs_sitelib}/uglify-js@2/bin/*
|
|
|
@ -135,14 +122,17 @@ end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files -n js-uglify
|
|
|
|
%files -n js-uglify
|
|
|
|
%{installdir}/%{name}-2
|
|
|
|
%{_jsdir}/%{name}-2
|
|
|
|
%{installdir}/%{name}
|
|
|
|
%{_jsdir}/%{name}
|
|
|
|
%{_datadir}/%{name}
|
|
|
|
%{_datadir}/%{name}
|
|
|
|
%doc README.md
|
|
|
|
%doc README.md
|
|
|
|
%license LICENSE
|
|
|
|
%license LICENSE
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
%changelog
|
|
|
|
|
|
|
|
* Wed Jan 22 2020 Jan Staněk <jstanek@redhat.com> - 2.8.22-8
|
|
|
|
|
|
|
|
- Remove unneeded legacy conditionals around %%{nodejs_arches} and %%{_jsdir}
|
|
|
|
|
|
|
|
|
|
|
|
* Sat Jul 27 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.8.22-7
|
|
|
|
* Sat Jul 27 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.8.22-7
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
|
|