]> git.pld-linux.org Git - packages/apache-mod_whatkilledus.git/blame_incremental - apache-mod_whatkilledus.spec
- release 2 (by relup.sh)
[packages/apache-mod_whatkilledus.git] / apache-mod_whatkilledus.spec
... / ...
CommitLineData
1%define mod_name whatkilledus
2%define apxs /usr/sbin/apxs
3Summary: Apache module: knows what a thread was handling in case the thread segfaults
4Summary(pl.UTF-8): Moduł apache wiedzący, co obsługiwał wątek w przypadku naruszenia ochrony pamięci
5Name: apache-mod_%{mod_name}
6Version: 2.01
7Release: 2
8License: Apache v2.0
9Group: Networking/Daemons/HTTP
10Source0: http://emptyhammock.com/downloads/wku_bt-%{version}.zip
11# Source0-md5: 32bbe148f6cb2b8714166388f94d9129
12Source1: http://mirrors.ludost.net/gentoo-portage/www-apache/mod_whatkilledus/files/gen_test_char.c
13# Source1-md5: 7c4e734d1afc695a5be53581998f3700
14URL: http://emptyhammock.com/projects/httpd/diag/
15BuildRequires: %{apxs}
16BuildRequires: apache-devel >= 2.0
17BuildRequires: rpmbuild(macros) >= 1.268
18Requires: apache(modules-api) = %apache_modules_api
19BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21%define _sysconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null)/conf.d
22%define _pkglibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null)
23
24%description
25Keeps a little bit of state on each active connection, which allows it
26to know what a thread was handling in case the thread segfaults.
27
28%description -l pl.UTF-8
29Moduł przechowujący wybrane informacje o stanie każdego aktywnego
30połączenia, pozwalające dowiedzieć się, co obsługiwał wątek w
31sytuacji, kiedy spowodował naruszenie ochrony pamięci.
32
33%prep
34%setup -q -n wku_bt-%{version}
35
36%build
37%{apxs} -c mod_%{mod_name}.c diag.c \
38 -DDIAG_HAVE_LIBUNWIND_BACKTRACE=1 \
39%if "%{__lib}" == "lib64"
40 -DDIAG_BITS_64=1 \
41%endif
42 -o mod_%{mod_name}.la
43
44%install
45rm -rf $RPM_BUILD_ROOT
46install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir},/var/log/httpd}
47install .libs/mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
48
49touch $RPM_BUILD_ROOT/var/log/httpd/whatkilledus_log
50
51cat > $RPM_BUILD_ROOT%{_sysconfdir}/68_mod_%{mod_name}.conf << 'EOF'
52LoadModule %{mod_name}_module modules/mod_%{mod_name}.so
53EnableExceptionHook On
54# WKUObscureInRequest On
55EOF
56
57%clean
58rm -rf $RPM_BUILD_ROOT
59
60%post
61%service -q httpd restart
62touch /var/log/httpd/whatkilledus_log && chown root:http /var/log/httpd/whatkilledus_log && chmod 620 /var/log/httpd/whatkilledus_log
63
64%postun
65if [ "$1" = "0" ]; then
66 %service -q httpd restart
67fi
68
69%triggerpostun -- %{name} < 2.00
70sed -i -e 's#^WhatKilledUsLog.*##g' %{_sysconfdir}/68_mod_%{mod_name}.conf
71
72%files
73%defattr(644,root,root,755)
74%doc CHANGES.txt NOTICE.txt
75%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*_mod_%{mod_name}.conf
76%attr(755,root,root) %{_pkglibdir}/*.so
77# append by webserver
78%attr(620,root,http) %ghost /var/log/httpd/whatkilledus_log
This page took 0.074864 seconds and 4 git commands to generate.