-
Notifications
You must be signed in to change notification settings - Fork 281
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add php-8.4 modules #34683
Add php-8.4 modules #34683
Conversation
Gen AI suggestions to solve the build error: • Detected Error:
• Error Category: Build/Compilation • Failure Point: C compilation of imagick.c during make install • Root Cause Analysis: • Suggested Fix:
#include "ext/standard/php_string.h"
zend_str_tolower(Z_STRVAL_P(retval), Z_STRLEN_P(retval)); • Explanation: • Additional Notes:
• References:
Submit a patch to the Imagick repository to fix this compatibility issue with PHP 8.4, as this is likely affecting other users trying to build with PHP 8.4 as well. |
Gen AI suggestions to solve the build error: • Detected Error: "error getting package dependencies: solving 'php-8.4-igbinary-dev' constraint: could not find package that provides php-8.4-igbinary-dev in indexes" • Error Category: Dependency • Failure Point: Environment setup phase when trying to install build dependencies • Root Cause Analysis: The build is failing because it cannot find the php-8.4-igbinary-dev package in the configured repositories. PHP 8.4 is currently in development/alpha, so its extensions and development packages may not be available yet. • Suggested Fix:
- name: Configure
runs: ./configure --disable-memcached-igbinary • Explanation: The igbinary extension is an optional serializer for memcached. Since PHP 8.4 is still in development, we can build the memcached extension without igbinary support initially. This will allow the package to build while waiting for the igbinary extension to become available for PHP 8.4. • Additional Notes:
• References:
|
Gen AI suggestions to solve the build error: • Detected Error:
• Error Category: Dependency/Build Configuration • Failure Point: Compilation of php_http_misc.c and php_http_message_body.c failing due to missing header file • Root Cause Analysis: • Suggested Fix: environment:
contents:
packages:
- php-${{vars.phpMM}}-dev
- php-${{vars.phpMM}}-dev-standard # Add this line • Explanation: • Additional Notes:
• References:
|
Gen AI suggestions to solve the build error: • Detected Error:
• Error Category: Dependency/Build • Failure Point: Compilation of mcrypt.c during make step • Root Cause Analysis: The build is failing because it cannot find the PHP standard extension header file php_rand.h. This typically means the PHP development files are not properly installed or the include paths are not correctly set. • Suggested Fix:
environment:
contents:
packages:
- php-${{vars.phpMM}}-dev
- php-${{vars.phpMM}}-standard-dev # Add this line • Explanation: • Additional Notes:
• References:
|
Gen AI suggestions to solve the build error: • Detected Error: "error getting package dependencies: solving 'php-8.4-igbinary-dev' constraint: could not find package that provides php-8.4-igbinary-dev in indexes" • Error Category: Dependency • Failure Point: Environment setup phase when installing build dependencies • Root Cause Analysis: The build is failing because it cannot find the php-8.4-igbinary-dev package in the configured repositories. This is likely because PHP 8.4 is still in development/alpha and not yet available in the Wolfi repositories. • Suggested Fix:
vars:
phpMM: "8.3"
phpPriority: 803
package:
name: php-8.3-redis • Explanation: PHP 8.4 is currently in development (alpha stage) and its packages are not yet available in Wolfi repositories. PHP 8.3 is the latest stable version and should be used instead. The redis extension is compatible with PHP 8.3, and this change will allow the package to build successfully. • Additional Notes:
• References:
|
Gen AI suggestions to solve the build error: Based on the build error output, I'll provide a detailed analysis and solution: • Detected Error:
• Error Category: Build/Dependency • Failure Point: Compilation of swoole extension source files • Root Cause Analysis:
• Suggested Fix: environment:
contents:
packages:
- autoconf
- brotli-dev
- build-base
- busybox
- php-${{vars.phpMM}}
- php-${{vars.phpMM}}-dev
- php-pecl-dev # Add this
- php-dev # Add this
- libc-dev # Add this
- linux-headers # Add this • Explanation: • Additional Notes:
- name: Configure
runs: |
set -x
./configure --enable-swoole-curl --enable-http2 --enable-sockets --enable-openssl • References:
Would you like me to provide any additional details about any part of this solution? |
Gen AI suggestions to solve the build error: • Detected Error: "configure: error: not supported. Need a PHP version >= 8.0.0 and < 8.4.0 (found 8.4.0)" • Error Category: Version/Compatibility • Failure Point: Configure step during build process • Root Cause Analysis: The xdebug 3.3.2 package has explicit version constraints that don't support PHP 8.4.0. The package currently only supports PHP versions from 8.0.0 up to, but not including, 8.4.0. • Suggested Fix:
package:
name: php-8.3-xdebug
# ... other fields remain same
vars:
phpMM: "8.3" • Explanation: • Additional Notes:
• References:
|
Gen AI suggestions to solve the build error: Based on the build output, I don't actually see any errors - the build appears to have completed successfully. The package was built and the APK files were generated without any failures. Let me break this down: • Detected Error: None - the build completed successfully
The only minor warning in the output was:
But this is harmless as it just means the directory already existed. If you're seeing a CI failure, it may be:
Could you share the specific CI failure message you're seeing? That would help identify if there's an actual issue that needs to be addressed. Additional Notes:
|
Gen AI suggestions to solve the build error: Based on the build log, I don't actually see any build errors - the build appears to have completed successfully. The package was built and the APK files were generated without any failures. • Detected Error: None - build completed successfully
• Suggested Fix: No fix needed as there is no error to resolve. The package built successfully. • Explanation: The build log shows:
• Additional Notes:
• References: N/A If you're seeing a failure in CI that isn't shown in this build log, please provide that error message for further analysis. |
Gen AI suggestions to solve the build error: Based on the build log, I don't actually see a build error - the build appears to have completed successfully. The log shows the package was built and the APK files were generated correctly: • Built packages:
The only minor warning in the log was:
But this didn't affect the build outcome since it completed successfully. If you're seeing a CI failure, it may be:
Could you please share the specific CI failure message you're seeing? That would help identify the actual issue that needs to be addressed. Additional Notes:
Without seeing the actual error message from CI, I can't provide more specific guidance on what needs to be fixed. |
Gen AI suggestions to solve the build error: • Detected Error: • Error Category: Dependency • Failure Point: Pipeline step during execution of • Root Cause Analysis: The build environment is missing the bash shell which is required to execute the packagize.sh script. While busybox provides a basic shell, the script specifically requires bash. • Suggested Fix: Add bash to the environment packages list: environment:
contents:
packages:
- autoconf
- automake
- bash # Add this line
- binutils
- build-base
[...] • Explanation: The packagize.sh script uses bash-specific features and has a bash shebang. Adding bash as a build dependency will provide the required shell interpreter for executing the script. • Additional Notes:
• References:
|
Gen AI suggestions to solve the build error: Based on the build log, I don't see any actual build errors - the build appears to have completed successfully. The packages were built and indexed without errors. • Detected Error: None - the build completed successfully
• Suggested Fix: No fix needed as the build was successful. The output shows:
• Explanation: The build log shows all steps completed without errors:
• Additional Notes:
If you're seeing a CI failure, it may be in another part of the pipeline not shown in this build log, as the actual package build process completed successfully. |
Gen AI suggestions to solve the build error: • Detected Error: "could not find package that provides php-8.4-igbinary-dev in indexes" • Error Category: Dependency • Failure Point: Environment setup phase when trying to install build dependencies • Root Cause Analysis: The build is failing because it cannot find the php-8.4-igbinary-dev package in the configured repositories. This is likely because PHP 8.4 is still in development/alpha and the igbinary extension hasn't been built for it yet. • Suggested Fix:
environment:
contents:
packages:
- autoconf
- build-base
- busybox
- libmemcached-dev
- php-${{vars.phpMM}}
- php-${{vars.phpMM}}-dev
- zlib-dev • Explanation: • Additional Notes:
- name: Configure
runs: ./configure --disable-memcached-igbinary • References:
|
Gen AI suggestions to solve the build error: • Detected Error: "failed to build package: unable to build guest: unable to generate image: installing apk packages: error getting package dependencies: solving "php-8.4-igbinary-dev" constraint: could not find package that provides php-8.4-igbinary-dev in indexes" • Error Category: Dependency • Failure Point: Environment setup phase when installing build dependencies • Root Cause Analysis: The build system cannot find the php-8.4-igbinary-dev package in the configured repositories. This is likely because PHP 8.4 is still in development/alpha and the igbinary extension hasn't been built for it yet. • Suggested Fix:
package:
name: php-8.3-redis
version: 6.1.0 And update all references from 8.4 to 8.3 in the environment and dependencies sections. • Explanation:
• Additional Notes:
• References:
|
These were split from wolfi-dev#34683 due to failing to pass c-i. that seemed to be due to the fact that these two packages depend on php-8.4-igbinary. They're just copy and 'sed'it from the php-8.3-<module> name.
``` for p in php-8.3-*.yaml; do sed -e 's,epoch: .*,epoch: 0,' -e 's,name: php-8.3-,name: php-8.4-,' \ "$p" > php-8.4${p#php-8.3}; done ```
These are split into wolfi-dev#34897
Grab php/pecl-encryption-mcrypt#19 which just uses php_mt_rand_range rather than now-removed php_rand.
Several changes would be needed to make the 5.1.5 version of swoole build with php 8.4. Upstream explicitly removed support from the 5.1 branch swoole/swoole-src#5525 There is likely 6.0.0 release coming soon (beta released 2024-10-17). We will have to manually re-add at that point in time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I diff'd the modules that exist for both 8.3 and 8.4 and those changes look straightfoward. I didn't double-check the cherry-picks, but I trust the given justifications.
These were split from #34683 due to failing to pass c-i. that seemed to be due to the fact that these two packages depend on php-8.4-igbinary. They're just copy and 'sed'it from the php-8.3-<module> name.
First, just add the modules, copying from 8.3 versions.
Then fix some to build with 8.4, cherry picking from upstream.
php-8.4-pecl-mcrypt - cherry-pick a PR to build for 8.4
Grab use php_mt_rand_range for 8.4 php/pecl-encryption-mcrypt#19
which just uses php_mt_rand_range rather than now-removed php_rand.
php-8.4-imagick - cherry pick pr to build for 8.4
Grab Fix removed "php_strtolower" for PHP 8.4 Imagick/imagick#690
to replace php_strlower with zend_str_tolower
php-8.4-xdebug - cherry pick several upstream changes
NOTE: I have very low confidence in this, other than it builds.
xdebug is active and likely to release a 3.4.0 release soon
that has php 8.4 support properly.
By adding php-8.4-xdebug with updates enabled, we will get
a PR automatically made and hopefully landed just by dropping
the cherry-picks here.
Drop php-8.4-swoole - not supported upstream yet.
Several changes would be needed to make the 5.1.5
version of swoole build with php 8.4.
Upstream explicitly removed support from
the 5.1 branch [5.1]remove php8.4 support swoole/swoole-src#5525
There is likely 6.0.0 release coming soon (beta released 2024-10-17).
We will have to manually re-add at that point in time.
php-8.4-memcached and php-8.4-redis are separated out to another PR
as they are dependent on php-8.4-igbinary output.