On Ubuntu (apt), only these two packages are currently available:
postgresql-server-dev-12 - development files for PostgreSQL 12 server-side programming
postgresql-server-dev-all - extension build tool for multiple PostgreSQL versions
So, you can install postgreSQL 12
along with postgresql-server-dev-12
But it is not necessary to install the postgresql-server-dev-xx
package anymore, as the installation of PostgreSQL should already include all the necessary header files.
The standard installation provides all the header files needed for
client application development as well as for server-side program
development, such as custom functions or data types written in C.
This change was introduced in PostgreSQL 9.2
, where the pg_config
script was updated to include the necessary compiler and linker flags, so extensions can be built against the PostgreSQL installation without the need for additional packages.