]>
Commit | Line | Data |
---|---|---|
d99462c6 | 1 | # TODO: |
2 | # - package docs? | |
3 | # - test lighttpd config | |
8b717ae2 | 4 | Summary: CalDAV Server |
5 | Summary(pl.UTF-8): Serwer CalDAV | |
d99462c6 | 6 | Name: davical |
7 | Version: 0.9.9.2 | |
915bb6fd | 8 | Release: 0.5 |
d99462c6 | 9 | License: GPL v2 |
10 | Group: Applications | |
888f9340 | 11 | Source0: http://downloads.sourceforge.net/project/rscds/davical/0.9.9.2/%{name}-%{version}.tar.gz |
d99462c6 | 12 | # Source0-md5: c35047bab51ca86729cba94f81988db8 |
13 | Source1: %{name}.conf | |
14 | Source2: %{name}-lighttpd.conf | |
54a75c0e | 15 | Patch0: %{name}-php_data_dir.patch |
915bb6fd | 16 | Patch1: %{name}-conf_path.patch |
d99462c6 | 17 | BuildRequires: php-awl |
18 | BuildRequires: php-pear-PhpDocumentor | |
19 | Requires: php-awl | |
915bb6fd | 20 | Requires: php-pcre |
21 | Requires: php-pdo-pgsql | |
d99462c6 | 22 | Requires: php-session |
23 | Requires: webapps | |
24 | Requires: webserver(access) | |
25 | Requires: webserver(alias) | |
e5afb108 | 26 | Requires: webserver(php) |
d99462c6 | 27 | Suggests: webserver(indexfile) |
d99462c6 | 28 | BuildArch: noarch |
29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
30 | ||
31 | %define _appdir %{_datadir}/%{name} | |
32 | %define _webapps /etc/webapps | |
33 | ||
34 | %description | |
888f9340 | 35 | The DAViCal CalDAV Server is a repository for calendar, todo and |
36 | journal entries to be accessed via CalDAV clients such as Evolution, | |
37 | Sunbird, Lightning, Mulberry, Chandler, Apple iCal or the iPhone. | |
d99462c6 | 38 | |
39 | %prep | |
40 | %setup -q | |
41 | ||
54a75c0e | 42 | %patch0 -p1 |
915bb6fd | 43 | %patch1 -p1 |
54a75c0e | 44 | |
d99462c6 | 45 | sed -i 's#^AWL_LOCATION="\.\./awl"$#AWL_LOCATION=%{php_data_dir}/awl#' scripts/po/rebuild-translations.sh |
46 | sed -i /^================================================================/q COPYING | |
47 | ||
48 | %build | |
49 | scripts/build-always.sh < inc/always.php.in > htdocs/always.php | |
50 | phpdoc -c docs/api/phpdoc.ini | |
51 | scripts/po/rebuild-translations.sh | |
52 | ||
53 | %install | |
54 | rm -rf $RPM_BUILD_ROOT | |
55 | install -d $RPM_BUILD_ROOT%{_webapps}/%{name} | |
56 | install -d $RPM_BUILD_ROOT%{_appdir} | |
57 | ||
58 | cp -a config/example-config.php $RPM_BUILD_ROOT%{_webapps}/%{name}/config.php | |
59 | cp -a config/example-administration.yml $RPM_BUILD_ROOT%{_webapps}/%{name}/administration.yml | |
54a75c0e | 60 | cp -a inc $RPM_BUILD_ROOT%{_appdir} |
d99462c6 | 61 | cp -a htdocs $RPM_BUILD_ROOT%{_appdir} |
62 | cp -a dba $RPM_BUILD_ROOT%{_appdir} | |
63 | ||
64 | install %{SOURCE1} $RPM_BUILD_ROOT%{_webapps}/%{name}/httpd.conf | |
65 | install %{SOURCE1} $RPM_BUILD_ROOT%{_webapps}/%{name}/apache.conf | |
66 | install %{SOURCE2} $RPM_BUILD_ROOT%{_webapps}/%{name}/lighttpd.conf | |
67 | ||
68 | cp -a locale $RPM_BUILD_ROOT%{_datadir} | |
69 | %find_lang %{name} | |
70 | ||
71 | %clean | |
72 | rm -rf $RPM_BUILD_ROOT | |
73 | ||
74 | %triggerin -- apache1 < 1.3.37-3, apache1-base | |
75 | %webapp_register apache %{name} | |
76 | ||
77 | %triggerun -- apache1 < 1.3.37-3, apache1-base | |
78 | %webapp_unregister apache %{name} | |
79 | ||
80 | %triggerin -- apache < 2.2.0, apache-base | |
81 | %webapp_register httpd %{name} | |
82 | ||
83 | %triggerun -- apache < 2.2.0, apache-base | |
84 | %webapp_unregister httpd %{name} | |
85 | ||
86 | %triggerin -- lighttpd | |
87 | %webapp_register lighttpd %{name} | |
88 | ||
89 | %triggerun -- lighttpd | |
90 | %webapp_unregister lighttpd %{name} | |
91 | ||
92 | %files -f %{name}.lang | |
93 | %defattr(644,root,root,755) | |
94 | %doc COPYING ChangeLog CREDITS README TODO | |
95 | %dir %attr(750,root,http) %{_sysconfdir}/webapps/%{name} | |
96 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_webapps}/%{name}/config.php | |
97 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_webapps}/%{name}/administration.yml | |
98 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webapps}/%{name}/apache.conf | |
99 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webapps}/%{name}/httpd.conf | |
100 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webapps}/%{name}/lighttpd.conf | |
101 | %dir %{_appdir} | |
d99462c6 | 102 | %{_appdir}/dba |
54a75c0e | 103 | %{_appdir}/htdocs |
104 | %{_appdir}/inc |