]> git.pld-linux.org Git - packages/ruby-safe_yaml.git/blame - ruby-safe_yaml.spec
build with gem provides
[packages/ruby-safe_yaml.git] / ruby-safe_yaml.spec
CommitLineData
362aae0b
ER
1#
2# Conditional build:
3%bcond_with tests # build without tests
4
d7b67053
ER
5%define pkgname safe_yaml
6Summary: Parse YAML safely
7Name: ruby-%{pkgname}
8Version: 0.9.4
9Release: 1
10License: MIT
11Group: Development/Languages
12Source0: http://rubygems.org/downloads/%{pkgname}-%{version}.gem
13# Source0-md5: 9788eb941a0935853679ee186a3d481b
14URL: http://dtao.github.com/safe_yaml/
15BuildRequires: rpm-rubyprov
16BuildRequires: rpmbuild(macros) >= 1.656
362aae0b
ER
17%if %{with tests}
18BuildRequires: ruby-hashie
19BuildRequires: ruby-heredoc_unindent
20BuildRequires: ruby-ostruct
21BuildRequires: ruby-rspec
22BuildRequires: ruby-yaml
23%endif
d7b67053
ER
24BuildArch: noarch
25BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27%description
28Parse YAML safely, without that pesky arbitrary object deserialization
29vulnerability
30
31%prep
32%setup -q -n %{pkgname}-%{version}
33
362aae0b 34%build
ec19f15b
ER
35%__gem_helper spec
36
362aae0b
ER
37%if %{with tests}
38rspec -Ilib spec
39%endif
40
d7b67053
ER
41%install
42rm -rf $RPM_BUILD_ROOT
43install -d $RPM_BUILD_ROOT%{ruby_vendorlibdir}
44cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir}
45
ec19f15b
ER
46# install gemspec
47install -d $RPM_BUILD_ROOT%{ruby_specdir}
48cp -p %{pkgname}-%{version}.gemspec $RPM_BUILD_ROOT%{ruby_specdir}
49
d7b67053
ER
50%clean
51rm -rf $RPM_BUILD_ROOT
52
53%files
54%defattr(644,root,root,755)
362aae0b 55%doc README.md CHANGES.md LICENSE.txt
d7b67053
ER
56%{ruby_vendorlibdir}/safe_yaml.rb
57%{ruby_vendorlibdir}/safe_yaml
ec19f15b 58%{ruby_specdir}/safe_yaml-%{version}.gemspec
This page took 0.097902 seconds and 4 git commands to generate.