Updated stubs, improved PHP7 compatibility

This commit is contained in:
Christopher Vagnetoft
2016-07-21 03:08:06 +02:00
parent 10f4f09a34
commit 9f8cf0bf38
10 changed files with 35 additions and 15 deletions

View File

@ -1,5 +1,7 @@
<?php
define("APP_VERSION", "0.1-pre");
require_once __DIR__."/../vendor/autoload.php";
require_once __DIR__."/systemtest.php";
if (file_exists(__DIR__."/banner.php"))

View File

@ -2,6 +2,13 @@
if (!is_callable("gnupg_init")) {
fprintf(STDERR, "Error: The PHP GnuPG extension is not installed.\n\n");
fprintf(STDERR," * Debian/Ubuntu: Resolve with 'sudo apt-get install php5-gnupg' (or 'php7-gnupg')\n");
if (PHP_VERSION_ID >= 7) {
fprintf(STDERR, "Resolve using pecl:\n sudo pecl install gnupg-1.4.0RC1\n");
fprintf(STDERR, " echo 'extension=gnupg.so' | sudo tee /etc/php/7.0/mods-available/gnupg.ini\n");
fprintf(STDERR, " sudo phpenmod gnupg\n");
} else {
fprintf(STDERR," * Debian/Ubuntu: Resolve with 'sudo apt-get install php5-gnupg'\n");
fprintf(STDERR," * Any distro: Resolve with 'sudp pecl install gnupg', follow instructions to enable.\n");
}
die();
}