Skip to content

Cleanup & fix openssl handling in configure #5091

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

Closed
wants to merge 2 commits into from
Closed
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
8 changes: 1 addition & 7 deletions build/php.m4
Original file line number Diff line number Diff line change
Expand Up @@ -1917,13 +1917,7 @@ dnl
AC_DEFUN([PHP_SETUP_OPENSSL],[
found_openssl=no

dnl Empty variable means 'no'.
test -z "$PHP_OPENSSL" && PHP_OPENSSL=no
test -z "$PHP_IMAP_SSL" && PHP_IMAP_SSL=no

if test "$PHP_OPENSSL" != "no"; then
PKG_CHECK_MODULES([OPENSSL], [openssl >= 1.0.1], [found_openssl=yes])
fi
PKG_CHECK_MODULES([OPENSSL], [openssl >= 1.0.1], [found_openssl=yes])

if test "$found_openssl" = "yes"; then
PHP_EVAL_LIBLINE($OPENSSL_LIBS, $1)
Expand Down
7 changes: 4 additions & 3 deletions ext/ftp/config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ PHP_ARG_ENABLE([ftp],
[AS_HELP_STRING([--enable-ftp],
[Enable FTP support])])

dnl TODO: Rename this option for master.
PHP_ARG_WITH([openssl-dir],
[OpenSSL dir for FTP],
[AS_HELP_STRING([[--with-openssl-dir[=DIR]]],
[FTP: openssl install prefix])],
[whether to explicitly enable FTP SSL support],
[AS_HELP_STRING([[--with-openssl-dir]],
[FTP: Whether to enable FTP SSL support without ext/openssl])],
[no],
[no])
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After thinking about this a bit more, I don't think we can drop these, because they're the only way to force enable SSL support if you only want to build the ftp ext (without the openssl ext). This should probably be something like --with-ftp-ssl similar to the imap option.

But to avoid BC break for 7.4, we should probably just keep this as-is and just change the message to not talk about prefixes.


Expand Down
6 changes: 3 additions & 3 deletions ext/imap/config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ AC_DEFUN([PHP_IMAP_SSL_CHK], [
], [
AC_MSG_ERROR([OpenSSL libraries not found.

Check the path given to --with-openssl-dir and output in config.log)
Check whether openssl is on your PKG_CONFIG_PATH and the output in config.log)
])
])
elif test -f "$IMAP_INC_DIR/linkage.c"; then
Expand All @@ -100,8 +100,8 @@ PHP_ARG_WITH([kerberos],

PHP_ARG_WITH([imap-ssl],
[for IMAP SSL support],
[AS_HELP_STRING([[--with-imap-ssl[=DIR]]],
[IMAP: Include SSL support. DIR is the OpenSSL install prefix])],
[AS_HELP_STRING([[--with-imap-ssl]],
[IMAP: Include SSL support])],
[no],
[no])

Expand Down
7 changes: 0 additions & 7 deletions ext/snmp/config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,6 @@ PHP_ARG_WITH([snmp],
[AS_HELP_STRING([[--with-snmp[=DIR]]],
[Include SNMP support])])

PHP_ARG_WITH([openssl-dir],
[OpenSSL dir for SNMP],
[AS_HELP_STRING([[--with-openssl-dir[=DIR]]],
[SNMP: openssl install prefix])],
[no],
[no])

if test "$PHP_SNMP" != "no"; then

if test "$PHP_SNMP" = "yes"; then
Expand Down