# # spec file for package wordpress # # Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # # apache macros %if 0%{?suse_version} %define apxs /usr/local/apache2/bin/apxs %define ap_libexecdir %(%{apxs} -q LIBEXECDIR) %define ap_sysconfdir %(%{apxs} -q SYSCONFDIR) %define ap_includedir %(%{apxs} -q INCLUDEDIR) %define ap_serverroot /var/lib/wordpress %else # Fedora, arrgghhh %define apxs %{_sbindir}/apxs %define ap_libexecdir %(%{apxs} -q LIBEXECDIR) %define ap_sysconfdir %(%{apxs} -q PREFIX) %define ap_includedir %(%{apxs} -q INCLUDEDIR) %define ap_serverroot /srv/www %endif %define language_date 20151205 %define language_date_formal 20151206 %define themes_date 20150126 %if 0%{?suse_version} >= 1210 %define has_systemd 1 %endif Name: wordpress Summary: World largest Bloging tool License: GPL-2.0 Group: Productivity/Networking/Web/Frontends Version: 4.4.2 Release: 1.1 Url: http://wordpress.org Source0: http://wordpress.org/%{name}-%{version}.tar.gz Source1: %{name}-lang-de_DE-%{language_date}.tar.gz Source2: %{name}-lang-de_DE_formal-%{language_date_formal}.tar.gz Source3: %{name}-plugins.tar.bz2 Source4: %{name}-themes-%{themes_date}.tar.gz Source10: README.SUSE Source11: %{name}.httpd Source20: %{name}.rpmlintrc # prepare wp-config for unique phrase Patch1: %{name}-sysconfdir.patch Patch2: %{name}-disable-core-auto-updates.patch BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-build %if 0%{?suse_version} BuildRequires: apache2-devel %else BuildRequires: httpd-devel %endif %if 0%{?suse_version} > 1100 BuildRequires: fdupes %endif %if 0%{?have_systemd} BuildRequires: systemd %{?systemd_requires} %else PreReq: %insserv_prereq %endif Requires: %{name}-themes = %{version}-%{release} Requires: php5-dom Requires: php5-mysql # php5-curl and php5-zlib are used to download themes Recommends: php5-curl Recommends: php5-zlib %if 0%{?suse_version} Recommends: apache2 Recommends: apache2-mod_php5 %else # These are Redhat identifiers Recommends: httpd Recommends: mod_php_any %endif %description WordPress started in 2003 with a single bit of code to enhance the typography of everyday writing and with fewer users than you can count on your fingers and toes. Since then it has grown to be the largest self-hosted blogging tool in the world, used on hundreds of thousands of sites and seen by tens of millions of people every day. %package lang-de_DE Summary: German language files for wordpress Group: Productivity/Networking/Web/Frontends Requires: %{name} = %{version}-%{release} Conflicts: lang-de_DE_formal %description lang-de_DE This package includes german language files for wordpress %package lang-de_DE_formal Summary: German language files for wordpress Group: Productivity/Networking/Web/Frontends Requires: %{name} = %{version}-%{release} Conflicts: lang-de_DE %description lang-de_DE_formal This package includes german language files for wordpress %package plugins Summary: Plugins for wordpress Group: Productivity/Networking/Web/Frontends Requires: %{name} = %{version}-%{release} %description plugins This package includes plugins for wordpress: custom-post-widget 1.9.5 %package themes Summary: Original Themes for wordpress Group: Productivity/Networking/Web/Frontends Requires: %{name} = %{version}-%{release} %description themes This package includes original themes for wordpress %package themes-collections Summary: Some other Themes for wordpress Group: Productivity/Networking/Web/Frontends Requires: %{name} = %{version}-%{release} %description themes-collections This package includes some other themes for wordpress %prep %setup -n %{name} -a 1 -a 2 -a 3 -a 4 # add README.SUSE %{__cp} -a %{S:10} . # create wp-config %patch1 -p1 %patch2 -p1 %{__cp} -a wp-config-sample.php wp-config.php ## rpmlint # wrong-file-end-of-line-encoding %{__perl} -p -i -e "s|\r\n|\n|" license.txt # wrong-script-end-of-line-encoding #%%{__perl} -p -i -e "s|\r\n|\n|" wp-content/themes/layers/* %{__perl} -p -i -e "s|\r\n|\n|" wp-config.php # script-without-shebang (has executable bits set) find ./ -type f -exec %{__chmod} 0644 {} \; # unneeded htaccess-file, it is in wordpress.httpd %{__rm} wp-content/plugins/akismet/.htaccess %build # no need for build %install %{__install} -d %{buildroot}%{_sysconfdir}/%{name} %{__install} -d %{buildroot}%{ap_serverroot}/%{name} %{__cp} -av * %{buildroot}%{ap_serverroot}/%{name}/ # install apache conf %{__install} -D -m0644 %{S:11} %{buildroot}%{ap_sysconfdir}/conf.d/%{name}.conf %{__sed} -i -e "s|@AP_SROOT@|%{ap_serverroot}|" \ %{buildroot}%{ap_sysconfdir}/conf.d/%{name}.conf # move wp-config to /etc/wordpress %{__mv} %{buildroot}%{ap_serverroot}/%{name}/wp-config.php %{buildroot}%{_sysconfdir}/%{name}/wp-config.php # some cleanup %{__rm} %{buildroot}%{ap_serverroot}/%{name}/{license.txt,readme.html} ## rpmlint %if 0%{?suse_version} > 1100 # files duplicates %fdupes %{buildroot}%{ap_serverroot}/%{name} %endif %post %{__chown} -R wwwrun:root %{ap_serverroot}/%{name} %{__chown} -R wwwrun:root %{_sysconfdir}/%{name} %if 0%{?has_systemd} %service_add_post apache2.service %else %restart_on_update apache2 %endif %postun %if 0%{?has_systemd} %service_del_postun apache2.service %else %restart_on_update apache2 %endif %clean %{__rm} -rf %{buildroot} %files %defattr(-,root,root) %doc license.txt readme.html README.SUSE %config(noreplace) %{ap_sysconfdir}/conf.d/%{name}.conf %config(noreplace) %{_sysconfdir}/%{name}/wp-config.php %dir %attr(750,wwwrun,root) %{_sysconfdir}/%{name} %{ap_serverroot}/wordpress # exclude language de_DE %exclude %{ap_serverroot}/wordpress/wp-content/languages/*de_DE* %exclude %{ap_serverroot}/wordpress/wp-content/languages/themes/*de_DE* %exclude %{ap_serverroot}/wordpress/wp-content/languages/plugins/*de_DE* # exlude plugins %exclude %{ap_serverroot}/wordpress/wp-content/plugins/* # exclude themes %exclude %{ap_serverroot}/wordpress/wp-content/themes/* # only wp-content for upgrade %defattr(-,wwwrun,root) %{ap_serverroot}/wordpress/wp-content/ %files lang-de_DE %defattr(-,wwwrun,root) %{ap_serverroot}/wordpress/wp-content/languages/*de_DE.* %{ap_serverroot}/wordpress/wp-content/languages/themes/*de_DE.* %{ap_serverroot}/wordpress/wp-content/languages/plugins/*de_DE.* %files lang-de_DE_formal %defattr(-,wwwrun,root) %{ap_serverroot}/wordpress/wp-content/languages/*de_DE_formal.* %{ap_serverroot}/wordpress/wp-content/languages/themes/*de_DE_formal.* %{ap_serverroot}/wordpress/wp-content/languages/plugins/*de_DE_formal.* %files plugins %defattr(-,wwwrun,root) %{ap_serverroot}/wordpress/wp-content/plugins/* %files themes %defattr(-,wwwrun,root) %{ap_serverroot}/wordpress/wp-content/themes/index.php %{ap_serverroot}/wordpress/wp-content/themes/twentyfourteen %{ap_serverroot}/wordpress/wp-content/themes/twentyfifteen %{ap_serverroot}/wordpress/wp-content/themes/twentysixteen %files themes-collections %defattr(-,wwwrun,root) %{ap_serverroot}/wordpress/wp-content/themes/ %exclude %{ap_serverroot}/wordpress/wp-content/themes/index.php %exclude %{ap_serverroot}/wordpress/wp-content/themes/twentyfourteen %exclude %{ap_serverroot}/wordpress/wp-content/themes/twentyfifteen %exclude %{ap_serverroot}/wordpress/wp-content/themes/twentysixteen %changelog * Thu Feb 4 2016 ecsos@opensuse.org - update to 4.4.2 This is a critical security and bugfix release. http://codex.wordpress.org/Version_4.4.2 * Thu Jan 7 2016 ecsos@opensuse.org - update to 4.4.1 This is a critical security release. http://codex.wordpress.org/Version_4.4.1 * Wed Dec 9 2015 ecsos@opensuse.org - update to 4.4 http://codex.wordpress.org/Version_4.4 - also update german languages file "DU" and "SIE" to 20151205 * Wed Sep 16 2015 ecsos@opensuse.org - update to 4.3.1 This is a critical security release. http://codex.wordpress.org/Version_4.3.1 * Sat Aug 29 2015 ecsos@opensuse.org - update to 4.3 http://codex.wordpress.org/Version_4.3 - also update german languages file "DU" to 20150819 * Wed Aug 5 2015 ecsos@opensuse.org - update to 4.2.4 This is a critical security release. http://codex.wordpress.org/Version_4.2.4 - fix rpmlint warnings * Thu Jul 23 2015 ecsos@opensuse.org - update to 4.2.3 This is a critical security release. http://codex.wordpress.org/Version_4.2.3 * Thu May 7 2015 ecsos@opensuse.org - update to 4.2.2 This is a critical security release. http://codex.wordpress.org/Version_4.2.2 * Tue Apr 28 2015 Greg.Freemyer@gmail.com - Update README.SuSE to give more details of database setup - Update spec file to recommend a webserver and php5 module * Tue Apr 28 2015 ecsos@opensuse.org - update to 4.2.1 This is a critical security release. http://codex.wordpress.org/Version_4.2.1 * Fri Apr 24 2015 ecsos@opensuse.org - update to 4.2 http://codex.wordpress.org/Version_4.2 * Fri Apr 10 2015 Greg.Freemyer@gmail.com - Add "Recommends: php5-curl php5-zlib". They allow themes to be installed, but are not truly "required". - Update README.SuSE to reflect that * Sun Feb 22 2015 ecsos@opensuse.org - update to 4.1.1 http://codex.wordpress.org/Version_4.1.1 * Mon Jan 26 2015 ecsos@opensuse.org - update theme pageline to 1.4.6 * Fri Dec 19 2014 ecsos@opensuse.org - update to 4.1 also update german languages files to 2014-12-18 * Sun Nov 23 2014 ecsos@opensuse.org - update to 4.0.1 This is a critical security release. * Sat Sep 6 2014 ecsos@opensuse.org - update to 4.0 * Thu Aug 7 2014 ecsos@opensuse.org - update to 3.9.2 * Fri Jun 13 2014 ecsos@opensuse.org - update to 3.9.1 * Tue May 6 2014 robert.munteanu@gmail.com - Added wordpress-3.9.0-disable-core-auto-updates.patch to fix bnc#876406 * Tue May 6 2014 ecsos@opensuse.org - syscconfigdir-patch now operate on wp-config-sample.php and wp-config.php * Mon Apr 21 2014 ecsos@opensuse.org - change wordpress.conf for Apache 2.2 and Apache 2.4 * Sun Apr 20 2014 ecsos@opensuse.org - update to 3.9 also update german languages files to 20140416 * Wed Apr 9 2014 ecsos@opensuse.org - update to 3.8.2 * Sun Feb 2 2014 ecsos@opensuse.org - fix missing plugins directory in core package * Fri Jan 24 2014 ecsos@opensuse.org - update to 3.8.1 * Sat Dec 14 2013 ecsos@opensuse.org - update to 3.8 * Wed Oct 30 2013 ecsos@opensuse.org - update to 3.7.1 * Wed Oct 30 2013 ecsos@opensuse.org - update to 3.7 also update german languages files to 20131025 * Thu Sep 12 2013 ecsos@opensuse.org - update to 3.6.1 also update german language files to 01.08.2013 * Tue Jun 25 2013 ecsos@opensuse.org - update to 3.5.2 * Server-Side Request Forgery (SSRF) via the HTTP API. CVE-2013-2199. * Privilege Escalation: Contributors can publish posts, and users can reassign authorship. CVE-2013-2200. * Cross-Site Scripting (XSS) in SWFUpload. CVE-2013-2205. * Denial of Service (DoS) via Post Password Cookies. CVE-2013-2173. * Content Spoofing via Flash Applet in TinyMCE Media Plugin. CVE-2013-2204. * Cross-Site Scripting (XSS) when Uploading Media. CVE-2013-2201. * Full Path Disclosure (FPD) during File Upload. CVE-2013-2203. * Cross-Site Scripting (XSS) (Low Severity) when Editing Media. CVE-2013-2201. * Cross-Site Scripting (XSS) (Low Severity) when Installing/Updating Plugins/Themes. CVE-2013-2201. * XML External Entity Injection (XXE) via oEmbed. CVE-2013-2202. * Sat Feb 2 2013 ecsos@opensuse.org - update to 3.5.1 Version 3.5.1 is the first maintenance release of 3.5, fixing 37 bugs. It is also a security release for all previous WordPress versions. For a full list of changes, consult the list of tickets and the changelog, which include: Editor: Prevent certain HTML elements from being unexpectedly removed or modified in rare cases. Media: Fix a collection of minor workflow and compatibility issues in the new media manager. Networks: Suggest proper rewrite rules when creating a new network. Prevent scheduled posts from being stripped of certain HTML, such as video embeds, when they are published. Work around some misconfigurations that may have caused some JavaScript in the WordPress admin area to fail. Suppress some warnings that could occur when a plugin misused the database or user APIs. WordPress 3.5.1 also addresses the following security issues: A server-side request forgery vulnerability and remote port scanning using pingbacks. This vulnerability, which could potentially be used to expose information and compromise a site, affects all previous WordPress versions. This was fixed by the WordPress security team. We’d like to thank security researchers Gennady Kovshenin and Ryan Dewhurst for reviewing our work. Two instances of cross-site scripting via shortcodes and post content. These issues were discovered by Jon Cave of the WordPress security team. A cross-site scripting vulnerability in the external library Plupload. Thanks to the Moxiecode team for working with us on this, and for releasing Plupload 1.5.5 to address this issue. * Sun Dec 16 2012 ecsos@opensuse.org - update to Release 3.5 New Standard Theme “Twenty Twelve” Uses the current Theme Features responsive Design Improvements of the administration interface uses the current New welcome screen HiDPI Admin (for Retina display) Summary of options Suppression of the Link Manager (blogroll) Media improvements Upload / Insert workflow revised Full contribution types UI for file attachments * Tue Nov 13 2012 ecsos@opensuse.org - patch for /etc and FS_METHOD to direct for update over http and without FTP * Sun Nov 11 2012 ecsos@opensuse.org - update to 3.4.2 * Mon Jul 4 2011 chris@computersalat.de - update to 3.1.4 o wp#17556 PHP Errors on the media page in 3.1.3 o wp#17559 Deprecated query_string doesn't support array arguments o wp#17855 Allow plus '+' character when sanitizing mime type o wp#17910 User Profile JS cleanup - update to 3.1.3 o wp#17264 Duplicate posts returned if multiple meta_values match and no meta_key is set o wp#17327 Plugins page pagination links disabled for Must-use plugins / Incorrect path displayed in must-use help text - some rpmlint fixes o wrong-script-end-of-line-encoding (wp-content/themes/layers/*) o script-without-shebang (replace to all files) * Sat May 21 2011 chris@computersalat.de - added themes (http://wordpress.org/extend/themes/) o autumn-leaves.1.0 o chip-life.1.3.4 o grunge-wall.3.6 o layers.1.1.1 o orange-coffee.1.1 o portfolio-press.0.7.3 o softgreen.1.2 o strawberry-blend.1.2 o tropicala.1.5 o wp-bats-theme.1.2 * Mon May 16 2011 chris@computersalat.de - added themes (http://wordpress.org/extend/themes/) o blackneon.1.0.2 o decoder.0.9.1 o elements-of-seo.1.2 o flexi-blue.1.0.0 o piano-black.2.2 o phantom.1.1 o sliding-door.2.6.1 o tomorrow.1.09 o varg.1.3.1 o yoko.1.0.3 - fix deps/build o SLE_10, Fedora (no fdupes) o Fedora (no apache2 but httpd) o Fedora (fix "apxs" defines) o add @AP_SROOT@ to wordpress.httpd - add rpmlintrc * Wed May 11 2011 chris@computersalat.de - initial pkg 3.1.2