diff --git a/README.en.md b/README.en.md
index 1b2a07b6201fbdd33add611646eb910edc2f66c0..a9541f6832f16aae240b836f7d53fca0fb1cd18f 100644
--- a/README.en.md
+++ b/README.en.md
@@ -1,7 +1,7 @@
# wordpress
#### Description
-{**When you're done, you can delete the content in this README and update the file with details for others getting started with your repository**}
+wordpress
#### Software Architecture
Software architecture description
diff --git a/README.fedora.wordpress b/README.fedora.wordpress
new file mode 100644
index 0000000000000000000000000000000000000000..7fdb05828539fd0d1f35ec6d4128313240460c37
--- /dev/null
+++ b/README.fedora.wordpress
@@ -0,0 +1,86 @@
+-------------------------------------------------------------------------------
+
+Wordpress is a database driven blogging program designed to make it exceedingly
+easy to publish an online blog, sometimes also called a weblog or journal.
+
+Once this package is installed, there are a few configuration items which need
+to be performed before the blog is usable. First, you need to establish a
+username and password to connect to your MySQL database as, and make both
+MySQL and Wordpress aware of this. Let's start by creating the database and the
+username / password inside MySQL first:
+
+ # mysql
+ mysql> create database wordpress;
+ Query OK, 1 row affected (0.00 sec)
+
+ mysql> grant all privileges on wordpress.* to wordpress identified by 'wordpress';
+ Query OK, 0 rows affected (0.00 sec)
+
+ mysql> flush privileges;
+ Query OK, 0 rows affected (0.00 sec)
+
+ mysql> exit
+ Bye
+ #
+
+Under certain curcumstances, you may need to run variations of the "grant"
+command:
+mysql> grant all privileges on wordpress.* to wordpress@localhost identified by 'wordpress';
+ OR
+mysql> grant all privileges on wordpress.* to wordpress@'%' identified by 'wordpress';
+
+This has created an empty database called 'wordpress', created a user named
+'wordpress' with a password of 'wordpress', and given the 'wordpress' user total
+permission over the 'wordpress' database. Obviously, you'll want to select a
+different password, and you may want to choose different database and user
+names depending on your installation. The specific values you choose are
+not constrained, they simply need to be consistent between the database and the
+config file.
+
+Next, you need to edit your /etc/wordpress/wp-config.php file to reflect the
+values you've chosen. These values will go in the appropriate places at the
+beginning of that file.
+
+Once that's done and the database server and web server have been started,
+open a web browser to http://localhost/wordpress/wp-admin/install.php and
+follow the instructions given to you on the pages you see to set up the
+database tables and begin publishing your blog.
+
+-------------------------------------------------------------------------------
+
+Wordpress ships with Flash and Silverlight plugins for the 'plupload' file
+uploader and the 'mediaelement' media player embedder. The idea is to try and
+be able to provide a multi-file uploader and an embedded video player when
+HTML5 is not available (or does not support the video format in question).
+These plugins are provided as pre-built binaries and there is no mechanism
+for building them from source during Wordpress compilation. As the inclusion
+of pre-built binaries is against Fedora policy - see
+https://fedoraproject.org/wiki/Packaging:Guidelines#No_inclusion_of_pre-built_binaries_or_libraries
+ - these plugins have been removed from the Fedora package. As a consequence:
+
+a) any Wordpress element or plugin that uses the 'plupload' will only present
+an HTML5-based multi-file uploader if HTML5 is supported by the user's browser
+or an HMTL4-based single-file uploader in HTML5 is not supported. No Flash
+or Silverlight-based multi-file uploader will be provided.
+
+b) If you try to embed media into a Wordpress post using the [video] and
+[audio] short tags, the media player will be visible if the reader is using
+a browser that has HTML5 support for the media format in question; if not, the
+'Download Media' link will be offered. No Flash or Silverlight-based player
+element will be included.
+
+-------------------------------------------------------------------------------
+
+Optional dependencies:
+
+You may wish to install the following packages:
+
+ php-pecl-imagick: optimize image transformation
+ php-pecl-ssh2: for file transfert using ssh
+
+An opcode cache is also recommended:
+ php 5.5: php-opcache
+ php 5.4: php-pecl-zendopcache
+ php 5.3: php-pecl-apc
+
+-------------------------------------------------------------------------------
diff --git a/README.fedora.wordpress-mu b/README.fedora.wordpress-mu
new file mode 100644
index 0000000000000000000000000000000000000000..af10453f34f0c81684db2a5f7f5f6a7b19de0a6f
--- /dev/null
+++ b/README.fedora.wordpress-mu
@@ -0,0 +1,5 @@
+As of wordpress 3.0.x, upstream has deprecated wordpress-mu. This
+functionality has been included in mainline wordpress. For
+information on migrating from wordpress-mu, visit
+http://codex.wordpress.org/Migrating_Multiple_Blogs_into_WordPress_3.0_Multisite
+
diff --git a/README.md b/README.md
index b1810a8b06bf29c2589128e59e214b3a511616cf..951ee9468b8d81fb7df0ed2a8e40da4081f94df2 100644
--- a/README.md
+++ b/README.md
@@ -1,9 +1,7 @@
# wordpress
#### 介绍
-{**以下是 Gitee 平台说明,您可以替换此简介**
-Gitee 是 OSCHINA 推出的基于 Git 的代码托管平台(同时支持 SVN)。专为开发者提供稳定、高效、安全的云端软件开发协作平台
-无论是个人、团队、或是企业,都能够用 Gitee 实现代码托管、项目管理、协作开发。企业项目请看 [https://gitee.com/enterprises](https://gitee.com/enterprises)}
+wordpress
#### 软件架构
软件架构说明
diff --git a/wordpress-5.1-remove-jshint-refs.patch b/wordpress-5.1-remove-jshint-refs.patch
new file mode 100644
index 0000000000000000000000000000000000000000..fff73680354b53f00e0deeccdc1049f59c1f4e54
--- /dev/null
+++ b/wordpress-5.1-remove-jshint-refs.patch
@@ -0,0 +1,11 @@
+diff -up wordpress/wp-includes/script-loader.php.orig wordpress/wp-includes/script-loader.php
+--- wordpress/wp-includes/script-loader.php.orig 2019-02-22 10:52:01.902006889 +0100
++++ wordpress/wp-includes/script-loader.php 2019-02-22 10:52:04.560023086 +0100
+@@ -1251,7 +1251,6 @@ function wp_default_scripts( &$scripts )
+ $scripts->add( 'wp-codemirror', '/wp-includes/js/codemirror/codemirror.min.js', array(), '5.29.1-alpha-ee20357' );
+ $scripts->add( 'csslint', '/wp-includes/js/codemirror/csslint.js', array(), '1.0.5' );
+ $scripts->add( 'esprima', '/wp-includes/js/codemirror/esprima.js', array(), '4.0.0' );
+- $scripts->add( 'jshint', '/wp-includes/js/codemirror/fakejshint.js', array( 'esprima' ), '2.9.5' );
+ $scripts->add( 'jsonlint', '/wp-includes/js/codemirror/jsonlint.js', array(), '1.6.2' );
+ $scripts->add( 'htmlhint', '/wp-includes/js/codemirror/htmlhint.js', array(), '0.9.14-xwp' );
+ $scripts->add( 'htmlhint-kses', '/wp-includes/js/codemirror/htmlhint-kses.js', array( 'htmlhint' ) );
diff --git a/wordpress-5.1-tinymce_noflash.patch b/wordpress-5.1-tinymce_noflash.patch
new file mode 100644
index 0000000000000000000000000000000000000000..0d0e79ce9421e482226d569d0b9dcec093c8d935
--- /dev/null
+++ b/wordpress-5.1-tinymce_noflash.patch
@@ -0,0 +1,35 @@
+diff -up wordpress/wp-includes/js/tinymce/plugins/media/plugin.js.orig wordpress/wp-includes/js/tinymce/plugins/media/plugin.js
+--- wordpress/wp-includes/js/tinymce/plugins/media/plugin.js.orig 2019-02-21 14:59:28.793415420 +0100
++++ wordpress/wp-includes/js/tinymce/plugins/media/plugin.js 2019-02-21 15:00:14.319647286 +0100
+@@ -166,7 +166,6 @@ var media = (function () {
+ mp4: 'video/mp4',
+ webm: 'video/webm',
+ ogg: 'video/ogg',
+- swf: 'application/x-shockwave-flash'
+ };
+ var fileEnd = url.toLowerCase().split('.').pop();
+ var mime = mimes[fileEnd];
+@@ -424,14 +423,6 @@ var media = (function () {
+ var allowFullscreen = data.allowFullscreen ? ' allowFullscreen="1"' : '';
+ return '';
+ };
+- var getFlashHtml = function (data) {
+- var html = '';
+- return html;
+- };
+ var getAudioHtml = function (data, audioTemplateCallback) {
+ if (audioTemplateCallback) {
+ return audioTemplateCallback(data);
+@@ -494,8 +485,6 @@ var media = (function () {
+ });
+ if (data.type === 'iframe') {
+ return getIframeHtml(data);
+- } else if (data.source1mime === 'application/x-shockwave-flash') {
+- return getFlashHtml(data);
+ } else if (data.source1mime.indexOf('audio') !== -1) {
+ return getAudioHtml(data, audioTemplateCallback);
+ } else if (data.type === 'script') {
diff --git a/wordpress-5.2-hello.patch b/wordpress-5.2-hello.patch
new file mode 100644
index 0000000000000000000000000000000000000000..5ccc2f5ae6f99830cbbf216bd8e42e22032deaee
--- /dev/null
+++ b/wordpress-5.2-hello.patch
@@ -0,0 +1,59 @@
+diff -up wordpress/wp-content/plugins/hello.php.dolly wordpress/wp-content/plugins/hello.php
+--- wordpress/wp-content/plugins/hello.php.dolly 2019-03-28 15:09:05.874797878 +0100
++++ wordpress/wp-content/plugins/hello.php 2019-03-28 15:10:15.892164549 +0100
+@@ -6,41 +6,26 @@
+ /*
+ Plugin Name: Hello Dolly
+ Plugin URI: http://wordpress.org/plugins/hello-dolly/
+-Description: This is not just a plugin, it symbolizes the hope and enthusiasm of an entire generation summed up in two words sung most famously by Louis Armstrong: Hello, Dolly. When activated you will randomly see a lyric from Hello, Dolly in the upper right of your admin screen on every page.
++Description: This is not just a plugin, it symbolizes the hope and enthusiasm of an entire generation summed up in two words sung most famously by Richard M. Stallman: Free Software. When activated you will randomly see a lyric from the Free Software Song in the upper right of your admin screen on every page.
+ Author: Matt Mullenweg
+ Version: 1.7.2
+ Author URI: http://ma.tt/
+ */
+
+ function hello_dolly_get_lyric() {
+- /** These are the lyrics to Hello Dolly */
+- $lyrics = "Hello, Dolly
+-Well, hello, Dolly
+-It's so nice to have you back where you belong
+-You're lookin' swell, Dolly
+-I can tell, Dolly
+-You're still glowin', you're still crowin'
+-You're still goin' strong
+-I feel the room swayin'
+-While the band's playin'
+-One of our old favorite songs from way back when
+-So, take her wrap, fellas
+-Dolly, never go away again
+-Hello, Dolly
+-Well, hello, Dolly
+-It's so nice to have you back where you belong
+-You're lookin' swell, Dolly
+-I can tell, Dolly
+-You're still glowin', you're still crowin'
+-You're still goin' strong
+-I feel the room swayin'
+-While the band's playin'
+-One of our old favorite songs from way back when
+-So, golly, gee, fellas
+-Have a little faith in me, fellas
+-Dolly, never go away
+-Promise, you'll never go away
+-Dolly'll never go away again";
++ // These are the lyrics to the Free Software Song
++ $lyrics = "Join us now and share the software;
++You'll be free, hackers, you'll be free.
++Hoarders may get piles of money,
++That is true, hackers, that is true.
++But they cannot help their neighbors;
++That ain't good, hackers, that ain't good.
++When we have enough free software
++At our call, hackers, at our call,
++We'll kick out those dirty licenses
++Ever more, hackers, ever more.
++Join us now and share the software;
++You'll be free, hackers, you'll be free.";
+
+ // Here we split it into lines.
+ $lyrics = explode( "\n", $lyrics );
diff --git a/wordpress-5.4-config.patch b/wordpress-5.4-config.patch
new file mode 100644
index 0000000000000000000000000000000000000000..4f9440457a4e405bec31b77b3850756d0b0b4486
--- /dev/null
+++ b/wordpress-5.4-config.patch
@@ -0,0 +1,35 @@
+diff -up wordpress/wp-config.php.rpm wordpress/wp-config.php
+--- wordpress/wp-config.php.rpm 2020-10-20 15:05:26.351765085 +0200
++++ wordpress/wp-config.php 2020-10-20 15:05:48.663684089 +0200
+@@ -66,6 +66,22 @@ define( 'NONCE_SALT', 'put your un
+ $table_prefix = 'wp_';
+
+ /**
++ * See http://make.wordpress.org/core/2013/10/25/the-definitive-guide-to-disabling-auto-updates-in-wordpress-3-7
++ */
++
++/* Disable all file change, as RPM base installation are read-only */
++define('DISALLOW_FILE_MODS', true);
++
++/* Please ensure that this is either 'direct', 'ssh2', 'ftpext', 'ftpsockets' or false */
++define('FS_METHOD', 'direct');
++
++/* Disable automatic updater, in case you want to allow
++ above FILE_MODS for plugins, themes, ... */
++define('AUTOMATIC_UPDATER_DISABLED', true);
++
++/* Core update is always disabled, WP_AUTO_UPDATE_CORE value is ignore */
++
++/**
+ * For developers: WordPress debugging mode.
+ *
+ * Change this to true to enable the display of notices during development.
+@@ -83,7 +99,7 @@ define( 'WP_DEBUG', false );
+
+ /** Absolute path to the WordPress directory. */
+ if ( ! defined( 'ABSPATH' ) ) {
+- define( 'ABSPATH', __DIR__ . '/' );
++ define('ABSPATH', '/usr/share/wordpress');
+ }
+
+ /** Sets up WordPress vars and included files. */
diff --git a/wordpress-5.4-no_swfupload.patch b/wordpress-5.4-no_swfupload.patch
new file mode 100644
index 0000000000000000000000000000000000000000..3683cb73f2a58421722c4305a4d3a730874b0309
--- /dev/null
+++ b/wordpress-5.4-no_swfupload.patch
@@ -0,0 +1,16 @@
+diff -up wordpress/wp-includes/script-loader.php.old wordpress/wp-includes/script-loader.php
+--- wordpress/wp-includes/script-loader.php.old 2020-03-25 16:34:50.606199762 +0100
++++ wordpress/wp-includes/script-loader.php 2020-03-25 16:35:59.409883628 +0100
+@@ -892,12 +892,6 @@ function wp_default_scripts( $scripts )
+ $scripts->add( 'wp-plupload', "/wp-includes/js/plupload/wp-plupload$suffix.js", array( 'plupload', 'jquery', 'json2', 'media-models' ), false, 1 );
+ did_action( 'init' ) && $scripts->localize( 'wp-plupload', 'pluploadL10n', $uploader_l10n );
+
+- // Keep 'swfupload' for back-compat.
+- $scripts->add( 'swfupload', '/wp-includes/js/swfupload/swfupload.js', array(), '2201-20110113' );
+- $scripts->add( 'swfupload-all', false, array( 'swfupload' ), '2201' );
+- $scripts->add( 'swfupload-handlers', "/wp-includes/js/swfupload/handlers$suffix.js", array( 'swfupload-all', 'jquery' ), '2201-20110524' );
+- did_action( 'init' ) && $scripts->localize( 'swfupload-handlers', 'swfuploadL10n', $uploader_l10n );
+-
+ $scripts->add( 'comment-reply', "/wp-includes/js/comment-reply$suffix.js", array(), false, 1 );
+
+ $scripts->add( 'json2', "/wp-includes/js/json2$suffix.js", array(), '2015-05-03' );
diff --git a/wordpress-5.6-mediaelement_no_swf.patch b/wordpress-5.6-mediaelement_no_swf.patch
new file mode 100644
index 0000000000000000000000000000000000000000..4ee0eec3c66eb681f110d59d76d01166ca7a68c0
--- /dev/null
+++ b/wordpress-5.6-mediaelement_no_swf.patch
@@ -0,0 +1,38 @@
+diff -up wordpress/wp-includes/js/mediaelement/mediaelement-and-player.js.no wordpress/wp-includes/js/mediaelement/mediaelement-and-player.js
+--- wordpress/wp-includes/js/mediaelement/mediaelement-and-player.js.no 2020-09-29 17:53:06.000000000 +0200
++++ wordpress/wp-includes/js/mediaelement/mediaelement-and-player.js 2020-12-09 09:44:27.954254919 +0100
+@@ -6135,6 +6135,7 @@ if (hasFlash) {
+ }
+ });
+
++/* swf files removed from RPM
+ var FlashMediaElementVideoRenderer = {
+ name: 'flash_video',
+ options: {
+@@ -6219,6 +6220,7 @@ if (hasFlash) {
+ create: FlashMediaElementRenderer.create
+ };
+ _renderer.renderer.add(FlashMediaElementAudioOggRenderer);
++*/
+ }
+
+ },{"2":2,"25":25,"27":27,"28":28,"3":3,"5":5,"7":7,"8":8}],21:[function(_dereq_,module,exports){
+diff -up wordpress/wp-includes/js/mediaelement/mediaelement.js.no wordpress/wp-includes/js/mediaelement/mediaelement.js
+--- wordpress/wp-includes/js/mediaelement/mediaelement.js.no 2020-09-29 17:53:06.000000000 +0200
++++ wordpress/wp-includes/js/mediaelement/mediaelement.js 2020-12-09 09:44:38.532227178 +0100
+@@ -1842,6 +1842,7 @@ if (hasFlash) {
+ }
+ });
+
++/* swf files removed from RPM
+ var FlashMediaElementVideoRenderer = {
+ name: 'flash_video',
+ options: {
+@@ -1926,6 +1927,7 @@ if (hasFlash) {
+ create: FlashMediaElementRenderer.create
+ };
+ _renderer.renderer.add(FlashMediaElementAudioOggRenderer);
++*/
+ }
+
+ },{"16":16,"18":18,"19":19,"2":2,"3":3,"5":5,"7":7,"8":8}],12:[function(_dereq_,module,exports){
diff --git a/wordpress-5.8-noupdate.patch b/wordpress-5.8-noupdate.patch
new file mode 100644
index 0000000000000000000000000000000000000000..39dbb9201e965b29631961948cff81e92c790d84
--- /dev/null
+++ b/wordpress-5.8-noupdate.patch
@@ -0,0 +1,91 @@
+diff -up wordpress/wp-admin/includes/admin-filters.php.noupdate wordpress/wp-admin/includes/admin-filters.php
+--- wordpress/wp-admin/includes/admin-filters.php.noupdate 2021-07-21 13:55:03.381224813 +0200
++++ wordpress/wp-admin/includes/admin-filters.php 2021-07-21 13:55:11.920208285 +0200
+@@ -113,7 +113,6 @@ add_action( 'personal_options_update', '
+ add_action( 'load-plugins.php', 'wp_plugin_update_rows', 20 ); // After wp_update_plugins() is called.
+ add_action( 'load-themes.php', 'wp_theme_update_rows', 20 ); // After wp_update_themes() is called.
+
+-add_action( 'admin_notices', 'update_nag', 3 );
+ add_action( 'admin_notices', 'deactivated_plugins_notice', 5 );
+ add_action( 'admin_notices', 'paused_plugins_notice', 5 );
+ add_action( 'admin_notices', 'paused_themes_notice', 5 );
+diff -up wordpress/wp-admin/includes/class-core-upgrader.php.noupdate wordpress/wp-admin/includes/class-core-upgrader.php
+--- wordpress/wp-admin/includes/class-core-upgrader.php.noupdate 2021-06-19 23:37:57.000000000 +0200
++++ wordpress/wp-admin/includes/class-core-upgrader.php 2021-07-21 13:55:03.381224813 +0200
+@@ -271,6 +271,9 @@ class Core_Upgrader extends WP_Upgrader
+ * @return bool True if we should update to the offered version, otherwise false.
+ */
+ public static function should_update_to_version( $offered_ver ) {
++ // RPM: nether allow core update
++ return false;
++
+ require ABSPATH . WPINC . '/version.php'; // $wp_version; // x.y.z
+
+ $current_branch = implode( '.', array_slice( preg_split( '/[.-]/', $wp_version ), 0, 2 ) ); // x.y
+diff -up wordpress/wp-admin/includes/class-wp-automatic-updater.php.noupdate wordpress/wp-admin/includes/class-wp-automatic-updater.php
+--- wordpress/wp-admin/includes/class-wp-automatic-updater.php.noupdate 2021-04-16 14:01:15.000000000 +0200
++++ wordpress/wp-admin/includes/class-wp-automatic-updater.php 2021-07-21 13:55:03.381224813 +0200
+@@ -38,7 +38,7 @@ class WP_Automatic_Updater {
+ }
+
+ // More fine grained control can be done through the WP_AUTO_UPDATE_CORE constant and filters.
+- $disabled = defined( 'AUTOMATIC_UPDATER_DISABLED' ) && AUTOMATIC_UPDATER_DISABLED;
++ $disabled = !defined( 'AUTOMATIC_UPDATER_DISABLED' ) || AUTOMATIC_UPDATER_DISABLED;
+
+ /**
+ * Filters whether to entirely disable background updates.
+diff -up wordpress/wp-admin/includes/file.php.noupdate wordpress/wp-admin/includes/file.php
+--- wordpress/wp-admin/includes/file.php.noupdate 2021-05-24 21:24:57.000000000 +0200
++++ wordpress/wp-admin/includes/file.php 2021-07-21 13:55:03.381224813 +0200
+@@ -1992,7 +1992,7 @@ function WP_Filesystem( $args = false, $
+ */
+ function get_filesystem_method( $args = array(), $context = '', $allow_relaxed_file_ownership = false ) {
+ // Please ensure that this is either 'direct', 'ssh2', 'ftpext', or 'ftpsockets'.
+- $method = defined( 'FS_METHOD' ) ? FS_METHOD : false;
++ $method = defined( 'FS_METHOD' ) ? FS_METHOD : 'direct';
+
+ if ( ! $context ) {
+ $context = WP_CONTENT_DIR;
+diff -up wordpress/wp-admin/includes/update.php.noupdate wordpress/wp-admin/includes/update.php
+--- wordpress/wp-admin/includes/update.php.noupdate 2021-05-17 19:04:01.000000000 +0200
++++ wordpress/wp-admin/includes/update.php 2021-07-21 13:55:03.381224813 +0200
+@@ -341,12 +341,7 @@ function update_right_now_message() {
+ $cur = get_preferred_from_update_core();
+
+ if ( isset( $cur->response ) && 'upgrade' === $cur->response ) {
+- $msg .= sprintf(
+- '%s ',
+- network_admin_url( 'update-core.php' ),
+- /* translators: %s: WordPress version number, or 'Latest' string. */
+- sprintf( __( 'Update to %s' ), $cur->current ? $cur->current : __( 'Latest' ) )
+- );
++ $msg .= '';
+ }
+ }
+
+diff -up wordpress/wp-includes/load.php.noupdate wordpress/wp-includes/load.php
+--- wordpress/wp-includes/load.php.noupdate 2021-06-23 21:05:57.000000000 +0200
++++ wordpress/wp-includes/load.php 2021-07-21 13:55:03.381224813 +0200
+@@ -1579,7 +1579,7 @@ function wp_is_file_mod_allowed( $contex
+ * @param bool $file_mod_allowed Whether file modifications are allowed.
+ * @param string $context The usage context.
+ */
+- return apply_filters( 'file_mod_allowed', ! defined( 'DISALLOW_FILE_MODS' ) || ! DISALLOW_FILE_MODS, $context );
++ return apply_filters( 'file_mod_allowed', defined( 'DISALLOW_FILE_MODS' ) && ! DISALLOW_FILE_MODS, $context );
+ }
+
+ /**
+diff -up wordpress/wp-includes/update.php.noupdate wordpress/wp-includes/update.php
+--- wordpress/wp-includes/update.php.noupdate 2021-05-17 19:04:01.000000000 +0200
++++ wordpress/wp-includes/update.php 2021-07-21 13:55:03.381224813 +0200
+@@ -926,10 +926,6 @@ function _maybe_update_themes() {
+ * @since 3.1.0
+ */
+ function wp_schedule_update_checks() {
+- if ( ! wp_next_scheduled( 'wp_version_check' ) && ! wp_installing() ) {
+- wp_schedule_event( time(), 'twicedaily', 'wp_version_check' );
+- }
+-
+ if ( ! wp_next_scheduled( 'wp_update_plugins' ) && ! wp_installing() ) {
+ wp_schedule_event( time(), 'twicedaily', 'wp_update_plugins' );
+ }
diff --git a/wordpress-6.2.2.tar.gz b/wordpress-6.2.2.tar.gz
new file mode 100644
index 0000000000000000000000000000000000000000..2618f5488298c546c48612a53275a199449250ee
Binary files /dev/null and b/wordpress-6.2.2.tar.gz differ
diff --git a/wordpress-httpd-conf b/wordpress-httpd-conf
new file mode 100644
index 0000000000000000000000000000000000000000..dbefe979d1dc0d6a41804d7ec8896aa304b61d3f
--- /dev/null
+++ b/wordpress-httpd-conf
@@ -0,0 +1,23 @@
+Alias /wordpress /usr/share/wordpress
+
+# Access is only allowed via local access
+# Change this once configured
+
+
+ AllowOverride Options
+ Require local
+
+
+
+ # Deny access to any php file in the uploads directory
+
+ Require all denied
+
+
+
+
+ # Deny access to any php file in the akismet directory
+
+ Require all denied
+
+
diff --git a/wordpress-minify.php b/wordpress-minify.php
new file mode 100644
index 0000000000000000000000000000000000000000..d8e18c425c60f0ffe68879b954cf3c9ead8ea2e3
--- /dev/null
+++ b/wordpress-minify.php
@@ -0,0 +1,16 @@
+squeeze($in);
+if ($out) {
+ printf("+ minify from %s to %s: %2d%% of %6d\n",
+ basename($_SERVER['argv'][1]), basename($_SERVER['argv'][2]),
+ round(strlen($out)*100/strlen($in)), strlen($in));
+ file_put_contents($_SERVER['argv'][2], $out);
+} else {
+ exit(2);
+}
+
diff --git a/wordpress-nginx-conf b/wordpress-nginx-conf
new file mode 100644
index 0000000000000000000000000000000000000000..e41cc6ab4594e92abdd2c4cfd6e3d061907bf1f6
--- /dev/null
+++ b/wordpress-nginx-conf
@@ -0,0 +1,35 @@
+# Wordpress
+
+location = /wordpress {
+ alias /usr/share/wordpress/;
+}
+
+location /wordpress/ {
+ root /usr/share;
+ index index.php;
+
+ location ~ ^/wordpress/wp-content/uploads/(.+)\.php$ {
+ # Deny access to any php file in the uploads directory
+ deny all;
+ }
+ location ~ ^/wordpress/wp-content/plugins/akismet/(.+)\.php$ {
+ # Deny access to any php file in the akismet directory
+ deny all;
+ }
+
+ # Access is only allowed via local access
+ # Change this once configured
+ location ~ ^/wordpress/(.+\.php)$ {
+ allow 127.0.0.1;
+ allow ::1;
+ deny all;
+
+ try_files $uri =404;
+ fastcgi_intercept_errors on;
+ include fastcgi_params;
+ fastcgi_param SERVER_NAME $host;
+ fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
+ fastcgi_pass php-fpm;
+ }
+}
+
diff --git a/wordpress.spec b/wordpress.spec
new file mode 100644
index 0000000000000000000000000000000000000000..7964b78c562b4059a603735413555e0be1812583
--- /dev/null
+++ b/wordpress.spec
@@ -0,0 +1,258 @@
+%define anolis_release 1
+
+%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}}
+%global wp_content %{_datadir}/wordpress/wp-content
+
+%global with_nginx 1
+%global upstream_version 6.2.2
+
+Summary: Blog tool and publishing platform
+URL: http://www.wordpress.org
+Name: wordpress
+Version: %{upstream_version}
+Release: %{anolis_release}%{?dist}
+# Wordpress is GPL-2.0-or-later
+# php-simplepie is BSD-3-Clause
+# php-getid3 is LGPL-3.0-or-later (or some others)
+# php-mailer is LGPL-2.1-only
+License: GPL-2.0-or-later AND BSD-3-Clause AND LGPL-3.0-or-later AND LGPL-2.1-only
+
+Source0: https://wordpress.org/%{name}-%{upstream_version}%{?upstream_prever:-%{upstream_prever}}.tar.gz
+Source1: wordpress-httpd-conf
+Source4: wordpress-nginx-conf
+# To minify JS assets
+Source5: wordpress-minify.php
+
+# Patch out copyrighted text of Hello, Dolly
+# (and replace it with Free Software Song)
+Patch0: wordpress-5.2-hello.patch
+# Drop swfupload: not built from source, not reasonably possible to do
+Patch2: wordpress-5.4-no_swfupload.patch
+# Adjust tinymce's media plugin not to use its SWF plugin. This changes
+# 'p.getParam("flash_video_player_url",u.convertUrl(u.url+"/moxieplayer.swf"))'
+# to 'false'
+Patch3: wordpress-5.1-tinymce_noflash.patch
+# We drop the SWF files from mediaelement
+Patch4: wordpress-5.6-mediaelement_no_swf.patch
+# RPM configuration:
+# Path to installation
+# Disable auto-updater
+Patch5: wordpress-5.4-config.patch
+# RPM are readonly
+# disable version check and updated
+# change DISALLOW_FILE_MODS default value to true
+# ignore WP_AUTO_UPDATE_CORE (always false)
+Patch6: wordpress-5.8-noupdate.patch
+# Debian patch for jshint
+Patch8: wordpress-5.1-remove-jshint-refs.patch
+
+
+BuildArch: noarch
+BuildRequires: php-cli
+BuildRequires: php-patchwork-jsqueeze
+BuildRequires: php(language) >= 7.2
+
+%if %{with_nginx}
+Requires: webserver
+Requires: php(httpd)
+Suggests: httpd
+# For directory ownership
+Requires: httpd-filesystem
+Requires: nginx-filesystem
+%else
+Requires: php
+%endif
+Requires: php(language) >= 7.2
+Requires: php-sodium
+Requires: php-ctype
+Requires: php-filter
+Requires: php-mysqli
+
+# From phpcompatinfo report for version 4.5.3
+Requires: php-curl
+Requires: php-date
+Requires: php-dom
+Requires: php-exif
+Requires: php-fileinfo
+Requires: php-gd
+Requires: php-gettext
+Requires: php-hash
+Requires: php-iconv
+Requires: php-intl
+Requires: php-json
+Requires: php-libxml
+Requires: php-mbstring
+Requires: php-openssl
+Requires: php-pcre
+Requires: php-simplexml
+Requires: php-spl
+Requires: php-xml
+Requires: php-xmlreader
+Requires: php-zip
+Requires: php-zlib
+Requires: httpd
+# Unbundled
+Requires: ca-certificates
+# Bundled
+# grep "SIMPLEPIE_VERSION'" wordpress/wp-includes/class-simplepie.php
+Provides: bundled(php-simplepie) = 1.5.8
+# grep ' VERSION ' wordpress/wp-includes/ID3/getid3.php
+Provides: bundled(php-getid3) = 1.9.22
+# grep ' VERSION ' wordpress/wp-includes/PHPMailer/PHPMailer.php
+Provides: bundled(php-phpmailer) = 6.7
+Provides: wordpress-mu = %{version}-%{release}
+Obsoletes: wordpress-mu < 2.9.3
+
+
+%description
+Wordpress is an online publishing / weblog package that makes it very easy,
+almost trivial, to get information out to people on the web.
+
+%package doc
+Summary: Documentation files for %{name}
+Requires: %{name} = %{version}-%{release}
+BuildArch: noarch
+
+%description doc
+The %{name}-doc package contains documentation files for %{name}.
+
+%prep
+%setup -q -n wordpress
+
+# swfupload can just die in its entirety
+rm -rf wp-includes/js/swfupload
+
+# remove .htaccess, protected by httpd config file
+rm wp-content/plugins/akismet/.htaccess
+
+# only for PHP < 7.0 without random_int
+rm -rf wp-includes/random_compat
+# only for PHP < 7.2 without sodium_crypto_box
+rm -rf wp-includes/sodium_compat
+
+%patch -P0 -p1 -b .dolly
+%patch -P2 -p1
+%patch -P3 -p1
+# Adjust mediaelement not to use its SWF
+%patch -P4 -p1
+%patch -P8 -p1
+
+# We patch .js files, so minify them
+php %{SOURCE5} \
+ wp-includes/js/tinymce/plugins/media/plugin.js \
+ wp-includes/js/tinymce/plugins/media/plugin.min.js
+php %{SOURCE5} \
+ wp-includes/js/mediaelement/mediaelement-and-player.js \
+ wp-includes/js/mediaelement/mediaelement-and-player.min.js
+php %{SOURCE5} \
+ wp-includes/js/mediaelement/mediaelement.js \
+ wp-includes/js/mediaelement/mediaelement.min.js
+
+# Re-Generated the archive
+arc=wp-includes/js/tinymce/wp-tinymce.js
+grep "^// Source" $arc | while read a b c
+do
+ if [ -f $c ]; then
+ echo -e "\n$a $b $c"
+ cat $c
+ else
+ exit 1
+ fi
+done >$arc.tmp
+if [ -s $arc.tmp ]; then
+ gzip -c $arc > $arc.gz
+ ls -l $arc*
+ mv $arc.tmp $arc
+else
+ exit 1
+fi
+
+# Create RPM configuration
+sed -e 's/\r//' wp-config-sample.php >wp-config.php
+%patch -P5 -p1
+%patch -P6 -p1
+
+# fix file encoding
+sed -i -e 's/\r//' license.txt
+
+: Bundled library versions
+grep "SIMPLEPIE_VERSION'" wp-includes/class-simplepie.php
+grep ' VERSION ' wp-includes/ID3/getid3.php
+grep ' VERSION ' wp-includes/PHPMailer/PHPMailer.php
+
+
+%build
+
+%install
+# Apache configuration
+install -m 0644 -D -p %{SOURCE1} ${RPM_BUILD_ROOT}%{_sysconfdir}/httpd/conf.d/wordpress.conf
+
+%if %{with_nginx}
+install -m 0644 -D -p %{SOURCE4} ${RPM_BUILD_ROOT}%{_sysconfdir}/nginx/default.d/wordpress.conf
+%endif
+
+# Application
+mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/wordpress
+cp -pr * ${RPM_BUILD_ROOT}%{_datadir}/wordpress
+
+# Configuration
+install -m 0644 -D wp-config.php ${RPM_BUILD_ROOT}%{_sysconfdir}/wordpress/wp-config.php
+/bin/ln -sf ../../../etc/wordpress/wp-config.php ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-config.php
+
+# Create additional wp-content directories so we can own them
+install -d ${RPM_BUILD_ROOT}%{wp_content}/{plugins,themes,upgrade,uploads}
+
+# Remove empty files to make rpmlint happy
+find ${RPM_BUILD_ROOT} -type f -empty -exec rm -vf {} \;
+# These are docs, remove them from here, docify them later
+rm -f ${RPM_BUILD_ROOT}%{_datadir}/wordpress/{license.txt,readme.html}
+
+# Remove bundled ca-bundle.crt
+rm ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/certificates/ca-bundle.crt
+ln -s %{_sysconfdir}/pki/tls/certs/ca-bundle.crt \
+ ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/certificates/ca-bundle.crt
+
+# Remove backup copies of patches
+find ${RPM_BUILD_ROOT} \( -name \*.dolly -o -name \*.rhbz522897 -o -name \*.orig \) \
+ -print -delete
+
+
+%pretrans -p
+-- Remove link to system library
+path = "%{_datadir}/wordpress/wp-includes/PHPMailer"
+st = posix.stat(path)
+if st and st.type == "link" then
+ os.remove(path)
+end
+
+
+%files
+%config(noreplace) %{_sysconfdir}/httpd/conf.d/wordpress.conf
+%if %{with_nginx}
+%config(noreplace) %{_sysconfdir}/nginx/default.d/wordpress.conf
+%endif
+%dir %{_datadir}/wordpress
+%{_datadir}/wordpress/wp-admin
+%{_datadir}/wordpress/wp-includes
+%{_datadir}/wordpress/index.php
+%dir %{wp_content}/
+%{wp_content}/index.php
+%dir %attr(2775,apache,ftp) %{wp_content}/plugins
+%dir %attr(2775,apache,ftp) %{wp_content}/themes
+%dir %attr(2775,apache,ftp) %{wp_content}/upgrade
+%dir %attr(2775,apache,ftp) %{wp_content}/uploads
+%{wp_content}/plugins/*
+%{wp_content}/themes/*
+%{!?_licensedir:%global license %%doc}
+%license license.txt
+%{_datadir}/wordpress/wp-*.php
+%attr(750,root,apache) %dir %{_sysconfdir}/wordpress
+%attr(640,root,apache) %config(noreplace) %{_sysconfdir}/wordpress/wp-config.php
+%{_datadir}/wordpress/xmlrpc.php
+
+%files doc
+%doc readme.html
+
+%changelog
+* Fri Jul 14 2023 mgb01105731 - 6.2.2-1
+- Init upstream from version 6.2.2