49 lines
1.4 KiB
RPMSpec
49 lines
1.4 KiB
RPMSpec
%{?nodejs_find_provides_and_requires}
|
|
%global enable_tests 0
|
|
Name: nodejs-form-data
|
|
Version: 0.2.0
|
|
Release: 1
|
|
Summary: A module to create readable "multipart/form-data" streams
|
|
License: MIT
|
|
URL: https://github.com/form-data/form-data
|
|
Source0: https://github.com/form-data/form-data/archive/0.2/form-data-%{version}.tar.gz
|
|
BuildArch: noarch
|
|
ExclusiveArch: %{nodejs_arches} noarch
|
|
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
|
|
BuildRequires: nodejs-packaging
|
|
BuildRequires: npm(async) npm(combined-stream) npm(mime-types)
|
|
%if 0%{?enable_tests}
|
|
BuildRequires: npm(fake) npm(far) npm(formidable) npm(request)
|
|
%endif
|
|
%description
|
|
A module to create readable "multipart/form-data" streams. Can be used to
|
|
submit forms and file uploads to other web applications.
|
|
|
|
%prep
|
|
%setup -q -n form-data-0.2
|
|
%nodejs_fixdep async "^1.5.0"
|
|
%nodejs_fixdep mime-types "^2.1.7"
|
|
%nodejs_fixdep combined-stream "^1.0.5"
|
|
|
|
%build
|
|
|
|
%install
|
|
mkdir -p %{buildroot}%{nodejs_sitelib}/form-data
|
|
cp -pr package.json lib %{buildroot}%{nodejs_sitelib}/form-data
|
|
|
|
%check
|
|
%nodejs_symlink_deps --check
|
|
%__nodejs -e "require('./')"
|
|
%if 0%{?enable_tests}
|
|
%__nodejs test/run.js
|
|
%endif
|
|
|
|
%files
|
|
%doc Readme.md
|
|
%license License
|
|
%{nodejs_sitelib}/form-data
|
|
|
|
%changelog
|
|
* Thu Aug 20 2020 Anan Fu <fuanan3@huawei.com> - 0.2.0-1
|
|
- package init
|