2 # - security http://security.gentoo.org/glsa/glsa-200506-04.xml
3 # - security http://security.gentoo.org/glsa/glsa-200507-02.xml
4 Summary: Personal publishing system
5 Summary(pl): Osobisty system publikacji
10 Group: Applications/Publishing
11 Source0: http://wordpress.org/latest.tar.gz
12 # Source0-md5: df6dc18a7a0d93fa6bb187eb48b41612
17 URL: http://wordpress.org/
19 Requires: php-gettext >= 5.0
20 Requires: php-mysql >= 5.0
21 Requires: php-pcre >= 5.0
22 Requires: php-xml >= 5.0
23 Requires: php-xmlrpc >= 5.0
26 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28 %define wordpressdir %{_datadir}/%{name}
31 WordPress is a state-of-the-art semantic personal publishing platform
32 with a focus on aesthetics, web standards, and usability. WordPress
33 was born out of a desire for an elegant, well-architectured personal
34 publishing system (also called blog or weblog) built on PHP and MySQL
35 and licensed under the GPL. It is the official successor of
36 b2/cafelog. WordPress is fresh software, but its roots and development
40 WordPress jest technologicznie dopracowan±, semantyczn±, osobist±
41 platform± do publikacji k³ad±c± nacisk na standardy WWW oraz
42 u¿yteczno¶æ. WordPress zosta³ stworzony w wyniku potrzeby
43 eleganckiego, dobrze zaprojektowanego, osobistego systemu publikacji
44 (nazywanego równie¿ blogiem czy weblogiem). Jest to system oparty
45 o PHP i MySQL oraz na licencji GPL. Jest oficjalnym nastêpc± b2/cafelog.
46 WordPress jest nowym oprogramowaniem, ale jego korzenie i rozwój
51 cp %{SOURCE1} %{SOURCE2} %{SOURCE3} .
54 rm -rf $RPM_BUILD_ROOT
55 install -d $RPM_BUILD_ROOT%{wordpressdir} $RPM_BUILD_ROOT%{_bindir} $RPM_BUILD_ROOT/etc/httpd
58 install %{SOURCE4} $RPM_BUILD_ROOT/etc/httpd/%{name}.conf
60 cp -R * $RPM_BUILD_ROOT%{wordpressdir}
61 rm -f $RPM_BUILD_ROOT%{wordpressdir}/readme.html
62 rm -f $RPM_BUILD_ROOT%{wordpressdir}/wp-setup.txt
63 ln -sf %{wordpressdir}/wp-setup.sh $RPM_BUILD_ROOT%{_bindir}/wp-setup
64 ln -sf %{wordpressdir}/wp-secure.sh $RPM_BUILD_ROOT%{_bindir}/wp-secure
67 rm -rf $RPM_BUILD_ROOT
70 if [ -f /etc/httpd/httpd.conf ] && ! grep -q "^Include.*%{name}.conf" /etc/httpd/httpd.conf; then
71 echo "Include /etc/httpd/%{name}.conf" >> /etc/httpd/httpd.conf
72 elif [ -d /etc/httpd/httpd.conf ]; then
73 ln -sf /etc/httpd/%{name}.conf /etc/httpd/httpd.conf/99_%{name}.conf
75 if [ -f /var/lock/subsys/httpd ]; then
76 /usr/sbin/apachectl restart 1>&2
78 if [ ! -f %{wordpressdir}/wp-config.php ]; then
79 touch %{wordpressdir}/wp-config.php
80 chmod 0640 %{wordpressdir}/wp-config.php
81 chown root:http %{wordpressdir}/wp-config.php
82 cat %{wordpressdir}/wp-config-sample.php > %{wordpressdir}/wp-config.php
83 echo "To finish your configuration DO NOT FORGET to:"
85 echo "0.) Create some MySQL database owned by some user"
86 echo "1.) Edit the file: %{wordpressdir}/wp-config.php"
87 echo "2.) Run a browser and visit: http://`hostname`/wordpress/wp-admin/install.php"
91 if [ "$1" = "0" ]; then
93 if [ -d /etc/httpd/httpd.conf ]; then
94 rm -f /etc/httpd/httpd.conf/99_%{name}.conf
96 grep -v "^Include.*%{name}.conf" /etc/httpd/httpd.conf > \
97 /etc/httpd/httpd.conf.tmp
98 mv -f /etc/httpd/httpd.conf.tmp /etc/httpd/httpd.conf
99 if [ -f /var/lock/subsys/httpd ]; then
100 /usr/sbin/apachectl restart 1>&2
106 %defattr(644,root,root,755)
107 %doc readme.html wp-setup.txt
108 %config(noreplace) %verify(not md5 mtime size) /etc/httpd/%{name}.conf
110 %dir %attr(750,root,http) %{wordpressdir}/wp-content
111 %dir %attr(750,root,http) %{wordpressdir}/wp-content/plugins
112 %dir %attr(750,root,http) %{wordpressdir}/wp-content/themes
113 %dir %attr(750,root,http) %{wordpressdir}/wp-content/themes/classic
114 %dir %attr(750,root,http) %{wordpressdir}/wp-content/themes/default
115 %attr(640,root,http) %{wordpressdir}/wp-content/plugins/*.php
116 %attr(640,root,http) %{wordpressdir}/wp-content/themes/classic/*
117 %attr(640,root,http) %{wordpressdir}/wp-content/themes/default/*.php
118 %attr(640,root,http) %{wordpressdir}/wp-content/themes/default/*.css
119 %attr(640,root,http) %{wordpressdir}/wp-content/themes/default/images/*
120 %{wordpressdir}/wp-admin
121 %{wordpressdir}/wp-images
122 %{wordpressdir}/wp-includes
123 %{wordpressdir}/*.php
124 %{wordpressdir}/wp-secure.sh
125 %{wordpressdir}/wp-setup.sh
126 %attr(755,root,root) %{_bindir}/wp-secure
127 %attr(755,root,root) %{_bindir}/wp-setup