]> git.pld-linux.org Git - packages/ruby-re2.git/blob - ruby-re2.spec
- updated to 1.2.0
[packages/ruby-re2.git] / ruby-re2.spec
1 #
2 # Conditional build:
3 %bcond_with     tests           # build without tests
4
5 %define pkgname re2
6 Summary:        Ruby bindings to re2
7 Summary(pl.UTF-8):      Wiązania języka Ruby do re2
8 Name:           ruby-%{pkgname}
9 Version:        1.2.0
10 Release:        1
11 License:        BSD
12 Group:          Development/Languages
13 Source0:        http://rubygems.org/downloads/%{pkgname}-%{version}.gem
14 # Source0-md5:  8aaf69fac7a9567540791b5b5f7d35c8
15 URL:            https://github.com/mudge/re2
16 BuildRequires:  libstdc++-devel >= 6:4.8
17 BuildRequires:  re2-devel
18 BuildRequires:  rpm-rubyprov
19 BuildRequires:  rpmbuild(macros) >= 1.656
20 BuildRequires:  ruby-devel >= 1:1.8.7
21 %if %{with tests}
22 BuildRequires:  ruby-minitest < 6
23 BuildRequires:  ruby-minitest >= 5.4
24 BuildRequires:  ruby-rake-compiler < 1
25 BuildRequires:  ruby-rake-compiler >= 0.9
26 %endif
27 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28
29 %description
30 Ruby bindings to re2, an efficient, principled regular expression
31 library.
32
33 %description -l pl.UTF-8
34 Wiązania języka Ruby do re2 - wydajnej, zasadniczej biblioteki
35 wyrażeń regularnych.
36
37 %prep
38 %setup -q -n %{pkgname}-%{version}
39
40 %build
41 # write .gemspec
42 %__gem_helper spec
43
44 cd ext/%{pkgname}
45 %{__ruby} extconf.rb
46 %{__make} \
47         CC="%{__cc}" \
48         LDFLAGS="%{rpmldflags}" \
49         CFLAGS="%{rpmcflags} -fPIC"
50
51 %install
52 rm -rf $RPM_BUILD_ROOT
53 install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{ruby_vendorarchdir},%{ruby_specdir}}
54
55 cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir}
56 cp -p %{pkgname}-%{version}.gemspec $RPM_BUILD_ROOT%{ruby_specdir}
57 install -p ext/re2/re2.so $RPM_BUILD_ROOT%{ruby_vendorarchdir}
58
59 %clean
60 rm -rf $RPM_BUILD_ROOT
61
62 %files
63 %defattr(644,root,root,755)
64 %attr(755,root,root) %{ruby_vendorarchdir}/re2.so
65 %{ruby_vendorlibdir}/re2.rb
66 %{ruby_vendorlibdir}/re2
67 %{ruby_specdir}/%{pkgname}-%{version}.gemspec
This page took 0.065628 seconds and 4 git commands to generate.