Skip to content

fix(pdo-fbird): make split package self-contained#563

Merged
satwareAG-ironMike merged 1 commit into
mainfrom
fix/pdo-fbird-split-self-contained
Jul 21, 2026
Merged

fix(pdo-fbird): make split package self-contained#563
satwareAG-ironMike merged 1 commit into
mainfrom
fix/pdo-fbird-split-self-contained

Conversation

@satwareAG-ironMike

Copy link
Copy Markdown

Problem

pie install satwareag/pdo-fbird fails with:

fatal error: ../firebird_utils.h: No such file or directory

The pdo-fbird PIE package (split to satwareAG/pdo-fbird repo) references parent headers (../firebird_utils.h, ../php_firebird.h, etc.) that don't exist in the split repo.

Fix

Copy 5 shared headers + VERSION.txt into pdo_fbird/ directory so the split package is self-contained:

File Size Purpose
firebird_utils.h 54KB Utility function declarations
php_fbird_includes.h 23KB Core includes (types, macros, constants)
php_firebird.h 6KB Extension registration
fbird_classes.h 4KB OOP class declarations
fbird_service_types.h 1KB Service manager types
VERSION.txt 7B Version string (for config.m4)

Then changed all #include "../xxx.h" to #include "xxx.h" (local references).

Also rewrote config.m4:

  • Removed PHP_ADD_INCLUDE([$srcdir/..])
  • Changed $srcdir/../VERSION.txt to $srcdir/VERSION.txt

Verification

Split build (simulated PIE install)

cd /tmp/pdo-fbird-split/  # isolated copy with only pdo_fbird/ + headers
phpize && ./configure --with-pdo-fbird --with-firebird=/usr && make
# => Build complete. modules/pdo_fbird.so created

In-tree build (main repo)

phpize && ./configure --with-firebird=/usr && make
# => Both firebird.so and pdo_fbird.so build successfully

No ../ references remain

grep -rn '\.\./' pdo_fbird/config.m4 pdo_fbird/config.w32 pdo_fbird/*.c pdo_fbird/*.h
# (none)

Split workflow

No changes needed to split-stubs.yml. The danharrin/monorepo-split-github-action does a subtree split of pdo_fbird/, which now includes all the shared headers.

After merge

  1. Tag v13.0.3 (version bump)
  2. split-stubs.yml pushes the fixed pdo_fbird/ to satwareAG/pdo-fbird
  3. Packagist picks up the new tag
  4. pie install satwareag/pdo-fbird will work

Relates: #485

The pdo-fbird PIE package (satwareAG/pdo-fbird) failed to build because
its source files used #include "../firebird_utils.h" etc., referencing
parent headers that don't exist in the split repo.

Fix:
- Copy 5 shared headers + VERSION.txt into pdo_fbird/ directory:
  firebird_utils.h, php_firebird.h, php_fbird_includes.h,
  fbird_classes.h, fbird_service_types.h
- Change all #include "../xxx.h" to #include "xxx.h" (local)
- Rewrite config.m4: remove PHP_ADD_INCLUDE([$srcdir/..]) and
  $srcdir/../VERSION.txt references

Verified:
- Split build: phpize + configure + make in isolated /tmp/pdo-fbird-split/
- In-tree build: main Makefile builds both firebird.so and pdo_fbird.so
- No ../ references remain in any pdo_fbird/ source or config file

The split-stubs.yml workflow automatically includes all files in
pdo_fbird/ via subtree split, so no workflow changes needed.

Fixes: pie install satwareag/pdo-fbird build failure (#485)
@satwareAG-ironMike
satwareAG-ironMike merged commit e1eaef9 into main Jul 21, 2026
61 of 62 checks passed
@satwareAG-ironMike
satwareAG-ironMike deleted the fix/pdo-fbird-split-self-contained branch July 21, 2026 21:02
satwareAG-ironMike added a commit that referenced this pull request Jul 21, 2026
Version bump to 13.0.3 for the pdo-fbird split package fix (#563).

Changes:
- VERSION.txt: 13.0.2 -> 13.0.3
- stubs/*.php: @Version 13.0.2 -> 13.0.3
- pdo_fbird/VERSION.txt: 13.0.2 -> 13.0.3
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.

1 participant