1 Summary: A feature-rich PHP discussion board
2 Summary(pl): Forum dyskusyjne o du¿ych mo¿liwo¶ciach
7 Group: Applications/WWW
8 #Source0: http://dl.sourceforge.net/phpbb/%{name}-%{version}.tar.bz2
9 Source0: http://dl.sourceforge.net/phpbb-php5mod/20143.tar.gz
10 # Source0-md5: aedb16819029c7e1f6cd625d566685e4
11 Source1: http://dl.sourceforge.net/phpbb/lang_polish.tar.gz
12 # Source1-md5: db020ef788d4bd50ce04014964e3e043
13 Source2: http://dl.sourceforge.net/phpbb/subSilver_polish.tar.gz
14 # Source2-md5: 9367f7a761aef3795ffa296b413136b4
15 Source3: http://dl.sourceforge.net/phpbb/lang_german.tar.gz
16 # Source3-md5: afc686072978b896e18fa211210c3b13
17 Source4: http://dl.sourceforge.net/phpbb/subSilver_german.tar.gz
18 # Source4-md5: 8340f310ee4892f3e19da3e000fdb708
19 Source5: http://dl.sourceforge.net/phpbb/lang_french.tar.gz
20 # Source5-md5: c81f843d4adf0a086efef590074478e6
21 Source6: http://dl.sourceforge.net/phpbb/subSilver_french.tar.gz
22 # Source6-md5: 419157eb144fa81b7464a5f2edeea434
25 URL: http://www.phpbb.com/
29 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31 %define _phpdir %{_datadir}/%{name}
32 %define _confdir %{_sysconfdir}/%{name}
33 %define _avatardir /var/lib/%{name}/avatars
36 phpBB is a UBB-style dissussion board written in PHP backended by a
37 MySQL database. It includes features such as posting/replying/editing
38 messages, private messages, private forums, user and anonymous
39 posting, robust theming, user ranking by posts or by special, admin
40 definable, ranks, and much more.
43 phpBB jest forum dyskusyjnym w stylu UBB napisanym w PHP z u¿yciem
44 bazy danych MySQL. Ma mo¿liwo¶ci takie jak: wysy³anie, odpisywanie,
45 edycja wiadomo¶ci, prywatne wiadomo¶ci, prywatne fora, wysy³anie jako
46 u¿ytkownik i anonimowe, bogaty wybór motywów, ranking u¿ytkowników
47 wed³ug ich wiadomo¶ci lub specjalne, definiowane przez administratora,
48 rankingi i wiele innych.
51 Summary: A feature-rich PHP discussion board - installer
52 Summary(pl): Forum dyskusyjne o du¿ych mo¿liwo¶ciach - instalator
53 Group: Applications/Databases/Interfaces
57 Package needed for %{name} forum instalation.
59 %description install -l pl
60 Pakiet potrzebny do instalacji forum %{name}.
66 rm -rf $RPM_BUILD_ROOT
67 install -d $RPM_BUILD_ROOT%{_phpdir}/{admin,db,images,includes,install/schemas,language,templates} \
68 $RPM_BUILD_ROOT{%{_confdir},/etc/httpd} \
69 $RPM_BUILD_ROOT%{_avatardir}
71 install *.{php,inc} $RPM_BUILD_ROOT%{_phpdir}
72 install admin/*.php $RPM_BUILD_ROOT%{_phpdir}/admin
73 install db/*.php $RPM_BUILD_ROOT%{_phpdir}/db
74 install includes/*.php $RPM_BUILD_ROOT%{_phpdir}/includes
75 install install/*.php $RPM_BUILD_ROOT%{_phpdir}/install
76 install install/schemas/*.sql $RPM_BUILD_ROOT%{_phpdir}/install/schemas
78 cp -R images/* $RPM_BUILD_ROOT%{_phpdir}/images
79 cp -R images/avatars/* $RPM_BUILD_ROOT%{_avatardir}
80 cp -R language/* $RPM_BUILD_ROOT%{_phpdir}/language
81 cp -R templates/* $RPM_BUILD_ROOT%{_phpdir}/templates
82 rm -rf $RPM_BUILD_ROOT%{_phpdir}/images/avatars
83 ln -sf %{_avatardir} $RPM_BUILD_ROOT%{_phpdir}/images/avatars
85 install config.php $RPM_BUILD_ROOT%{_confdir}
86 install %{SOURCE8} $RPM_BUILD_ROOT%{_confdir}/favicon.ico
87 touch $RPM_BUILD_ROOT%{_confdir}/robots.txt
88 ln -sf %{_confdir}/config.php $RPM_BUILD_ROOT%{_phpdir}/config.php
89 ln -sf %{_confdir}/favicon.ico $RPM_BUILD_ROOT%{_phpdir}/favicon.ico
90 ln -sf %{_confdir}/robots.txt $RPM_BUILD_ROOT%{_phpdir}/robots.txt
92 tar zxf %{SOURCE1} -C $RPM_BUILD_ROOT%{_phpdir}/language/
93 tar zxf %{SOURCE2} -C $RPM_BUILD_ROOT%{_phpdir}/templates/
95 tar zxf %{SOURCE3} -C $RPM_BUILD_ROOT%{_phpdir}/language/
96 tar zxf %{SOURCE4} -C $RPM_BUILD_ROOT%{_phpdir}/templates/
98 tar zxf %{SOURCE5} -C $RPM_BUILD_ROOT%{_phpdir}/language/
99 tar zxf %{SOURCE6} -C $RPM_BUILD_ROOT%{_phpdir}/templates/
101 install %{SOURCE7} $RPM_BUILD_ROOT/etc/httpd/%{name}.conf
104 rm -rf $RPM_BUILD_ROOT
107 if [ "$1" = "1" ]; then
108 if [ -f /etc/httpd/httpd.conf ] && ! grep -q "^Include.*%{name}.conf" /etc/httpd/httpd.conf; then
109 echo "Include /etc/httpd/%{name}.conf" >> /etc/httpd/httpd.conf
110 elif [ -d /etc/httpd/httpd.conf ]; then
111 ln -sf /etc/httpd/%{name}.conf /etc/httpd/httpd.conf/99_%{name}.conf
113 if [ -f /var/lock/subsys/httpd ]; then
114 /usr/sbin/apachectl graceful 1>&2
119 echo "For instalation: http://<your.site.address>/<path>/install/install.php"
120 echo "For upgrade: http://<your.site.address>/<path>/install/upgrade.php"
122 echo "Remember to uninstall %{name}-install after initiation/upgrade of %{name}!!"
125 if [ "$1" = "0" ]; then
127 if [ -d /etc/httpd/httpd.conf ]; then
128 rm -f /etc/httpd/httpd.conf/99_%{name}.conf
130 grep -v "^Include.*%{name}.conf" /etc/httpd/httpd.conf > \
131 /etc/httpd/httpd.conf.tmp
132 mv -f /etc/httpd/httpd.conf.tmp /etc/httpd/httpd.conf
133 if [ -f /var/lock/subsys/httpd ]; then
134 /usr/sbin/apachectl graceful 1>&2
139 %triggerpostun -- %{name} < %{version}
140 echo "You have to install %{name}-install package to prepare upgrade!!!"
141 echo "For upgrade: http://<your.site.address>/<path>/install/upgrade.php"
143 %triggerpostun -- %{name} <= 2.0.10-1
144 if [ -f /home/services/httpd/html/phpBB/config.php.rpmsave ]; then
145 mv -f /home/services/httpd/html/phpBB/config.php.rpmsave /etc/phpBB/config.php
147 if [ -f /home/httpd/html/phpBB/config.php.rpmsave ]; then
148 mv -f /home/httpd/html/phpBB/config.php.rpmsave /etc/phpBB/config.php
151 for i in `grep -lr "/home/\(services/\)*httpd/html/phpBB" /etc/httpd/*`; do
153 %{__perl} -pi -e "s#/home/httpd/html/phpBB#%{_phpdir}#g" $i
154 %{__perl} -pi -e "s#/home/services/httpd/html/phpBB#%{_phpdir}#g" $i
155 echo "File changed by trigger: $i (backup: $i.backup)"
157 if [ -f /var/lock/subsys/httpd ]; then
158 /usr/sbin/apachectl graceful 1>&2
162 %defattr(644,root,root,755)
164 %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_confdir}/*
165 %config(noreplace) %verify(not md5 mtime size) /etc/httpd/%{name}.conf
167 %attr(755,root,http) %dir %{_phpdir}
168 %attr(640,root,http) %{_phpdir}/[!c]*.php
169 %attr(640,root,http) %{_phpdir}/common.php
170 %attr(640,root,http) %{_phpdir}/*.inc
171 %attr(750,root,http) %dir %{_phpdir}/admin
172 %attr(750,root,http) %dir %{_phpdir}/db
173 %attr(750,root,http) %dir %{_phpdir}/images
174 %attr(640,root,http) %{_phpdir}/images/*.gif
175 %attr(640,root,http) %{_phpdir}/images/index.htm
176 %attr(750,root,http) %dir %{_phpdir}/images/smiles
177 %attr(710,root,http) %dir /var/lib/%{name}
178 %attr(1770,root,http) %dir %{_avatardir}
179 %attr(750,root,http) %dir %{_phpdir}/includes
180 %attr(640,root,http) %config(noreplace) %{_phpdir}/config.php
181 %attr(640,root,http) %config(noreplace) %{_phpdir}/favicon.ico
182 %attr(640,root,http) %config(noreplace) %{_phpdir}/robots.txt
185 %{_phpdir}/images/smiles/*
186 %{_phpdir}/images/avatars
188 %{_phpdir}/includes/*
189 %{_phpdir}/templates/index.htm
190 %attr(750,root,http) %dir %{_phpdir}/templates
191 %attr(750,root,http) %dir %{_phpdir}/templates/subSilver
192 %attr(750,root,http) %dir %{_phpdir}/templates/subSilver/admin
193 %attr(640,root,http) %{_phpdir}/templates/subSilver/admin/*
194 %attr(640,root,http) %{_phpdir}/templates/subSilver/*.*
195 %attr(750,root,http) %dir %{_phpdir}/templates/subSilver/images
196 %attr(640,root,http) %{_phpdir}/templates/subSilver/images/*.*
197 %attr(750,root,http) %dir %{_phpdir}/language
198 %attr(640,root,http) %{_phpdir}/language/*.htm
200 %lang(en) %{_phpdir}/language/lang_english
201 %lang(en) %{_phpdir}/templates/subSilver/images/lang_english
203 %lang(pl) %{_phpdir}/language/lang_polish
204 %lang(pl) %{_phpdir}/templates/subSilver/images/lang_polish
206 %lang(de) %{_phpdir}/language/lang_german
207 %lang(de) %{_phpdir}/templates/subSilver/images/lang_german
209 %lang(fr) %{_phpdir}/language/lang_french
210 %lang(fr) %{_phpdir}/templates/subSilver/images/lang_french
213 %defattr(644,root,root,755)
214 %doc install/schemas/*.zip
215 %attr(750,root,http) %dir %{_phpdir}/install
216 %attr(640,root,http) %{_phpdir}/install/*.php
217 %attr(750,root,http) %dir %{_phpdir}/install/schemas
218 %attr(640,root,http) %{_phpdir}/install/schemas/*.sql