John Davidson

openssl - How I can fixed build in installing php 7.4?

0 comments
Message:


I try to install php 7.4 in command phpbrew install 7.4, but build is failed
I try to reinstall openssl, reinstall libraries and all links about this problem in google.


build log:


===> phpbrew will now build 7.4.25
You haven't enabled any variants. The default variant will be enabled:
[bcmath, bz2, calendar, cli, ctype, dom, fileinfo, filter, ipc, json, mbregex, mbstring, mhash, pcntl, pcre, pdo, pear, phar, posix, readline, sockets, tokenizer, xml, curl, openssl, zip]
Please run 'phpbrew variants' for more information.

===> Loading and resolving variants...
Checking distribution checksum...
Checksum matched: 27992570caf3e2e5323ab7b37853c44c1529b1d31ea94d9776efa91d5a781313
===> Distribution file was successfully extracted, skipping...
Found existing Makefile, running make clean to ensure everything will be rebuilt.
You can append --no-clean option after the install command if you don't want to rebuild.
===> Running make clean: /usr/bin/make -C '/Users/i.pishchylin/.phpbrew/build/php-7.4.25' --quiet 'clean'
===> Checking patches...
Checking patch for replace apache php module name with custom version name
Checking patch for replace freetype-config with pkg-config on php older than 7.4
Found existing build.log, renaming it to /Users/i.pishchylin/.phpbrew/build/php-7.4.25/build.log.1635245534
===> Configuring 7.4.25...


Use tail command to see what's going on:
$ tail -F '/Users/i.pishchylin/.phpbrew/build/php-7.4.25/build.log'


===> Checking patches...
Checking patch for php5.3.x on 64bit machine when intl is enabled.
Checking patch for openssl dso linking patch
2 changes patched.
Checking patch for php5.6 with openssl 1.1.x patch.
===> Building...
Error: Make failed:
The last 5 lines in the log file:
/usr/local/Cellar/openssl@3/3.0.0_1/include/openssl/rsa.h:289:29: note: passing argument to parameter 'rsa' here

RSA *rsa, int padding);

^

108 warnings and 1 error generated.

make: *** [ext/openssl/openssl.lo] Error 1

Please checkout the build log file for more details:
tail /Users/i.pishchylin/.phpbrew/build/php-7.4.25/build.log

tail /Users/i.pishchylin/.phpbrew/build/php-7.4.25/build.log:


#     define OSSL_DEPRECATED(since) __attribute__((deprecated))
^
/Users/i.pishchylin/.phpbrew/build/php-7.4.25/ext/openssl/openssl.c:5960:6: warning: passing 'const struct rsa_st *' to parameter of type 'RSA *' (aka 'struct rsa_st *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
EVP_PKEY_get0_RSA(pkey),
^~~~~~~~~~~~~~~~~~~~~~~
/usr/local/Cellar/openssl@3/3.0.0_1/include/openssl/rsa.h:289:29: note: passing argument to parameter 'rsa' here
RSA *rsa, int padding);
^
108 warnings and 1 error generated.
make: *** [ext/openssl/openssl.lo] Error 1

I try install with [email protected], but it version is too old. How i can fixed this?



My Answer:
It looks like the build is failing due to compatibility issues with OpenSSL. One possible solution is to try installing an older version of OpenSSL that is compatible with PHP 7.4. You can try installing OpenSSL 1.1.x or another version that is known to work with PHP 7.4.

You can also try updating your OpenSSL installation to the latest version and then attempting to build PHP 7.4 again. Make sure to follow the installation instructions for OpenSSL carefully to ensure that it is properly installed and configured.

If the issue persists, you may need to look for specific patches or fixes for OpenSSL compatibility with PHP 7.4. You can search for any known issues or solutions on forums, GitHub repositories, or other sources where developers discuss similar problems.

Additionally, you can try reaching out to the PHP community or the maintainers of PHPBrew for further assistance with resolving the build issue. They may have more insights or recommendations on how to fix the problem.

Rate this post

5 of 5 based on 5136 votes

Comments




© 2024 Hayatsk.info - Personal Blogs Platform. All Rights Reserved.
Create blog  |  Privacy Policy  |  Terms & Conditions  |  Contact Us