1 # TODO: php() Rs, setup stuff
2 Summary: GGZ Community - web-based GGZ community platform
3 Summary(pl.UTF-8): GGZ Community - platforma społecznościowa GGZ oparta na WWW
8 Group: Applications/WWW
9 Source0: http://mirrors.dotsrc.org/ggzgamingzone/ggz/%{version}/%{name}-%{version}.tar.gz
10 # Source0-md5: 414201494a0c2b027d07a5836d9f9508
11 URL: http://www.ggzgamingzone.org/
12 Requires: webserver(php)
14 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
16 %define _webapps /etc/webapps
17 %define _webapp %{name}
18 %define _sysconfdir %{_webapps}/%{_webapp}
19 %define _appdir %{_datadir}/%{_webapp}
22 GGZ Community - web-based GGZ community platform.
24 %description -l pl.UTF-8
25 GGZ Community - platforma społecznościowa GGZ oparta na WWW.
30 cat > apache.conf <<'EOF'
31 Alias /%{name} %{_appdir}
32 <Directory %{_appdir}>
37 cat > lighttpd.conf <<'EOF'
39 "/%{name}" => "%{_appdir}",
44 rm -rf $RPM_BUILD_ROOT
45 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_datadir}}
47 cp -a web $RPM_BUILD_ROOT%{_appdir}
48 cp -p apache.conf $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
49 cp -p apache.conf $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
50 cp -p lighttpd.conf $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf
53 rm -rf $RPM_BUILD_ROOT
55 %triggerin -- apache1 < 1.3.37-3, apache1-base
56 %webapp_register apache %{_webapp}
58 %triggerun -- apache1 < 1.3.37-3, apache1-base
59 %webapp_unregister apache %{_webapp}
61 %triggerin -- apache < 2.2.0, apache-base
62 %webapp_register httpd %{_webapp}
64 %triggerun -- apache < 2.2.0, apache-base
65 %webapp_unregister httpd %{_webapp}
67 %triggerin -- lighttpd
68 %webapp_register lighttpd %{_webapp}
70 %triggerun -- lighttpd
71 %webapp_unregister lighttpd %{_webapp}
74 %defattr(644,root,root,755)
75 %doc ChangeLog Community.features NEWS README README.GGZ
76 %dir %attr(750,root,http) %{_sysconfdir}
77 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
78 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
79 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf
80 #%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.php