Skip to contentSkip to conversation

php: zlib and zip support

PATCH Superseded Joe Slater 4 participants 7 messages Aug 12, 2019 – Aug 14, 2019

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Joe Slater

author
#0 lore raw

PATCH 1/1 php: zlib and zip support

Add back zlib support. Define zip support but do not enable it.

---
 meta-oe/recipes-devtools/php/php.inc | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
meta-oe/recipes-devtools/php/php.inc +6 -1
index 33bcf12..08173ea 100644
@@ -59,7 +59,7 @@ EXTRA_OECONF = "--enable-mbstring \
                 --enable-fpm \
                 --with-libdir=${baselib} \
                 --with-gettext=${STAGING_LIBDIR}/.. \
-                --with-libzip=${STAGING_LIBDIR}/.. \
+                --with-zlib=${STAGING_LIBDIR}/.. \
                 --with-iconv=${STAGING_LIBDIR}/.. \
                 --with-bz2=${STAGING_DIR_TARGET}${exec_prefix} \
                 --with-config-file-path=${sysconfdir}/php/apache2-php${PHP_MAJOR_VERSION} \
@@ -81,6 +81,11 @@ PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \
 "
 PACKAGECONFIG_class-native = ""
 
+# For zip, select one or none.  oldzip uses a bundled library and is deprecated.
+#
+PACKAGECONFIG[newzip] = "--enable-zip --with-libzip=${STAGING_EXECPREFIXDIR},,libzip"
+PACKAGECONFIG[oldzip] = "--enable-zip --without-libzip,"
+
 PACKAGECONFIG[mysql] = "--with-mysql=${STAGING_DIR_TARGET}${prefix} \
                         --with-mysqli=${STAGING_BINDIR_CROSS}/mysql_config \
                         --with-pdo-mysql=${STAGING_BINDIR_CROSS}/mysql_config \
Signature · 1 line
2.7.4
#1 lore raw
Quoted 21 lines · Joe Slater

Add back zlib support. Define zip support but do not enable it.

---
 meta-oe/recipes-devtools/php/php.inc | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
meta-oe/recipes-devtools/php/php.inc +1 -1
index 33bcf12..08173ea 100644
@@ -59,7 +59,7 @@ EXTRA_OECONF = "--enable-mbstring \
                 --enable-fpm \
                 --with-libdir=${baselib} \
                 --with-gettext=${STAGING_LIBDIR}/.. \
-                --with-libzip=${STAGING_LIBDIR}/.. \
+                --with-zlib=${STAGING_LIBDIR}/.. \
                 --with-iconv=${STAGING_LIBDIR}/.. \
                 --with-bz2=${STAGING_DIR_TARGET}${exec_prefix} \
                 --with-config-file-path=${sysconfdir}/php/apache2-php${PHP_MAJOR_VERSION} \

meta-oe/recipes-devtools/php/php.inc PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ · line 85

Quoted 5 lines
meta-oe/recipes-devtools/php/php.inc +2 -0
@@ -81,6 +81,11 @@ PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \
 "
 PACKAGECONFIG_class-native = ""
 
+# For zip, select one or none.  oldzip uses a bundled library and is deprecated.
+#

How would I know which is old or new? is there a version ref we can mention? is it a gplv2 or gplv3 thing?

-armin

Quoted 6 lines
meta-oe/recipes-devtools/php/php.inc +3 -0
+PACKAGECONFIG[newzip] = "--enable-zip --with-libzip=${STAGING_EXECPREFIXDIR},,libzip"
+PACKAGECONFIG[oldzip] = "--enable-zip --without-libzip,"
+
 PACKAGECONFIG[mysql] = "--with-mysql=${STAGING_DIR_TARGET}${prefix} \
                         --with-mysqli=${STAGING_BINDIR_CROSS}/mysql_config \
                         --with-pdo-mysql=${STAGING_BINDIR_CROSS}/mysql_config \
#2 lore raw

Maybe the names are confusing. It's really use_libzip_zip vs use_bundled_zip. Joe

-----Original Message-----
From: akuster808 <[email protected]>
Sent: Monday, August 12, 2019 12:34 PM
To: Slater, Joseph <[email protected]>; [email protected]
Subject: Re: [oe] [meta-oe][PATCH 1/1] php: zlib and zip support

Quoted 25 lines · Joe Slater

Add back zlib support. Define zip support but do not enable it.

---
 meta-oe/recipes-devtools/php/php.inc | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
meta-oe/recipes-devtools/php/php.inc +1 -2
index 33bcf12..08173ea 100644
@@ -59,7 +59,7 @@ EXTRA_OECONF = "--enable-mbstring \
                 --enable-fpm \
                 --with-libdir=${baselib} \
                 --with-gettext=${STAGING_LIBDIR}/.. \
-                --with-libzip=${STAGING_LIBDIR}/.. \
+                --with-zlib=${STAGING_LIBDIR}/.. \
                 --with-iconv=${STAGING_LIBDIR}/.. \
                 --with-bz2=${STAGING_DIR_TARGET}${exec_prefix} \
 
--with-config-file-path=${sysconfdir}/php/apache2-php${PHP_MAJOR_VERSI

ON} \ @@ -81,6 +81,11 @@ PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ "
PACKAGECONFIG_class-native = ""

meta-oe/recipes-devtools/php/php.inc PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ · line 85

Quoted 2 lines
meta-oe/recipes-devtools/php/php.inc +2 -0
+# For zip, select one or none.  oldzip uses a bundled library and is deprecated.
+#

How would I know which is old or new? is there a version ref we can mention? is it a gplv2 or gplv3 thing?

-armin

Quoted 7 lines
meta-oe/recipes-devtools/php/php.inc +3 -1
+PACKAGECONFIG[newzip] = "--enable-zip --with-libzip=${STAGING_EXECPREFIXDIR},,libzip"
+PACKAGECONFIG[oldzip] = "--enable-zip --without-libzip,"
+
 PACKAGECONFIG[mysql] = "--with-mysql=${STAGING_DIR_TARGET}${prefix} \
                         --with-mysqli=${STAGING_BINDIR_CROSS}/mysql_config \
 
--with-pdo-mysql=${STAGING_BINDIR_CROSS}/mysql_config \
#3 lore raw
Quoted 41 lines · Joseph

Maybe the names are confusing. It's really use_libzip_zip vs use_bundled_zip. Joe

-----Original Message-----
From: akuster808 <[email protected]>
Sent: Monday, August 12, 2019 12:34 PM
To: Slater, Joseph <[email protected]>; [email protected]
Subject: Re: [oe] [meta-oe][PATCH 1/1] php: zlib and zip support

Quoted 25 lines · Joe Slater

Add back zlib support. Define zip support but do not enable it.

---
  meta-oe/recipes-devtools/php/php.inc | 7 ++++++-
  1 file changed, 6 insertions(+), 1 deletion(-)
meta-oe/recipes-devtools/php/php.inc +1 -2
index 33bcf12..08173ea 100644
@@ -59,7 +59,7 @@ EXTRA_OECONF = "--enable-mbstring \
                  --enable-fpm \
                  --with-libdir=${baselib} \
                  --with-gettext=${STAGING_LIBDIR}/.. \
-                --with-libzip=${STAGING_LIBDIR}/.. \
+                --with-zlib=${STAGING_LIBDIR}/.. \
                  --with-iconv=${STAGING_LIBDIR}/.. \
                  --with-bz2=${STAGING_DIR_TARGET}${exec_prefix} \
 
--with-config-file-path=${sysconfdir}/php/apache2-php${PHP_MAJOR_VERSI

ON} \ @@ -81,6 +81,11 @@ PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ "
PACKAGECONFIG_class-native = ""

meta-oe/recipes-devtools/php/php.inc PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ · line 85

Quoted 2 lines
meta-oe/recipes-devtools/php/php.inc +2 -0
+# For zip, select one or none.  oldzip uses a bundled library and is deprecated.
+#

How would I know which is old or new? is there a version ref we can mention? is it a gplv2 or gplv3 thing?

Quoted 4 lines

-armin

meta-oe/recipes-devtools/php/php.inc PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ · line 88

Quoted 3 lines
meta-oe/recipes-devtools/php/php.inc +3 -0
+PACKAGECONFIG[newzip] = "--enable-zip --with-libzip=${STAGING_EXECPREFIXDIR},,libzip"
+PACKAGECONFIG[oldzip] = "--enable-zip --without-libzip,"
+

maybe it should be called bundled-libzip and system-libzip maybe for clarity. What happens if someone enables both packageconfigs?

Quoted 5 lines
Quoted 4 lines
  PACKAGECONFIG[mysql] = "--with-mysql=${STAGING_DIR_TARGET}${prefix} \
                          --with-mysqli=${STAGING_BINDIR_CROSS}/mysql_config \

--with-pdo-mysql=${STAGING_BINDIR_CROSS}/mysql_config \

#4 lore raw
In reply to Joe Slater

meta-oe/recipes-devtools/php/php.inc PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ · line 87

Quoted 7 lines · Joe Slater

Add back zlib support. Define zip support but do not enable it.
...

meta-oe/recipes-devtools/php/php.inc +4 -0
+# For zip, select one or none.  oldzip uses a bundled library and is deprecated.
+#
+PACKAGECONFIG[newzip] = "--enable-zip --with-libzip=${STAGING_EXECPREFIXDIR},,libzip"
+PACKAGECONFIG[oldzip] = "--enable-zip --without-libzip,"
...

Any reason why this can't be PACKAGECONFIG[zip] for the external libzip only without any option for the bundled library?

Bundled libraries are usually behind on security fixes, and php is a software where this tends to matter.

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#5 lore raw

That's probably best. The bundled way won't be supported at some future date, anyway. Joe

-----Original Message-----
From: Adrian Bunk <[email protected]>
Sent: Monday, August 12, 2019 9:50 PM
To: Slater, Joseph <[email protected]>
Cc: [email protected]
Subject: Re: [oe] [meta-oe][PATCH 1/1] php: zlib and zip support

meta-oe/recipes-devtools/php/php.inc PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ · line 87

Quoted 7 lines · Joe Slater

Add back zlib support. Define zip support but do not enable it.
...

meta-oe/recipes-devtools/php/php.inc +4 -0
+# For zip, select one or none.  oldzip uses a bundled library and is deprecated.
+#
+PACKAGECONFIG[newzip] = "--enable-zip --with-libzip=${STAGING_EXECPREFIXDIR},,libzip"
+PACKAGECONFIG[oldzip] = "--enable-zip --without-libzip,"
...

Any reason why this can't be PACKAGECONFIG[zip] for the external libzip only without any option for the bundled library?

Bundled libraries are usually behind on security fixes, and php is a software where this tends to matter.

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#6 lore raw
Quoted 2 lines · Joseph

That's probably best. The bundled way won't be supported at some future date, anyway. Joe

I think so too. Would you send a v2 ?

Quoted 23 lines

-----Original Message-----
From: Adrian Bunk <[email protected]>
Sent: Monday, August 12, 2019 9:50 PM
To: Slater, Joseph <[email protected]>
Cc: [email protected]
Subject: Re: [oe] [meta-oe][PATCH 1/1] php: zlib and zip support

meta-oe/recipes-devtools/php/php.inc PACKAGECONFIG ??= "mysql sqlite3 imap opcache openssl \ · line 87

Quoted 7 lines · Joe Slater

Add back zlib support. Define zip support but do not enable it.
...

meta-oe/recipes-devtools/php/php.inc +4 -0
+# For zip, select one or none.  oldzip uses a bundled library and is deprecated.
+#
+PACKAGECONFIG[newzip] = "--enable-zip --with-libzip=${STAGING_EXECPREFIXDIR},,libzip"
+PACKAGECONFIG[oldzip] = "--enable-zip --without-libzip,"
...

Any reason why this can't be PACKAGECONFIG[zip] for the external libzip only without any option for the bundled library?

Bundled libraries are usually behind on security fixes, and php is a software where this tends to matter.

cu
Adrian