Skip to content

Commit 7ca01bc

Browse files
committed
Simplify FTP SSL configuration option
This simply makes default to `ON` as having FTP SSL is kind of a norm. And it also makes configuring FTP extension one step simpler on the expense of OpenSSL library dependency.
1 parent 3bc4c9c commit 7ca01bc

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

cmake/ext/ftp/CMakeLists.txt

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,10 @@ Build extension as shared.
2121
2222
## PHP_EXT_FTP_SSL
2323
24-
* Default: `OFF`
24+
* Default: `ON`
2525
* Values: `ON|OFF`
2626
27-
Explicitly enable FTP over SSL support when building without openssl extension
28-
(`PHP_EXT_OPENSSL=OFF`) or when using `phpize`. If the `openssl` extension is
29-
enabled at the configure step (`PHP_EXT_OPENSSL=ON`), FTP-SSL is enabled
30-
implicitly regardless of this option.
27+
Explicitly enable or disable FTP over SSL support.
3128
#]=============================================================================]
3229

3330
cmake_minimum_required(VERSION 3.25...3.31)
@@ -58,10 +55,9 @@ cmake_dependent_option(
5855

5956
cmake_dependent_option(
6057
PHP_EXT_FTP_SSL
61-
"Explicitly enable FTP over SSL support when building without openssl\
62-
extension (PHP_EXT_OPENSSL=OFF) or when using phpize."
63-
OFF
64-
"PHP_EXT_FTP;NOT PHP_EXT_OPENSSL"
58+
"Explicitly enable FTP over SSL support."
59+
ON
60+
"PHP_EXT_FTP"
6561
OFF
6662
)
6763

@@ -83,7 +79,7 @@ target_sources(
8379
php_ftp.c
8480
)
8581

86-
if(PHP_EXT_FTP_SSL OR PHP_EXT_OPENSSL)
82+
if(PHP_EXT_FTP_SSL)
8783
find_package(OpenSSL ${PHP_OPENSSL_MIN_VERSION} COMPONENTS SSL)
8884
set_package_properties(
8985
OpenSSL

0 commit comments

Comments
 (0)