2 # - put config files to %{_sysconfdir}!
3 Summary: Personal publishing system
4 Summary(pl.UTF-8): Osobisty system publikacji
9 Group: Applications/Publishing
10 Source0: http://wordpress.org/latest.tar.gz
11 # Source0-md5: e377fa9389d1a06a700ac349582f498c
16 URL: http://wordpress.org/
17 Requires: php(gettext)
23 Requires: webserver(php) >= 5.0
25 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27 %define _appdir %{_datadir}/%{name}
28 %define _webapps /etc/webapps
29 %define _webapp %{name}
30 %define _sysconfdir %{_webapps}/%{_webapp}
33 WordPress is a state-of-the-art semantic personal publishing platform
34 with a focus on aesthetics, web standards, and usability. WordPress
35 was born out of a desire for an elegant, well-architectured personal
36 publishing system (also called blog or weblog) built on PHP and MySQL
37 and licensed under the GPL. It is the official successor of
38 b2/cafelog. WordPress is fresh software, but its roots and development
41 %description -l pl.UTF-8
42 WordPress jest technologicznie dopracowaną, semantyczną, osobistą
43 platformą do publikacji kładącą nacisk na standardy WWW oraz
44 użyteczność. WordPress został stworzony w wyniku potrzeby
45 eleganckiego, dobrze zaprojektowanego, osobistego systemu publikacji
46 (nazywanego również blogiem czy weblogiem). Jest to system oparty o
47 PHP i MySQL oraz na licencji GPL. Jest oficjalnym następcą b2/cafelog.
48 WordPress jest nowym oprogramowaniem, ale jego korzenie i rozwój
53 cp %{SOURCE1} %{SOURCE2} %{SOURCE3} .
57 rm -rf $RPM_BUILD_ROOT
58 install -d $RPM_BUILD_ROOT{%{_appdir},%{_bindir},%{_sysconfdir}}
60 cp -R * $RPM_BUILD_ROOT%{_appdir}
61 rm -f $RPM_BUILD_ROOT%{_appdir}/readme.html
62 rm -f $RPM_BUILD_ROOT%{_appdir}/wp-setup.txt
63 ln -sf %{_appdir}/wp-setup.sh $RPM_BUILD_ROOT%{_bindir}/wp-setup
64 ln -sf %{_appdir}/wp-secure.sh $RPM_BUILD_ROOT%{_bindir}/wp-secure
66 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
67 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
70 rm -rf $RPM_BUILD_ROOT
73 if [ ! -f %{_appdir}/wp-config.php ]; then
74 install -uroot -ghttp -m640 %{_appdir}/wp-config-sample.php > %{_appdir}/wp-config.php
76 %banner -e %{name} <<-EOF
77 To finish your configuration DO NOT FORGET to:
79 1) Create some MySQL database owned by some user
80 2) Edit the file: %{_appdir}/wp-config.php
81 3) Run a browser and visit: http://`hostname`/wordpress/wp-admin/install.php
85 %triggerin -- apache1 < 1.3.37-3, apache1-base
86 %webapp_register apache %{_webapp}
88 %triggerun -- apache1 < 1.3.37-3, apache1-base
89 %webapp_unregister apache %{_webapp}
91 %triggerin -- apache < 2.2.0, apache-base
92 %webapp_register httpd %{_webapp}
94 %triggerun -- apache < 2.2.0, apache-base
95 %webapp_unregister httpd %{_webapp}
98 %defattr(644,root,root,755)
99 %doc readme.html wp-setup.txt
100 %dir %attr(750,root,http) %{_sysconfdir}
101 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
102 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
105 %dir %attr(750,root,http) %{_appdir}/wp-content
106 %dir %attr(750,root,http) %{_appdir}/wp-content/plugins
107 %dir %attr(750,root,http) %{_appdir}/wp-content/themes
108 %dir %attr(750,root,http) %{_appdir}/wp-content/themes/classic
109 %dir %attr(750,root,http) %{_appdir}/wp-content/themes/default
110 %dir %attr(750,root,http) %{_appdir}/wp-content/themes/default/images
111 %attr(640,root,http) %{_appdir}/wp-content/plugins/*.php
112 %attr(640,root,http) %{_appdir}/wp-content/plugins/akismet
113 %attr(640,root,http) %{_appdir}/wp-content/themes/classic/*
114 %attr(640,root,http) %{_appdir}/wp-content/themes/default/*.php
115 %attr(640,root,http) %{_appdir}/wp-content/themes/default/*.css
116 %attr(640,root,http) %{_appdir}/wp-content/themes/default/images/*
118 %{_appdir}/wp-includes
120 %{_appdir}/wp-secure.sh
121 %{_appdir}/wp-setup.sh
122 %attr(755,root,root) %{_bindir}/wp-secure
123 %attr(755,root,root) %{_bindir}/wp-setup