]> git.pld-linux.org Git - packages/apache-mod_perl.git/blob - apache-mod_perl.spec
- added post and preun scripts with apxs installation of module
[packages/apache-mod_perl.git] / apache-mod_perl.spec
1 %include        /usr/lib/rpm/macros.perl
2 Summary:        A Perl interpreter for the Apache Web server
3 Summary(pl):    Interpreter perla dla serwera WWW Apache
4 Name:           apache-mod_perl
5 Version:        1.24
6 Release:        1
7 License:        GPL
8 Group:          Networking/Daemons
9 Group(pl):      Sieciowe/Serwery
10 Source0:        http://perl.apache.org/dist/mod_perl-%{version}.tar.gz
11 Patch0:         apache-perl-rh.patch
12 Patch1:         apache-perl-IPv6.patch
13 BuildRequires:  rpm-perlprov >= 3.0.3-16
14 BuildRequires:  perl >= 5.005_03-14
15 BuildRequires:  apache-devel
16 BuildRequires:  gdbm-devel
17 BuildRequires:  perl-libwww
18 BuildRequires:  perl-HTML-Parser
19 BuildRequires:  perl-MIME-Base64
20 BuildRequires:  perl-BSD-Resource
21 BuildRequires:  perl-B-Graph
22 BuildRequires:  perl-Devel-Symdump
23 BuildRequires:  perl-URI
24 %requires_eq    perl
25 Requires:       %{perl_sitearch}
26 Requires:       apache
27 Provides:       perl(mod_perl_hooks)
28 Provides:       mod_perl
29 Obsoletes:      mod_perl
30 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32 %description
33 Mod_perl incorporates a Perl interpreter into the Apache web server,
34 so that the Apache web server can directly execute Perl code. Mod_perl
35 links the Perl runtime library into the Apache web server and provides
36 an object-oriented Perl interface for Apache's C language API. The end
37 result is a quicker CGI script turnaround process, since no external
38 Perl interpreter has to be started.
39
40 %description -l pl
41 Mod_perl jest modu³em, który wyposa¿a serwer Apache w interpreter
42 perla, umo¿liwiaj±c w ten sposób bezpo¶rednie wykonywanie kodu perla
43 przez serwer bez potrzeby anga¿owania zewnêtrznego interpretera, co
44 przyspiesza procesy zwi±zane z uruchamianiem skryptów CGI.
45
46 %prep
47 %setup  -q -n mod_perl-%{version}
48 %patch0 -p1
49 # %patch1 -p1
50
51 %build
52 perl Makefile.PL \
53         USE_APXS=1 \
54         WITH_APXS=%{_sbindir}/apxs \
55         EVERYTHING=1 \
56         PERL_STACKED_HANDLERS=1
57
58 (cd apaci; ln -s ../src/modules .; chmod +x find_source)
59 make
60
61 (cd faq; make)
62
63 %install
64 rm -rf $RPM_BUILD_ROOT
65 install -d $RPM_BUILD_ROOT{%{_libdir}/apache,/home/httpd/html/manual/mod}
66
67 make pure_install DESTDIR=$RPM_BUILD_ROOT
68         
69 install -m 755 apaci/libperl.so $RPM_BUILD_ROOT%{_libdir}/apache
70 install htdocs/manual/mod/mod_perl.html \
71         $RPM_BUILD_ROOT/home/httpd/html/manual/mod
72
73 find $RPM_BUILD_ROOT -name \*.so -exec strip --strip-unneeded {} \;
74
75 (
76         cd $RPM_BUILD_ROOT%{perl_sitearch}/auto/mod_perl/
77         mv .packlist .packlist.old
78         sed -e "s|$RPM_BUILD_ROOT||g" < .packlist.old > .packlist
79         rm -f .packlist.old
80 )
81
82 gzip -9nf $RPM_BUILD_ROOT%{_mandir}/man3/* \
83         README INSTALL ToDo
84
85 %clean
86 rm -rf $RPM_BUILD_ROOT
87
88 %post
89 %{_sbindir}/apxs -e -a -n perl %{_libexecdir}/libperl.so 1>&2
90 if [ -f /var/lock/subsys/httpd ]; then
91    /etc/rc.d/init.d/httpd restart 1>&2
92 fi
93
94 %preun
95 %{_sbindir}/apxs -e -A -n perl %{_libexecdir}/libperl.so 1>&2
96
97 if [ -f /var/lock/subsys/httpd ]; then
98         /etc/rc.d/init.d/httpd stop 1>&2
99 fi
100
101
102 %files
103 %defattr(644,root,root,755)
104 %doc {README,INSTALL,ToDo}.gz faq/*.html apache-modlist.html eg
105 %doc /home/httpd/html/manual/mod/*html
106
107 %attr(755,root,root) %{_libdir}/apache/*.so
108
109 %{perl_sitearch}/*.pm
110 %{perl_sitearch}/*.pod
111 %{perl_sitearch}/*.PL
112
113 %{perl_sitearch}/Apache/*.pm
114 %{perl_sitearch}/Apache/Constants
115 %{perl_sitearch}/Bundle/*.pm
116 %{perl_sitearch}/auto/mod_perl
117 %dir %{perl_sitearch}/auto/Apache/Leak
118 %dir %{perl_sitearch}/auto/Apache/Symbol
119
120 %{perl_sitearch}/auto/*/*/*.bs
121 %attr(755,root,root) %{perl_sitearch}/auto/*/*/*.so
122
123 %{_mandir}/man3/*
This page took 0.05858 seconds and 4 git commands to generate.