Project

General

Profile

Download (2.77 KB) Statistics
| Branch: | Tag: | Revision:
%{?scl:%scl_package rubygem-%{gem_name}}
%{!?scl:%global pkg_name %{name}}

%global gem_name syntax

Summary: Ruby library for performing simple syntax highlighting
Name: %{?scl_prefix}rubygem-%{gem_name}
Version: 1.0.0
Release: 9%{?dist}
Group: Development/Languages
License: Public Domain
URL: http://syntax.rubyforge.org/
Source0: http://gems.rubyforge.org/gems/%{gem_name}-%{version}.gem
Source1: %{gem_name}-LICENSE
Patch0: rubygem-syntax-fix-yaml-parse-for-ruby-1.9.patch
BuildRoot: %{_tmppath}/%{pkg_name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires: %{?scl_prefix}ruby(abi) = 1.9.1
Requires: %{?scl_prefix}ruby(rubygems)
BuildRequires: %{?scl_prefix}rubygems-devel
BuildRequires: %{?scl_prefix}rubygem(minitest)
BuildArch: noarch
Provides: %{?scl_prefix}rubygem(%{gem_name}) = %{version}

%description
Syntax is a lexical analysis framework. It supports pluggable syntax
modules, and comes with modules for Ruby, XML, and YAML.


%prep
install -pm 0644 %{SOURCE1} LICENSE
mkdir -p .{gem_dir}
%{?scl:scl enable %{scl} "}
gem install --local --install-dir .%{gem_dir} \
--force --rdoc %{SOURCE0}
%{?scl:"}

pushd .%{gem_instdir}
%patch0
popd

%build


%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{gem_dir}
cp -a .%{gem_dir}/* $RPM_BUILD_ROOT%{gem_dir}

%clean
rm -rf $RPM_BUILD_ROOT

%check
pushd .%{gem_instdir}
%{?scl:scl enable %{scl} "}
ruby -Itest test/ALL-TESTS.rb
%{?scl:"}
popd

%files
%defattr(-,root,root,-)
%{gem_instdir}/
%doc %{gem_docdir}
%{gem_cache}
%{gem_spec}
%doc LICENSE

%changelog
* Fri Mar 15 2013 Lukas Zapletal <lzap+git@redhat.com> 1.0.0-8
- new package built with tito

* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Tue Jan 31 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 1.0.0-6
- Rebuilt for Ruby 1.9.3.
- Introduced %%check section.
- Added patch for Ruby 1.9.3 tests.

* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Mon Jul 08 2009 Lubomir Rintel (Good Data) <lubo.rintel@gooddata.com> - 1.0.0-2
- Bring tests back
- Depend on ruby(abi)
- Replace defines with globals

* Fri Jul 05 2009 Lubomir Rintel (Good Data) <lubo.rintel@gooddata.com> - 1.0.0-1
- Package generated by gem2rpm
- Don't ship tests
- Fix up License
(2-2/4)