1 %define pkgname rack-mount
2 Summary: A stackable dynamic tree based Rack router
7 Group: Development/Libraries
8 Source0: http://rubygems.org/downloads/%{pkgname}-%{version}.gem
9 # Source0-md5: 6fe33c194d4b63817bd6ab857ff720a7
10 URL: http://github.com/josh/rack-mount
11 BuildRequires: rpmbuild(macros) >= 1.484
12 BuildRequires: ruby >= 1:1.8.6
13 BuildRequires: ruby-modules
15 %{?ruby_mod_ver_requires_eq}
17 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20 Rack::Mount supports Rack’s Cascade style of trying several routes
21 until it finds one that is not a 404. This allows multiple routes to
22 be nested or stacked on top of each other. Since the application
23 endpoint can trigger the router to continue matching, middleware can
24 be used to add arbitrary conditions to any route. This allows you to
25 route based on other request attributes, session information, or even
26 data dynamically pulled from a database.
29 Summary: HTML documentation for %{pkgname}
30 Summary(pl.UTF-8): Dokumentacja w formacie HTML dla %{pkgname}
32 Requires: ruby >= 1:1.8.7-4
35 HTML documentation for %{pkgname}.
37 %description rdoc -l pl.UTF-8
38 Dokumentacja w formacie HTML dla %{pkgname}.
41 Summary: ri documentation for %{pkgname}
42 Summary(pl.UTF-8): Dokumentacja w formacie ri dla %{pkgname}
47 ri documentation for %{pkgname}.
49 %description ri -l pl.UTF-8
50 Dokumentacji w formacie ri dla %{pkgname}.
54 %{__tar} xf %{SOURCE0} -O data.tar.gz | %{__tar} xz
55 find -newer README.rdoc -o -print | xargs touch --reference %{SOURCE0}
60 rm -r ri/{Multimap,Multiset,NestedMultimap,Reginald,Rack/cdesc-Rack.yaml}
64 rm -rf $RPM_BUILD_ROOT
65 install -d $RPM_BUILD_ROOT{%{_bindir},%{ruby_rubylibdir},%{ruby_ridir},%{ruby_rdocdir}}
67 cp -a lib/* $RPM_BUILD_ROOT%{ruby_rubylibdir}
68 cp -a ri/* $RPM_BUILD_ROOT%{ruby_ridir}
69 cp -a rdoc $RPM_BUILD_ROOT%{ruby_rdocdir}/%{name}-%{version}
72 rm -rf $RPM_BUILD_ROOT
75 %defattr(644,root,root,755)
77 %{ruby_rubylibdir}/rack/mount
78 %{ruby_rubylibdir}/rack/mount.rb
81 %defattr(644,root,root,755)
82 %{ruby_rdocdir}/%{name}-%{version}
85 %defattr(644,root,root,755)
86 %{ruby_ridir}/Rack/Mount