]>
Commit | Line | Data |
---|---|---|
06a8e3ae ER |
1 | # TODO |
2 | # - frontend package | |
3 | # - admin package | |
4 | Summary: ClickHeat | Clicks heatmap | |
5 | Name: clickheat | |
6 | Version: 1.11 | |
7 | Release: 0.1 | |
8 | License: GPL v2 | |
9 | Group: Applications/WWW | |
10 | Source0: http://downloads.sourceforge.net/clickheat/%{name}-%{version}.zip | |
11 | # Source0-md5: 0ad7c917045772ebcc004027b4858098 | |
12 | Source1: apache.conf | |
13 | Source2: lighttpd.conf | |
14 | URL: http://www.labsmedia.com/clickheat/ | |
15 | BuildRequires: rpmbuild(macros) >= 1.268 | |
16 | Requires: webapps | |
17 | # see packages/webapps/webapps.README for description and complete listing | |
18 | Requires: php-gd | |
19 | Requires: webserver(access) | |
20 | Requires: webserver(alias) | |
21 | #Requires: webserver(auth) | |
22 | #Requires: webserver(cgi) | |
23 | #Requires: webserver(indexfile) | |
24 | Requires: webserver(php) | |
25 | #Requires: webserver(setenv) | |
26 | BuildArch: noarch | |
27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
28 | ||
29 | %define _webapps /etc/webapps | |
30 | %define _webapp %{name} | |
31 | %define _sysconfdir %{_webapps}/%{_webapp} | |
32 | %define _appdir %{_datadir}/%{_webapp} | |
33 | ||
34 | %description | |
35 | ClickHeat is a visual heatmap of clicks on a HTML page, showing hot | |
36 | and cold click zones. | |
37 | ||
38 | %prep | |
39 | %setup -qn %{name} | |
40 | ||
41 | # simplify packaging | |
42 | install -d doc | |
43 | mv INSTALL LICENSE LISEZMOI README VERSION doc | |
44 | ||
45 | %install | |
46 | rm -rf $RPM_BUILD_ROOT | |
47 | install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir}} | |
48 | ||
49 | cp -a . $RPM_BUILD_ROOT%{_appdir} | |
50 | rm -rf $RPM_BUILD_ROOT%{_appdir}/doc | |
51 | rm $RPM_BUILD_ROOT%{_appdir}/js/clickheat-original.js | |
52 | ||
53 | cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf | |
54 | cp -a %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf | |
55 | cp -a $RPM_BUILD_ROOT%{_sysconfdir}/{apache,httpd}.conf | |
56 | ||
57 | %triggerin -- apache1 < 1.3.37-3, apache1-base | |
58 | %webapp_register apache %{_webapp} | |
59 | ||
60 | %triggerun -- apache1 < 1.3.37-3, apache1-base | |
61 | %webapp_unregister apache %{_webapp} | |
62 | ||
63 | %triggerin -- apache < 2.2.0, apache-base | |
64 | %webapp_register httpd %{_webapp} | |
65 | ||
66 | %triggerun -- apache < 2.2.0, apache-base | |
67 | %webapp_unregister httpd %{_webapp} | |
68 | ||
69 | %triggerin -- lighttpd | |
70 | %webapp_register lighttpd %{_webapp} | |
71 | ||
72 | %triggerun -- lighttpd | |
73 | %webapp_unregister lighttpd %{_webapp} | |
74 | ||
75 | %clean | |
76 | rm -rf $RPM_BUILD_ROOT | |
77 | ||
78 | %files | |
79 | %defattr(644,root,root,755) | |
80 | %doc doc/* | |
81 | %dir %attr(750,root,http) %{_sysconfdir} | |
82 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf | |
83 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf | |
84 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf | |
85 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.php | |
86 | %{_appdir} |