Skip to content

Migrate PHP extensions from PECL to Ubuntu packages - #2780

Merged
enoch85 merged 6 commits into
mainfrom
migrate-pecl-to-os-packages
May 5, 2026
Merged

enoch85 merged 6 commits into
mainfrom
migrate-pecl-to-os-packages

Conversation

@enoch85

@enoch85 enoch85 commented Nov 4, 2025

Copy link
Copy Markdown
Member

Replace PECL-based installation of redis, igbinary, and smbclient with native Ubuntu packages for easier maintenance and better stability.

Changes:

  • Replace PECL redis with php8.3-redis (5.3.7+4.3.0)
  • Replace PECL igbinary with php8.3-igbinary (3.2.13)
  • Replace PECL smbclient with php8.3-smbclient (1.0.6)
  • Remove build dependencies (php-dev, libsmbclient-dev)
  • Add migration logic in update script for existing installations
  • Simplify installation code (remove manual .ini creation)

Benefits:

  • Automatic updates via apt
  • No build failures
  • Faster installation (no compilation)
  • Automatic security updates from Ubuntu Security Team
  • Reduced code complexity (-109 lines, 87% reduction)
  • Save ~50MB disk space (no build dependencies)

The update script handles migration from PECL to OS packages automatically for existing installations while maintaining backward compatibility.

Fixes: Simplifies maintenance and improves reliability

Replace PECL-based installation of redis, igbinary, and smbclient
with native Ubuntu packages for easier maintenance and better stability.

Changes:
- Replace PECL redis with php8.3-redis (5.3.7+4.3.0)
- Replace PECL igbinary with php8.3-igbinary (3.2.13)
- Replace PECL smbclient with php8.3-smbclient (1.0.6)
- Remove build dependencies (php-dev, libsmbclient-dev)
- Add migration logic in update script for existing installations
- Simplify installation code (remove manual .ini creation)

Benefits:
- Automatic updates via apt
- No build failures
- Faster installation (no compilation)
- Automatic security updates from Ubuntu Security Team
- Reduced code complexity (-109 lines, 87% reduction)
- Save ~50MB disk space (no build dependencies)

The update script handles migration from PECL to OS packages
automatically for existing installations while maintaining
backward compatibility.

Fixes: Simplifies maintenance and improves reliability
@enoch85
enoch85 marked this pull request as ready for review November 6, 2025 10:24
@enoch85

enoch85 commented May 5, 2026

Copy link
Copy Markdown
Member Author

@copilot resolve the merge conflicts in this pull request

Resolve merge conflicts in nextcloud_update.sh:
- Keep PECL→OS migration code for redis, igbinary, smbclient
- Remove superseded PECL upgrade code for redis, igbinary, smbclient
- Preserve inotify PECL upgrade (not migrated to OS package)

Co-authored-by: enoch85 <[email protected]>

Copilot AI commented May 5, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Merge conflicts resolved in commit f59b6bc. The conflict in nextcloud_update.sh was resolved by:

  • Keeping our PECL→OS migration code for redis, igbinary, and smbclient
  • Removing the now-superseded PECL upgrade code for those extensions from main
  • Preserving the inotify PECL upgrade from main (since inotify is not being migrated to an OS package)

Copilot finished work on behalf of enoch85 May 5, 2026 18:49
@enoch85
enoch85 merged commit b302362 into main May 5, 2026
9 of 10 checks passed
@enoch85
enoch85 deleted the migrate-pecl-to-os-packages branch May 5, 2026 19:01
enoch85 added a commit that referenced this pull request Jul 8, 2026
Ubuntu ships inotify as an OS package since 25.10 (php8.5-inotify on
26.04), so prefer that over building with PECL. On Ubuntu 24.04 the
package doesn't exist, so keep the PECL path there, but install php-dev
first - it was removed from the base installation in #2780, which made
'pecl install inotify' fail when enabling inotify for an SMB mount.

No third-party repository (sury.org) is needed.

Fixes #2827
enoch85 added a commit that referenced this pull request Jul 8, 2026
Ubuntu ships inotify as an OS package since 25.10 (php8.5-inotify on
26.04), so prefer that over building with PECL. On Ubuntu 24.04 the
package doesn't exist, so keep the PECL path there, but install php-dev
first - it was removed from the base installation in #2780, which made
'pecl install inotify' fail when enabling inotify for an SMB mount.

No third-party repository (sury.org) is needed.

Fixes #2827
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants