Author Topic: PHP compiling fails, strange ld / ldconfig behaviour?  (Read 55 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
PHP compiling fails, strange ld / ldconfig behaviour?
« on: July 09, 2025, 11:04:46 AM »
Hello,
since i am trying to fix my troubles with recompiling different php versions in CWPpro, i maybe found some strange things.

I always get error-messages in the php build logs like "bz2" not found.

So i tried to "ld -libbz2 --verbose" and see
Code: [Select]
attempt to open //usr/lib64/libibbz2.so
So libibbz2.so is definiteley not installed, because there is no libibbz2 lib, right?

I tested with other libs like librt, and found out, that ld is also searching for the libIBrt.so file? Where is this coming from and
how to fix that?
Code: [Select]
attempt to open //usr/lib64/libibrt.so failed
OS: AlmaLinux 8


Update:
The output of ldconfig is correct...
Code: [Select]
[root@s1 ~]# ldconfig -p | grep bz2
        libbz2.so.1 (libc6,x86-64) => /usr/lib64/libbz2.so.1
        libbz2.so (libc6,x86-64) => /usr/lib64/libbz2.so


Thank you very much,
regards
« Last Edit: July 09, 2025, 11:13:03 AM by crouso »

Offline
*****
Re: PHP compiling fails, strange ld / ldconfig behaviour?
« Reply #1 on: July 09, 2025, 12:20:11 PM »
What is your end goal? Which mode are you going to use -- PHP switcher, suPHP, or php-fpm? Which versions of PHP would you like to have? Each case is a bit different.

Offline
*
Re: PHP compiling fails, strange ld / ldconfig behaviour?
« Reply #2 on: July 09, 2025, 07:54:27 PM »
Thank you for your reply.

What is your end goal? Which mode are you going to use -- PHP switcher, suPHP, or php-fpm? Which versions of PHP would you like to have? Each case is a bit different.

PHP switcher also did not work correctly, i tried it, same error messages in logfile regarding bz2... seems i am stuck at 7.4.33?

My end goal/s would be to (depends on solution/s)
- keep PHP 7.4.33 for compatibility issues as "base version"
- be able to compile (php >8.2 needed) other versions with php selector
- and maybe php-fpm selector too

Or a way how i can add alternate php versions manually?

Offline
*****
Re: PHP compiling fails, strange ld / ldconfig behaviour?
« Reply #3 on: July 09, 2025, 11:19:43 PM »
If you want to PM me login details, I could take a look for you. I recommend PHP-FPM for performance reasons, plus the versatility of running php versions on a site-by-site basis with separate configs is a good thing. I have 4 versions running on one server -- legacy 5.6 for one site, 7.4 for a WordPress site that needs full compatibility, 8.1 for other WP sites, and 8.2 for a Drupal site.