From: | Japin Li <japinli(at)hotmail(dot)com> |
---|---|
To: | PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | pg_probackup build issue with PostgreSQL 18beta1 due to pg_detoast_datum_packed() |
Date: | 2025-06-04 07:06:58 |
Message-ID: | ME0P300MB0445018F5C924B2D88983F45B66CA@ME0P300MB0445.AUSP300.PROD.OUTLOOK.COM |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi, hackers
I've run into a build issue when trying to use pg_probackup with PostgreSQL
18beta1. After some adjustments to pg_probackup, I encountered the following
linker errors:
/usr/bin/ld: src/pg_crc.o: in function `crc32_bytea':
/home/japin/Codes/extensions/pg_probackup/src/pg_crc.c:109:(.text+0x40): undefined reference to `pg_detoast_datum_packed'
/usr/bin/ld: src/pg_crc.o: in function `crc32c_bytea':
/home/japin/Codes/extensions/pg_probackup/src/pg_crc.c:122:(.text+0x1a1): undefined reference to `pg_detoast_datum_packed'
collect2: error: ld returned 1 exit status
make: *** [/data/Codes/ngdb/main/build/ngdb/lib/postgresql/pgxs/src/makefiles/pgxs.mk:478: pg_probackup] Error 1
It appears that PostgreSQL commit 760162f introduced user-callable CRC
functions. Since pg_probackup leverages pg_crc.c from the PostgreSQL source,
this change is leading to the "undefined reference to pg_detoast_datum_packed"
errors during the build.
To resolve this, I'm wondering about wrapping these user-callable CRC functions
with an #ifndef FRONTEND block:
#ifndef FRONTEND
... // user-callable CRC functions here
#endif
This would ensure these functions are only included in the backend compilation
and avoid linker issues when building extensions like pg_probackup.
Any thoughts or alternative suggestions would be greatly appreciated!
--
Regards,
Japin Li
Attachment | Content-Type | Size |
---|---|---|
pg_probackup-with-pg18.diff | text/x-diff | 3.5 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Florents Tselai | 2025-06-04 08:12:38 | Re: encode/decode support for base64url |
Previous Message | Peter Eisentraut | 2025-06-04 06:22:14 | Re: C11 / VS 2019 |