]> git.pld-linux.org Git - packages/apache-mod_ruby.git/blob - apache-mod_ruby.spec
- up to 1.2.0, works.
[packages/apache-mod_ruby.git] / apache-mod_ruby.spec
1 %define         mod_name        mod_ruby
2 %define         apxs            /usr/sbin/apxs
3 %define         _pkglibdir      %(%{apxs} -q LIBEXECDIR)
4 %define         _modrubyconf    %{_sysconfdir}/httpd/httpd.conf/70_mod_ruby.conf
5 Summary:        Apache mod_ruby module - embeds the Ruby interpreter into the Apache web server
6 Summary(pl):    Modu³ Apache'a mod_ruby - zapewniaj±cy obs³ugê skryptów rubego przez serwer Apache
7 Name:           apache-%{mod_name}
8 Version:        1.2.0
9 Release:        0.9
10 Group:          Networking/Daemons
11 License:        BSD-like
12 Source0:        http://www.modruby.net/archive/%{mod_name}-%{version}.tar.gz
13 # Source0-md5:  baf4f0fe44ae557528754f49b4ae46b9
14 Source1:        %{name}.conf
15 Patch0:         %{name}-struct.patch
16 URL:            http://www.modruby.net/
17 BuildRequires:  apache-devel >= 1.3.3
18 BuildRequires:  %{apxs}
19 BuildRequires:  ruby >= 1.6.4
20 Requires(post,preun):   %{apxs}
21 Requires:       apache >= 1.3.3
22 Requires:       ruby >= 1.6.4
23 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
25 %description
26 mod_ruby embeds the Ruby interpreter into the Apache web server,
27 allowing Ruby CGI scripts to be executed natively. These scripts will
28 start up much faster than without mod_ruby.
29
30 %description -l pl
31 mod_ruby zapewnia obs³ugê skryptów Ruby'ego bezpo¶rednio z poziomu
32 Apache'a, dziêki czemu bêd± siê one ³adowa³y znacnie szybciej ni¿
33 gdyby by³y wywo³ywane tradycyjnie.
34
35 %prep
36 %setup -q -n %{mod_name}-%{version}
37 %patch0 -p1
38
39 %build
40 ./configure.rb \
41         --with-apr-includes='/usr/include/apr -I/usr/include/apr-util'\
42         --with-apxs=%{apxs}
43 %{__make}
44
45 %install
46 rm -rf $RPM_BUILD_ROOT
47
48 install -d $RPM_BUILD_ROOT%{_pkglibdir}
49 install %{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}/%{mod_name}.so
50
51 # Install the config file
52 install -d $RPM_BUILD_ROOT%{_sysconfdir}/httpd/httpd.conf
53 install %{SOURCE1} $RPM_BUILD_ROOT%{_modrubyconf}
54
55 %clean
56 rm -rf $RPM_BUILD_ROOT
57
58 %post
59 if [ -f /var/lock/subsys/httpd ]; then
60         /etc/rc.d/init.d/httpd restart 1>&2
61 fi
62
63 %preun
64 if [ "$1" = "0" ]; then
65         if [ -f /var/lock/subsys/httpd ]; then
66                 /etc/rc.d/init.d/httpd restart 1>&2
67         fi
68 fi
69
70 %files
71 %defattr(644,root,root,755)
72 %doc COPYING ChangeLog README.en examples doc/*
73 %lang(ja) %doc README.ja
74 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/httpd/httpd.conf/70_mod_ruby.conf
75 %attr(755,root,root) %{_pkglibdir}/*
This page took 0.049705 seconds and 4 git commands to generate.