Parse MobilityDB's vendored pgtypes headers into the catalog#70
Merged
estebanzimanyi merged 1 commit intoJul 22, 2026
Merged
Conversation
MobilityDB keeps the PostgreSQL 18 base types in a pgtypes/ library at the repo root and installs pgtypes.h and the pg_*.h set into the include prefix, so they are as public as meos.h. run.py parses a single header root, so a catalog derived from an installed prefix carries that surface while one derived from the source tree, which points at meos/include, silently loses all of it: interval_make, the base type I/O functions, and the rest. The same MobilityDB commit therefore yielded two different catalogs depending on which root the caller passed, and a binding compiled against the smaller one for a symbol its library exports. Resolve the public pgtypes headers from MDB_SRC_ROOT, the root the @InGroup scan already uses, and parse them alongside the header root, skipping any the root already provides so an installed prefix is unaffected. pg_config*.h carry PostgreSQL's build configuration rather than API and stay out, matching the install set. Against MobilityDB master the source-tree catalog grows from 4569 to 5338 functions, interval_make among them, and three struct-layout tests that could not resolve Span, STBox and TInstant offsets now pass.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MobilityDB keeps the PostgreSQL 18 base types in a
pgtypes/library at the repo root andinstalls
pgtypes.hand thepg_*.hset into the include prefix, so they are as public asmeos.h.run.pyparses a single header root, so the two roots callers pass carry differentsurfaces:
meos*.hset, so they are parsed;meos/include, so a catalog derived from there loses thewhole base-type surface —
interval_make, the base type I/O functions, and the rest.One MobilityDB commit therefore yields two different catalogs depending on the root. In
provision-meosthe root followsbuild-libmeos, so a binding sees the full surface in aworkflow that builds the library and a smaller one in a workflow that does not, and compiling
against the smaller one fails on a symbol its own library exports.
This resolves the public pgtypes headers from
MDB_SRC_ROOT— the root the@ingroupscanalready uses — and parses them alongside the header root, skipping any name the root already
provides so an installed prefix is unaffected.
pg_config*.hcarry PostgreSQL's buildconfiguration rather than API and stay out, matching the install set in MobilityDB's
meos/CMakeLists.txt.Against MobilityDB master
f3929ed5bthe source-tree catalog grows from 4569 to 5338 functions,interval_makeamong them asapi: public, and the header set is the 11 files the installplaces. The test suite goes from 5 failures to 2 across
test_object_model.pyandtest_struct_layout.py:Span,STBoxandTInstantnow resolve real field offsets, becausethe vendored headers give clang the real base types. The 2 that remain fail the same way on
master and reflect the approximate struct layout of the source-tree parse.