Skip to content

Sync HAVE_OPENSSL* symbols #14333

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

Merged
merged 1 commit into from
Jun 11, 2024
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
3 changes: 3 additions & 0 deletions UPGRADING.INTERNALS
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,9 @@ PHP 8.4 INTERNALS UPGRADE NOTES
- Unused symbols CONFIGURATION_FILE_PATH, DISCARD_PATH, HAVE_ERRMSG_H,
HAVE_REGCOMP, HAVE_RINT, NEED_ISBLANK, PHP_URL_FOPEN, REGEX, HSREGEX,
USE_CONFIG_FILE have been removed.
- The HAVE_OPENSSL symbol has been removed.
- The HAVE_OPENSSL_EXT symbol is now consistently defined to value 1 whether
the openssl extension is available either as shared or built statically.

========================
3. Module changes
Expand Down
3 changes: 1 addition & 2 deletions ext/openssl/config.w32
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ if (PHP_OPENSSL != "no") {

if (ret > 0) {
EXTENSION("openssl", "openssl.c xp_ssl.c");
AC_DEFINE("HAVE_OPENSSL_EXT", PHP_OPENSSL_SHARED ? 0 : 1, "Have openssl");
AC_DEFINE("HAVE_OPENSSL", 1);
AC_DEFINE("HAVE_OPENSSL_EXT", 1, "Define to 1 if the openssl extension is available.");
}
}
3 changes: 2 additions & 1 deletion ext/openssl/config0.m4
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ if test "$PHP_OPENSSL" != "no"; then
PHP_NEW_EXTENSION(openssl, openssl.c xp_ssl.c, $ext_shared)
PHP_SUBST(OPENSSL_SHARED_LIBADD)
PHP_SETUP_OPENSSL([OPENSSL_SHARED_LIBADD],
[AC_DEFINE([HAVE_OPENSSL_EXT], [1], [ ])])
[AC_DEFINE([HAVE_OPENSSL_EXT], [1],
[Define to 1 if the openssl extension is available.])])

AC_CHECK_FUNCS([RAND_egd])

Expand Down
2 changes: 1 addition & 1 deletion ext/openssl/php_openssl.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

#ifndef PHP_OPENSSL_H
#define PHP_OPENSSL_H
/* HAVE_OPENSSL would include SSL MySQL stuff */

#ifdef HAVE_OPENSSL_EXT
extern zend_module_entry openssl_module_entry;
#define phpext_openssl_ptr &openssl_module_entry
Expand Down
2 changes: 1 addition & 1 deletion sapi/cgi/cgi_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ int __riscosify_control = __RISCOSIFY_STRICT_UNIX_SPECS;
#include "fastcgi.h"
#include "cgi_main_arginfo.h"

#if defined(PHP_WIN32) && defined(HAVE_OPENSSL)
#if defined(PHP_WIN32) && defined(HAVE_OPENSSL_EXT)
# include "openssl/applink.c"
#endif

Expand Down
2 changes: 1 addition & 1 deletion sapi/cli/php_cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
# include "win32/select.h"
#endif

#if defined(PHP_WIN32) && defined(HAVE_OPENSSL)
#if defined(PHP_WIN32) && defined(HAVE_OPENSSL_EXT)
# include "openssl/applink.c"
#endif

Expand Down
2 changes: 1 addition & 1 deletion sapi/phpdbg/phpdbg.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@

#include "ext/standard/basic_functions.h"

#if defined(PHP_WIN32) && defined(HAVE_OPENSSL)
#if defined(PHP_WIN32) && defined(HAVE_OPENSSL_EXT)
# include "openssl/applink.c"
#endif

Expand Down
Loading