Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove PEAR Log dependencies #1543

Merged
merged 1 commit into from
Jul 20, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 0 additions & 27 deletions bin/xdmod-check-config
Original file line number Diff line number Diff line change
Expand Up @@ -152,33 +152,6 @@ try {
'PHP XMLWriter extension installed'
);

_debug('Checking for Log class');
$result = class_exists('Log');
displayResult(
$result,
'PHP PEAR Log class installed'
);

_debug('Including Log/mdb2.php');
include_once 'Log/mdb2.php';

_debug('Checking for Log_mdb2 class');
$result = class_exists('Log_mdb2');
displayResult(
$result,
'PHP MDB2 class installed'
);

_debug('Including MDB2/Driver/mysql.php');
include_once 'MDB2/Driver/mysql.php';

_debug('Checking for MDB2_Driver_mysql class');
$result = class_exists('MDB2_Driver_mysql');
displayResult(
$result,
'PHP MDB2 MySQL driver installed'
);

_debug('Checking for json_encode function');
$result = function_exists('json_encode');
displayResult(
Expand Down
2 changes: 0 additions & 2 deletions classes/CCR/Log.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ class Log
const LINE_FORMAT = "%datetime% [%level_name%] %message%\n";
const TIME_FORMAT = 'Y-m-d H:i:s';

// Class constants so "Log.php" doesn't need to be required by users
// of the Log class.
const EMERG = 0;
const ALERT = 1;
const CRIT = 2;
Expand Down
5 changes: 0 additions & 5 deletions docs/software-requirements.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ Open XDMoD requires the following software:
- [cURL][php-curl]
- [DOM][php-dom]
- [XMLWriter][php-xmlwriter]
- [PEAR MDB2 Package][pear-mdb2]
- [PEAR MDB2 MySQL Driver][pear-mdb2-mysql]
- [mbstring][php-mbstring]
- [APCu][php-pecl-apcu]
- [libreoffice][]
Expand Down Expand Up @@ -47,8 +45,6 @@ Open XDMoD requires the following software:
[php-curl]: https://secure.php.net/manual/en/book.curl.php
[php-dom]: https://secure.php.net/manual/en/book.dom.php
[php-xmlwriter]: https://secure.php.net/manual/en/book.xmlwriter.php
[pear-mdb2]: https://pear.php.net/package/MDB2
[pear-mdb2-mysql]: https://pear.php.net/package/MDB2_Driver_mysql
[php-mbstring]: https://secure.php.net/manual/en/book.mbstring.php
[php-pecl-apcu]: https://www.php.net/manual/en/book.apcu.php
[libreoffice]: https://www.libreoffice.org
Expand Down Expand Up @@ -82,7 +78,6 @@ added with this command for CentOS 7:

# yum install httpd php php-cli php-mysql php-gd \
gmp-devel php-gmp php-pdo php-xml \
php-pear-MDB2 php-pear-MDB2-Driver-mysql \
libreoffice \
mariadb-server mariadb cronie logrotate \
perl-Image-ExifTool php-mbstring php-pecl-apcu jq \
Expand Down
2 changes: 1 addition & 1 deletion open_xdmod/modules/xdmod/xdmod.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ BuildRequires: php-cli
Requires: httpd mod_ssl
Requires: mariadb >= 5.5.3
Requires: php >= 5.4 php-cli php-mysql php-pdo php-gd php-xml php-mbstring
Requires: php-pear-MDB2 php-pear-MDB2-Driver-mysql php-pecl-apcu
Requires: php-pecl-apcu
Requires: libreoffice-writer
Requires: chromium-headless
Requires: librsvg2-tools
Expand Down
4 changes: 4 additions & 0 deletions tests/ci/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -136,3 +136,7 @@ then
sudo -u xdmod xdmod-ingestor --last-modified-start-date="2017-01-01 00:00:00"
fi
fi

# Remove old PEAR dependencies. This command can be removed when a new Docker
# image is created without these packages installed.
yum -y remove php-pear-MDB2 php-pear-MDB2-Driver-mysql