1 (edited by fredbradley 2020-07-14 15:48:24)

Topic: PHP ZIP (7.3 conflict with 7.4?)

Hello,

I've just followed the guide here: https://www.linuxtechi.com/install-php- … -7-server/ to upgrade my PHP from 7.2 to 7.4.

I've managed to install all but one of the extensions I need.

Each time I try
`yum install php-zip`

It responds:
`Package php73-common-7.3.19-1.el7.ius.x86_64 is obsoleted by php-common-7.4.8-2.el7.remi.x86_64 which is already installed`

It's as if it's looking for the 7.3 version of ZIP and not the 7.4 version?

Is this known and how can I get around the issue?

And for those that point me in the direction of self-compiling with PECL, I've tried an answer on StackOverflow (61831490/4299536) but it won't install. Output below

[root@server]# pecl install zip
downloading zip-1.19.0.tgz ...
Starting to download zip-1.19.0.tgz (325,123 bytes)
..................................................................done: 325,123 bytes
19 source files, building
running: phpize
Configuring for:
PHP Api Version:         20190902
Zend Module Api No:      20190902
Zend Extension Api No:   320190902
building in /var/tmp/pear-build-root4SDHC5/zip-1.19.0
running: /var/tmp/zip/configure --with-php-config=/usr/bin/php-config
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for a sed that does not truncate output... /usr/bin/sed
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cc -E
checking for icc... no
checking for suncc... no
checking for system library directory... lib
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
checking for PHP prefix... /usr
checking for PHP includes... -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib
checking for PHP extension directory... /usr/lib64/php/modules
checking for PHP installed headers prefix... /usr/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for gawk... gawk
checking for zip archive read/writesupport... yes, shared
checking libzip... yes
checking PHP version... 7.4
checking for pkg-config... /usr/bin/pkg-config
checking for libzip... configure: error: system libzip must be upgraded to version >= 0.11
ERROR: `/var/tmp/zip/configure --with-php-config=/usr/bin/php-config' failed

Re: PHP ZIP (7.3 conflict with 7.4?)

> `Package php73-common-7.3.19-1.el7.ius.x86_64 is obsoleted by php-common-7.4.8-2.el7.remi.x86_64 which is already installed`

You have 2 providers for PHP "IUS" and "remi", which raise this issue

Disable IUS.
Also check that "remi-php74" is enabled.

Full yum output may help

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: PHP ZIP (7.3 conflict with 7.4?)

Just a quicky to say: thankyou. I hadn't realised that it was trying to update from IUS first. Disabling IUS sorted me out.

Re: PHP ZIP (7.3 conflict with 7.4?)

smile

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi