55 lines
1.4 KiB
RPMSpec
55 lines
1.4 KiB
RPMSpec
%global gem_name coffee-script
|
|
Name: rubygem-%{gem_name}
|
|
Version: 2.4.1
|
|
Release: 1
|
|
Summary: Ruby CoffeeScript Compiler
|
|
License: MIT
|
|
URL: https://github.com/rails/ruby-coffee-script
|
|
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
|
Source1: https://github.com/rails/ruby-%{gem_name}/archive/v%{version}.tar.gz
|
|
BuildRequires: ruby(release) rubygems-devel ruby rubygem(coffee-script-source) rubygem(execjs)
|
|
BuildRequires: rubygem(minitest) nodejs-devel
|
|
BuildArch: noarch
|
|
%description
|
|
Ruby CoffeeScript is a bridge to the JS CoffeeScript compiler.
|
|
|
|
%package doc
|
|
Summary: Documentation for %{name}
|
|
Requires: %{name} = %{version}-%{release}
|
|
BuildArch: noarch
|
|
%description doc
|
|
Documentation for %{name}.
|
|
|
|
%prep
|
|
%setup -q -c -T
|
|
%gem_install -n %{SOURCE0}
|
|
|
|
%build
|
|
|
|
%install
|
|
mkdir -p %{buildroot}%{gem_dir}
|
|
cp -a .%{gem_dir}/* \
|
|
%{buildroot}%{gem_dir}/
|
|
|
|
%check
|
|
pushd .%{gem_instdir}
|
|
tar xzf %{SOURCE1}
|
|
ln -s ruby-%{gem_naem}-%{version}/test test
|
|
ruby -Ilib -e 'Dir.glob "./test/**/test_*.rb", &method(:require)'
|
|
popd
|
|
|
|
%files
|
|
%dir %{gem_instdir}
|
|
%license %{gem_instdir}/LICENSE
|
|
%{gem_libdir}
|
|
%exclude %{gem_cache}
|
|
%{gem_spec}
|
|
|
|
%files doc
|
|
%doc %{gem_docdir}
|
|
%doc %{gem_instdir}/README.md
|
|
|
|
%changelog
|
|
* Thu Aug 20 2020 fanjiachen <fanjiachen3@huawei.com> - 2.4.1-1
|
|
- package init
|