]>
Commit | Line | Data |
---|---|---|
d73655e0 | 1 | Summary: PHP-based Wiki webapplication |
b9cde090 | 2 | Summary(pl.UTF-8): Aplikacja WWW Wiki oparta na PHP |
d73655e0 SP |
3 | Name: dokuwiki |
4 | Version: 20070626b | |
2d01b400 | 5 | Release: 0.16 |
d73655e0 SP |
6 | License: GPL v2 |
7 | Group: Applications/WWW | |
8 | Source0: http://www.splitbrain.org/_media/projects/dokuwiki/%{name}-2007-06-26b.tgz | |
9 | # Source0-md5: 84e9b5e8e617658bb0264aa3836f23b3 | |
99646b81 ER |
10 | Source1: %{name}-apache.conf |
11 | Source2: %{name}-lighttpd.conf | |
641b29cc ER |
12 | Patch0: %{name}-paths.patch |
13 | Patch1: %{name}-config.patch | |
dcd487f1 | 14 | URL: http://wiki.splitbrain.org/wiki:dokuwiki |
d73655e0 SP |
15 | BuildRequires: rpmbuild(macros) >= 1.268 |
16 | Requires: webapps | |
24a3d556 | 17 | Requires: webserver(alias) |
d73655e0 SP |
18 | Requires: webserver(php) >= 4.0.6 |
19 | BuildArch: noarch | |
20 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
21 | ||
22 | %define _webapps /etc/webapps | |
23 | %define _webapp %{name} | |
24 | %define _sysconfdir %{_webapps}/%{_webapp} | |
25 | %define _appdir %{_datadir}/%{_webapp} | |
881190a4 | 26 | %define _localstatedir /var/lib/%{name} |
d73655e0 SP |
27 | |
28 | %description | |
29 | DokuWiki is a standards compliant, simple to use Wiki, mainly aimed at | |
30 | creating documentation of any kind. It is targeted at developer teams, | |
31 | workgroups and small companies. It has a simple but powerful syntax | |
32 | which makes sure the datafiles remain readable outside the Wiki and | |
33 | eases the creation of structured texts. All data is stored in plain | |
b9cde090 JB |
34 | text files - no database is required. |
35 | ||
36 | %description -l pl.UTF-8 | |
37 | DokuWiki to zgodne ze standardami i proste w użyciu Wiki, przeznaczone | |
38 | głównie do tworzenia dokumentów wszelkiego rodzaju. Jest przeznaczone | |
39 | dla zespołów programistów, grup roboczych i małych firm. Ma prostą, | |
40 | ale mającą duże możliwości składnię, dzięki której pliki danych | |
41 | pozostają czytelne poza Wiki, a także ułatwiającą tworzenie tekstów | |
42 | strukturalnych. Wszystkie dane są przechowywane w plikach tekstowych - | |
43 | nie jest wymagana baza danych. | |
d73655e0 | 44 | |
641b29cc ER |
45 | %package setup |
46 | Summary: Dokuwiki setup package | |
47 | Summary(pl.UTF-8): Pakiet do wstępnej konfiguracji Dokuwiki | |
48 | Group: Applications/WWW | |
49 | Requires: %{name} = %{version}-%{release} | |
50 | ||
51 | %description setup | |
52 | Install this package to configure initial Dokuwiki installation. You | |
53 | should uninstall this package when you're done, as it considered | |
54 | insecure to keep the setup files in place. | |
55 | ||
56 | %description setup -l pl.UTF-8 | |
57 | Ten pakiet należy zainstalować w celu wstępnej konfiguracji Dokuwiki | |
58 | po pierwszej instalacji. Potem należy go odinstalować, jako że | |
59 | pozostawienie plików instalacyjnych mogłoby być niebezpieczne. | |
60 | ||
d73655e0 SP |
61 | %prep |
62 | %setup -q -n %{name}-2007-06-26b | |
641b29cc ER |
63 | %patch0 -p1 |
64 | %patch1 -p1 | |
d73655e0 | 65 | |
2d01b400 ER |
66 | # safe file |
67 | mv conf/words.aspell{.dist,} | |
68 | ||
d73655e0 SP |
69 | %install |
70 | rm -rf $RPM_BUILD_ROOT | |
641b29cc | 71 | install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_localstatedir},%{_appdir}/{bin,inc,lib}} |
d73655e0 SP |
72 | |
73 | cp -a *.php $RPM_BUILD_ROOT%{_appdir} | |
641b29cc ER |
74 | cp -a bin/* $RPM_BUILD_ROOT%{_appdir}/bin |
75 | cp -a inc/* $RPM_BUILD_ROOT%{_appdir}/inc | |
76 | cp -a lib/* $RPM_BUILD_ROOT%{_appdir}/lib | |
881190a4 ER |
77 | cp -a conf/* $RPM_BUILD_ROOT%{_sysconfdir} |
78 | cp -a data/* $RPM_BUILD_ROOT%{_localstatedir} | |
99646b81 ER |
79 | install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf |
80 | install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf | |
81 | install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf | |
d73655e0 | 82 | |
2d01b400 ER |
83 | ln $RPM_BUILD_ROOT%{_appdir}/lib/images/interwiki/{dokubug,issue}.gif |
84 | ln $RPM_BUILD_ROOT%{_appdir}/lib/images/interwiki/{dokubug,bug}.gif | |
85 | ||
d73655e0 SP |
86 | %clean |
87 | rm -rf $RPM_BUILD_ROOT | |
88 | ||
641b29cc ER |
89 | %post setup |
90 | chmod 770 %{_sysconfdir} | |
91 | chmod 660 %{_sysconfdir}/dokuwiki.php | |
92 | ||
93 | %postun setup | |
94 | if [ "$1" = "0" ]; then | |
95 | chmod 750 %{_sysconfdir} | |
96 | chmod 640 %{_sysconfdir}/dokuwiki.php | |
97 | fi | |
98 | ||
d73655e0 SP |
99 | %triggerin -- apache1 < 1.3.37-3, apache1-base |
100 | %webapp_register apache %{_webapp} | |
101 | ||
102 | %triggerun -- apache1 < 1.3.37-3, apache1-base | |
103 | %webapp_unregister apache %{_webapp} | |
104 | ||
105 | %triggerin -- apache < 2.2.0, apache-base | |
106 | %webapp_register httpd %{_webapp} | |
107 | ||
108 | %triggerun -- apache < 2.2.0, apache-base | |
109 | %webapp_unregister httpd %{_webapp} | |
110 | ||
99646b81 ER |
111 | %triggerin -- lighttpd |
112 | %webapp_register lighttpd %{_webapp} | |
113 | ||
114 | %triggerun -- lighttpd | |
115 | %webapp_unregister lighttpd %{_webapp} | |
116 | ||
881190a4 ER |
117 | %pretrans |
118 | if [ -d %{_appdir}/data -a ! -L %{_appdir}/data ]; then | |
119 | mv -f %{_appdir}/data/* %{_localstatedir} | |
120 | rm -rf %{_appdir}/data | |
121 | fi | |
122 | if [ -d %{_appdir}/conf -a ! -L %{_appdir}/conf ]; then | |
123 | mv -f %{_appdir}/conf/* %{_sysconfdir} | |
124 | rm -rf %{_appdir}/conf | |
125 | fi | |
126 | exit 0 | |
127 | ||
d73655e0 SP |
128 | %files |
129 | %defattr(644,root,root,755) | |
881190a4 | 130 | %doc README VERSION |
d73655e0 SP |
131 | %dir %attr(750,root,http) %{_sysconfdir} |
132 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf | |
133 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf | |
99646b81 ER |
134 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf |
135 | ||
881190a4 | 136 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/acronyms.conf |
881190a4 | 137 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/entities.conf |
881190a4 ER |
138 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mediameta.php |
139 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mime.conf | |
140 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/msg | |
881190a4 | 141 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/smileys.conf |
2d01b400 ER |
142 | %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/words.aspell |
143 | ||
144 | # use local.php for local changes | |
145 | %attr(640,root,http) %verify(not md5 mtime size) %{_sysconfdir}/dokuwiki.php | |
146 | # use interwiki.local.conf for local changes | |
147 | %attr(640,root,http) %verify(not md5 mtime size) %{_sysconfdir}/interwiki.conf | |
b9fff555 ER |
148 | |
149 | %attr(640,root,http) %{_sysconfdir}/mysql.conf.php.example | |
150 | %attr(640,root,http) %{_sysconfdir}/acl.auth.php.dist | |
151 | %attr(640,root,http) %{_sysconfdir}/wordblock.conf | |
152 | %attr(640,root,http) %{_sysconfdir}/local.php.dist | |
153 | %attr(640,root,http) %{_sysconfdir}/users.auth.php.dist | |
881190a4 | 154 | |
641b29cc ER |
155 | %dir %{_appdir} |
156 | %dir %{_appdir}/bin | |
157 | %attr(755,root,root) %{_appdir}/bin/dwpage.php | |
158 | %attr(755,root,root) %{_appdir}/bin/indexer.php | |
159 | %attr(755,root,root) %{_appdir}/bin/wantedpages.php | |
160 | %{_appdir}/inc | |
161 | %{_appdir}/lib | |
162 | %{_appdir}/doku.php | |
163 | %{_appdir}/feed.php | |
164 | %{_appdir}/index.php | |
881190a4 ER |
165 | |
166 | %dir %attr(770,root,http) %{_localstatedir} | |
167 | %dir %attr(770,root,http) %{_localstatedir}/attic | |
168 | %dir %attr(770,root,http) %{_localstatedir}/cache | |
169 | %dir %attr(770,root,http) %{_localstatedir}/index | |
170 | %dir %attr(770,root,http) %{_localstatedir}/locks | |
171 | %dir %attr(770,root,http) %{_localstatedir}/media | |
172 | %dir %attr(770,root,http) %{_localstatedir}/media/wiki | |
173 | %dir %attr(770,root,http) %{_localstatedir}/meta | |
174 | %dir %attr(770,root,http) %{_localstatedir}/pages | |
175 | %dir %attr(770,root,http) %{_localstatedir}/pages/playground | |
176 | %dir %attr(770,root,http) %{_localstatedir}/pages/wiki | |
b9fff555 ER |
177 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/attic/_dummy |
178 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/cache/_dummy | |
179 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/index/_dummy | |
180 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/locks/_dummy | |
181 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/media/wiki/dokuwiki-128.png | |
182 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/meta/_dummy | |
183 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/pages/playground/playground.txt | |
184 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/pages/wiki/dokuwiki.txt | |
185 | %attr(660,root,http) %config(noreplace,missingok) %verify(not md5 mtime size) %{_localstatedir}/pages/wiki/syntax.txt | |
641b29cc ER |
186 | |
187 | %files setup | |
188 | %defattr(644,root,root,755) | |
189 | %{_appdir}/install.php |