You right Eliot Haisley more complete patch because he replaced all occurrences
of @SOURCE_DIR@ but I also added include_directories to dependency, so it will
not fail to find headers which are included in libpq headers. So if I merge my
patch with Eliot’s it should be fine. I can send complete patch after it’s
done.
About meson wrap subproject. In my projects I really like to have fallback if
there is no system lib available or system lib have not compatible version.
Basically I use it as package manager for my C/C++ projects, I just put the
link to git into wrap file, provide dependency and that’s it, meson does all
the work. Ideally everything in my project should be build from scratch without
any prebuilt binaries, so I can cross-compile to any platform that I want and
build/packaging of project becomes much easier.
> 3 янв. 2026 г., в 04:54, Andreas Karlsson <[email protected]> написал(а):
>
> On 12/23/25 4:21 PM, Niyaz Hazigaleyev wrote:
>> So to use Postgres as wrap subproject u need to change @SOURCE_DIR@ to
>> meson.project_source_root() and check include_directories for all
>> dependencies. Is there any plans to support it?
>
> Thanks for the patch!
>
> There was an earlier patch[1] for this from Elliot Haisley which looks more
> complete that Andres seemed a bit interested in but as far as I know no
> progress has been made on it recently. You could help out by testing it out
> and reviewing it.
>
> Out of curiosity since I am quite new to Meson: what is your personal use
> case for wrap subprojects?
>
> References
>
> 1.
> https://www.postgresql.org/message-id/PH0PR84MB1954C7D61C4882403B8258708605A%40PH0PR84MB1954.NAMPRD84.PROD.OUTLOOK.COM
>
> Andreas
>