Projects
Eulaceura:Factory
uglify-js
_service:obs_scm:uglify-js.spec
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:obs_scm:uglify-js.spec of Package uglify-js
%{?nodejs_find_provides_and_requires} %global enable_tests 1 %global installdir %{_jsdir} Name: uglify-js Version: 2.8.22 Release: 2 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 Patch1: skip-identifier-with-test.patch BuildArch: noarch ExclusiveArch: %{nodejs_arches} noarch Provides: nodejs-uglify-js = %{version}-%{release} BuildRequires: nodejs-packaging BuildRequires: web-assets-devel %if 0%{?enable_tests} BuildRequires: npm(acorn) npm(async) npm(mocha) npm(optimist) npm(source-map) %endif Requires: js-uglify = %{version}-%{release} %description JavaScript parser, mangler/compressor and beautifier toolkit. This package ships the uglifyjs command-line tool and a library suitable for use within Node.js. %package -n js-uglify Summary: JavaScript parser, mangler/compressor and beautifier toolkit - core library Obsoletes: uglify-js-common < 2.2.5-4 Provides: uglify-js-common = %{version}-%{release} Requires: web-assets-filesystem %description -n js-uglify JavaScript parser, mangler/compressor and beautifier toolkit. This package ships a JavaScript library suitable for use by any JavaScript runtime. %prep %autosetup -p 1 -n UglifyJS2-%{version} %nodejs_fixdep async "^1.5.0" %nodejs_fixdep yargs "^3.2.1" %build %install rm -rf %buildroot mkdir -p %{buildroot}%{installdir}/%{name}-2 cp -pr lib/* %{buildroot}%{installdir}/%{name}-2 ln -sf %{name}-2 %{buildroot}%{installdir}/%{name} 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 %{installdir}/%{name} %{buildroot}%{nodejs_sitelib}/uglify-js@2/lib sed -i -e 's|^#! */usr/bin/env node|#!/usr/bin/node|' \ %{buildroot}%{nodejs_sitelib}/uglify-js@2/bin/* mkdir -p %{buildroot}%{_bindir} ln -sf ../lib/node_modules/uglify-js@2/bin/uglifyjs %{buildroot}%{_bindir}/uglifyjs %nodejs_symlink_deps ln -sf uglify-js@2 %{buildroot}%{nodejs_sitelib}/uglify-js %check %nodejs_symlink_deps --check %{__nodejs} -e 'require("./")' %if 0%{?enable_tests} sed -i '/timeout/ s/5000/10000/' test/mocha/cli.js sed -i '/timeout/ s/10000/20000/' test/mocha/let.js sed -i '/timeout/ s/20000/40000/' test/mocha/spidermonkey.js NODE_DISABLE_COLORS=true %__nodejs test/run-tests.js %endif %pretrans -p <lua> st = posix.stat("%{nodejs_sitelib}/uglify-js") if st and st.type == "directory" then os.execute("rm -rf %{nodejs_sitelib}/uglify-js") end %pretrans -n js-uglify -p <lua> st = posix.stat("%{_datadir}/%{name}") if st and st.type == "directory" then os.execute("rm -rf %{_datadir}/%{name}") end %files %{nodejs_sitelib}/uglify-js %{nodejs_sitelib}/uglify-js@2 %{_bindir}/uglifyjs %files -n js-uglify %{installdir}/%{name}-2 %{installdir}/%{name} %{_datadir}/%{name} %doc README.md %license LICENSE %changelog * Tue Apr 23 2024 wangkai <13474090681@163.com> - 2.8.22-2 - skip identifier with test for nodejs20 * Mon Aug 24 2020 wangyue <wangyue92@huawei.com> - 2.8.22-1 - package init
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2