2005-12-05 04:35:38 +08:00
|
|
|
// $Id$
|
|
|
|
// vim:ft=javascript
|
|
|
|
|
2009-07-26 10:19:58 +08:00
|
|
|
ARG_ENABLE("phar", "disable phar support", "yes");
|
2008-08-01 21:45:06 +08:00
|
|
|
ARG_ENABLE("phar-native-ssl", "enable phar with native OpenSSL support", "no");
|
|
|
|
|
|
|
|
if (PHP_PHAR_NATIVE_SSL != "no") {
|
|
|
|
PHP_PHAR = PHP_PHAR_NATIVE_SSL;
|
|
|
|
}
|
2005-12-05 04:35:38 +08:00
|
|
|
|
|
|
|
if (PHP_PHAR != "no") {
|
2008-01-28 22:39:17 +08:00
|
|
|
EXTENSION("phar", "dirstream.c func_interceptors.c phar.c phar_object.c phar_path_check.c stream.c tar.c util.c zip.c");
|
2009-03-01 15:07:14 +08:00
|
|
|
if (PHP_PHAR_SHARED || (PHP_PHAR_NATIVE_SSL_SHARED && PHP_SNAPSHOT_BUILD == "no")) {
|
2008-01-13 00:18:26 +08:00
|
|
|
ADD_FLAG("CFLAGS_PHAR", "/D COMPILE_DL_PHAR ");
|
|
|
|
}
|
2008-08-01 21:45:06 +08:00
|
|
|
if (PHP_PHAR_NATIVE_SSL != "no") {
|
|
|
|
if (CHECK_LIB("libeay32st.lib", "phar")) {
|
|
|
|
/* We don't really need GDI for this, but there's no
|
|
|
|
way to avoid linking it in the static openssl build */
|
|
|
|
ADD_FLAG("LIBS_PHAR", "libeay32st.lib gdi32.lib");
|
|
|
|
if (PHP_DEBUG == "no") {
|
|
|
|
/* Silence irrelevant-to-us warning in release builds */
|
|
|
|
ADD_FLAG("LDFLAGS_PHAR", "/IGNORE:4089 ");
|
|
|
|
}
|
|
|
|
AC_DEFINE('PHAR_HAVE_OPENSSL', 1);
|
|
|
|
STDOUT.WriteLine(' Native OpenSSL support in Phar enabled');
|
|
|
|
} else {
|
|
|
|
WARNING('Could not enable native OpenSSL support in Phar');
|
|
|
|
}
|
|
|
|
} else {
|
2008-09-01 04:54:28 +08:00
|
|
|
if (PHP_OPENSSL != "no" && !PHP_OPENSSL_SHARED && !PHP_PHAR_SHARED) {
|
2008-08-01 21:45:06 +08:00
|
|
|
AC_DEFINE('PHAR_HAVE_OPENSSL', 1);
|
2008-09-01 04:54:28 +08:00
|
|
|
STDOUT.WriteLine(' Native OpenSSL support in Phar enabled');
|
|
|
|
} else {
|
|
|
|
STDOUT.WriteLine(' Native OpenSSL support in Phar disabled');
|
2008-08-01 21:45:06 +08:00
|
|
|
}
|
|
|
|
}
|
2009-03-01 15:07:14 +08:00
|
|
|
if (PHP_HASH != "no") {
|
2009-05-11 14:42:06 +08:00
|
|
|
if (!PHP_HASH_SHARED) {
|
2009-03-01 15:07:14 +08:00
|
|
|
AC_DEFINE("PHAR_HASH_OK", 1);
|
|
|
|
} else {
|
|
|
|
WARNING('Phar: sha256/sha512 signature support disabled if ext/hash is built shared');
|
|
|
|
}
|
|
|
|
}
|
2007-12-22 03:02:20 +08:00
|
|
|
ADD_EXTENSION_DEP('phar', 'spl', true);
|
2005-12-05 04:35:38 +08:00
|
|
|
}
|