meson: Add windows resource files

The generated resource files aren't exactly the same ones as the old
buildsystems generate. Previously "InternalName" and "OriginalFileName" were
mostly wrong / not set (despite being required), but that was hard to fix in
at least the make build. Additionally, the meson build falls back to a
"auto-generated" description when not set, and doesn't set it in a few cases -
unlikely that anybody looks at these descriptions in detail.

Author: Andres Freund <andres@anarazel.de>
Author: Nazir Bilal Yavuz <byavuz81@gmail.com>
Reviewed-by: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
This commit is contained in:
Andres Freund 2022-10-05 09:56:05 -07:00
parent a1261cd16f
commit 902ab2fcef
118 changed files with 1292 additions and 131 deletions

View File

@ -1,5 +1,15 @@
adminpack_sources = files(
'adminpack.c',
)
if host_system == 'windows'
adminpack_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'adminpack',
'--FILEDESC', 'adminpack - support functions for pgAdmin',])
endif
adminpack = shared_module('adminpack',
['adminpack.c'],
adminpack_sources,
kwargs: contrib_mod_args,
)
contrib_targets += adminpack

View File

@ -1,7 +1,16 @@
amcheck = shared_module('amcheck', [
'verify_heapam.c',
'verify_nbtree.c',
],
amcheck_sources = files(
'verify_heapam.c',
'verify_nbtree.c',
)
if host_system == 'windows'
amcheck_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'amcheck',
'--FILEDESC', 'amcheck - function for verifying relation integrity',])
endif
amcheck = shared_module('amcheck',
amcheck_sources,
kwargs: contrib_mod_args,
)
contrib_targets += amcheck

View File

@ -1,5 +1,15 @@
auth_delay_sources = files(
'auth_delay.c',
)
if host_system == 'windows'
auth_delay_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'auth_delay',
'--FILEDESC', 'auth_delay - delay authentication failure reports',])
endif
autoinc = shared_module('auth_delay',
['auth_delay.c'],
auth_delay_sources,
kwargs: contrib_mod_args,
)
contrib_targets += autoinc

View File

@ -1,5 +1,15 @@
auto_explain_sources = files(
'auto_explain.c',
)
if host_system == 'windows'
auto_explain_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'auto_explain',
'--FILEDESC', 'auto_explain - logging facility for execution plans',])
endif
auto_explain = shared_module('auto_explain',
files('auto_explain.c'),
auto_explain_sources,
kwargs: contrib_mod_args,
)
contrib_targets += auto_explain

View File

@ -2,6 +2,12 @@ basebackup_to_shell_sources = files(
'basebackup_to_shell.c',
)
if host_system == 'windows'
basebackup_to_shell_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'basebackup_to_shell',
'--FILEDESC', 'basebackup_to_shell - target basebackup to shell command',])
endif
basebackup_to_shell = shared_module('basebackup_to_shell',
basebackup_to_shell_sources,
kwargs: contrib_mod_args,

View File

@ -2,6 +2,12 @@ basic_archive_sources = files(
'basic_archive.c',
)
if host_system == 'windows'
basic_archive_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'basic_archive',
'--FILEDESC', 'basic_archive - basic archive module',])
endif
basic_archive = shared_module('basic_archive',
basic_archive_sources,
kwargs: contrib_mod_args,

View File

@ -7,6 +7,12 @@ bloom_sources = files(
'blvalidate.c',
)
if host_system == 'windows'
bloom_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'bloom',
'--FILEDESC', 'bloom access method - signature file based index',])
endif
bloom = shared_module('bloom',
bloom_sources,
kwargs: contrib_mod_args,

View File

@ -6,6 +6,12 @@ bool_plperl_sources = files(
'bool_plperl.c',
)
if host_system == 'windows'
bool_plperl_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'bool_plperl',
'--FILEDESC', 'bool_plperl - bool transform for plperl',])
endif
bool_plperl = shared_module('bool_plperl',
bool_plperl_sources,
include_directories: [plperl_inc, include_directories('.')],

View File

@ -1,5 +1,15 @@
btree_gin_sources = files(
'btree_gin.c',
)
if host_system == 'windows'
btree_gin_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'btree_gin',
'--FILEDESC', 'btree_gin - B-tree equivalent GIN operator classes',])
endif
btree_gin = shared_module('btree_gin',
files('btree_gin.c'),
btree_gin_sources,
kwargs: contrib_mod_args,
)
contrib_targets += btree_gin

View File

@ -25,6 +25,12 @@ btree_gist_sources = files(
'btree_uuid.c',
)
if host_system == 'windows'
btree_gist_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'btree_gist',
'--FILEDESC', 'btree_gist - B-tree equivalent GiST operator classes',])
endif
btree_gist = shared_module('btree_gist',
btree_gist_sources,
kwargs: contrib_mod_args,

View File

@ -2,6 +2,12 @@ citext_sources = files(
'citext.c',
)
if host_system == 'windows'
citext_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'citext',
'--FILEDESC', 'citext - case-insensitive character string data type',])
endif
citext = shared_module('citext',
citext_sources,
kwargs: contrib_mod_args,

View File

@ -17,6 +17,12 @@ cube_parse = custom_target('cubeparse',
generated_sources += cube_parse.to_list()
cube_sources += cube_parse
if host_system == 'windows'
cube_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'cube',
'--FILEDESC', 'cube - multidimensional cube data type',])
endif
cube = shared_module('cube',
cube_sources,
include_directories: include_directories('.'),

View File

@ -2,6 +2,12 @@ dblink_sources = files(
'dblink.c',
)
if host_system == 'windows'
dblink_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'dblink',
'--FILEDESC', 'dblink - connect to other PostgreSQL databases',])
endif
dblink = shared_module('dblink',
dblink_sources,
kwargs: contrib_mod_args + {

View File

@ -1,5 +1,15 @@
dict_int_sources = files(
'dict_int.c',
)
if host_system == 'windows'
dict_int_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'dict_int',
'--FILEDESC', 'dict_int - add-on dictionary template for full-text search',])
endif
dict_int = shared_module('dict_int',
files('dict_int.c'),
dict_int_sources,
kwargs: contrib_mod_args,
)
contrib_targets += dict_int

View File

@ -1,5 +1,15 @@
dict_xsyn_sources = files(
'dict_xsyn.c',
)
if host_system == 'windows'
dict_xsyn_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'dict_xsyn',
'--FILEDESC', 'dict_xsyn - add-on dictionary template for full-text search',])
endif
dict_xsyn = shared_module('dict_xsyn',
files('dict_xsyn.c'),
dict_xsyn_sources,
kwargs: contrib_mod_args,
)
contrib_targets += dict_xsyn

View File

@ -1,5 +1,15 @@
earthdistance_sources = files(
'earthdistance.c',
)
if host_system == 'windows'
earthdistance_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'earthdistance',
'--FILEDESC', 'earthdistance - calculate distances on the surface of the Earth',])
endif
earthdistance = shared_module('earthdistance',
files('earthdistance.c'),
earthdistance_sources,
kwargs: contrib_mod_args,
)
contrib_targets += earthdistance

View File

@ -1,5 +1,15 @@
file_fdw_sources = files(
'file_fdw.c',
)
if host_system == 'windows'
file_fdw_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'file_fdw',
'--FILEDESC', 'file_fdw - foreign data wrapper for files',])
endif
file_fdw = shared_module('file_fdw',
files('file_fdw.c'),
file_fdw_sources,
kwargs: contrib_mod_args,
)
contrib_targets += file_fdw

View File

@ -1,8 +1,16 @@
fuzzystrmatch_sources = files(
'fuzzystrmatch.c',
'dmetaphone.c',
)
if host_system == 'windows'
fuzzystrmatch_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'fuzzystrmatch',
'--FILEDESC', 'fuzzystrmatch - similarities and distance between strings',])
endif
fuzzystrmatch = shared_module('fuzzystrmatch',
files(
'fuzzystrmatch.c',
'dmetaphone.c'
),
fuzzystrmatch_sources,
kwargs: contrib_mod_args,
)
contrib_targets += fuzzystrmatch

View File

@ -1,15 +1,23 @@
# .. so that includes of hstore/hstore.h work
hstore_inc = include_directories('.', '../')
hstore_sources = files(
'hstore_compat.c',
'hstore_gin.c',
'hstore_gist.c',
'hstore_io.c',
'hstore_op.c',
'hstore_subs.c',
)
if host_system == 'windows'
hstore_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'hstore',
'--FILEDESC', 'hstore - key/value pair data type',])
endif
hstore = shared_module('hstore',
files(
'hstore_compat.c',
'hstore_gin.c',
'hstore_gist.c',
'hstore_io.c',
'hstore_op.c',
'hstore_subs.c',
),
hstore_sources,
kwargs: contrib_mod_args,
)
contrib_targets += hstore

View File

@ -6,6 +6,12 @@ hstore_plperl_sources = files(
'hstore_plperl.c',
)
if host_system == 'windows'
hstore_plperl_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'hstore_plperl',
'--FILEDESC', 'hstore_plperl - hstore transform for plperl',])
endif
hstore_plperl = shared_module('hstore_plperl',
hstore_plperl_sources,
include_directories: [plperl_inc, hstore_inc],

View File

@ -6,6 +6,12 @@ hstore_plpython_sources = files(
'hstore_plpython.c',
)
if host_system == 'windows'
hstore_plpython_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'hstore_plpython3',
'--FILEDESC', 'hstore_plpython - hstore transform for plpython',])
endif
hstore_plpython = shared_module('hstore_plpython3',
hstore_plpython_sources,
include_directories: [plpython_inc, hstore_inc, ],

View File

@ -8,6 +8,12 @@ intarray_sources = files(
'_intbig_gist.c',
)
if host_system == 'windows'
intarray_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', '_int',
'--FILEDESC', 'intarray - functions and operators for arrays of integers',])
endif
intarray = shared_module('_int',
intarray_sources,
kwargs: contrib_mod_args,

View File

@ -2,6 +2,12 @@ isn_sources = files(
'isn.c',
)
if host_system == 'windows'
isn_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'isn',
'--FILEDESC', 'isn - data types for international product numbering standards',])
endif
isn = shared_module('isn',
isn_sources,
kwargs: contrib_mod_args,

View File

@ -6,6 +6,12 @@ jsonb_plperl_sources = files(
'jsonb_plperl.c',
)
if host_system == 'windows'
jsonb_plperl_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'jsonb_plperl',
'--FILEDESC', 'jsonb_plperl - jsonb transform for plperl',])
endif
jsonb_plperl = shared_module('jsonb_plperl',
jsonb_plperl_sources,
include_directories: [plperl_inc],

View File

@ -6,6 +6,12 @@ jsonb_plpython_sources = files(
'jsonb_plpython.c',
)
if host_system == 'windows'
jsonb_plpython_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'jsonb_plpython3',
'--FILEDESC', 'jsonb_plpython - jsonb transform for plpython',])
endif
jsonb_plpython = shared_module('jsonb_plpython3',
jsonb_plpython_sources,
include_directories: [plpython_inc],

View File

@ -2,6 +2,12 @@ lo_sources = files(
'lo.c',
)
if host_system == 'windows'
lo_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'lo',
'--FILEDESC', 'lo - management for large objects',])
endif
lo = shared_module('lo',
lo_sources,
kwargs: contrib_mod_args,

View File

@ -13,6 +13,12 @@ ltree_sources = files(
# .. so that includes of ltree/ltree.h work
ltree_inc = include_directories('.', '../')
if host_system == 'windows'
ltree_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'ltree',
'--FILEDESC', 'ltree - hierarchical label data type',])
endif
ltree = shared_module('ltree',
ltree_sources,
kwargs: contrib_mod_args,

View File

@ -6,6 +6,12 @@ ltree_plpython_sources = files(
'ltree_plpython.c',
)
if host_system == 'windows'
ltree_plpython_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'ltree_plpython3',
'--FILEDESC', 'ltree_plpython - ltree transform for plpython',])
endif
ltree_plpython = shared_module('ltree_plpython3',
ltree_plpython_sources,
include_directories: [plpython_inc, ltree_inc],

View File

@ -1,5 +1,15 @@
oid2name_sources = files(
'oid2name.c',
)
if host_system == 'windows'
oid2name_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'oid2name',
'--FILEDESC', 'oid2name - examine the file structure',])
endif
oid2name = executable('oid2name',
['oid2name.c'],
oid2name_sources,
dependencies: [frontend_code, libpq],
kwargs: default_bin_args,
)

View File

@ -2,6 +2,12 @@ old_snapshot_sources = files(
'time_mapping.c',
)
if host_system == 'windows'
old_snapshot_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'old_snapshot',
'--FILEDESC', 'old_snapshot - utilities in support of old_snapshot_threshold',])
endif
old_snapshot = shared_module('old_snapshot',
old_snapshot_sources,
kwargs: contrib_mod_args,

View File

@ -9,6 +9,12 @@ pageinspect_sources = files(
'rawpage.c',
)
if host_system == 'windows'
pageinspect_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pageinspect',
'--FILEDESC', 'pageinspect - functions to inspect contents of database pages',])
endif
pageinspect = shared_module('pageinspect',
pageinspect_sources,
kwargs: contrib_mod_args,

View File

@ -9,6 +9,12 @@ passwordcheck_deps = []
# passwordcheck_c_args += ['-DUSE_CRACKLIB', '-DCRACKLIB_DICTPATH="/usr/lib/cracklib_dict"']
# passwordcheck_deps += [cc.find_library('crack')]
if host_system == 'windows'
passwordcheck_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'passwordcheck',
'--FILEDESC', 'passwordcheck - strengthen user password checks',])
endif
passwordcheck = shared_module('passwordcheck',
passwordcheck_sources,
c_args: passwordcheck_c_args,

View File

@ -1,7 +1,15 @@
pg_buffercache_sources = files(
'pg_buffercache_pages.c',
)
if host_system == 'windows'
pg_buffercache_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_buffercache',
'--FILEDESC', 'pg_buffercache - monitoring of shared buffer cache in real-time',])
endif
pg_buffercache = shared_module('pg_buffercache',
files(
'pg_buffercache_pages.c',
),
pg_buffercache_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pg_buffercache

View File

@ -1,7 +1,15 @@
pg_freespacemap_sources = files(
'pg_freespacemap.c',
)
if host_system == 'windows'
pg_freespacemap_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_freespacemap',
'--FILEDESC', 'pg_freespacemap - monitoring of free space map',])
endif
pg_freespacemap = shared_module('pg_freespacemap',
files(
'pg_freespacemap.c',
),
pg_freespacemap_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pg_freespacemap

View File

@ -1,8 +1,16 @@
pg_prewarm_sources = files(
'autoprewarm.c',
'pg_prewarm.c',
)
if host_system == 'windows'
pg_prewarm_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_prewarm',
'--FILEDESC', 'pg_prewarm - preload relation data into system buffer cache',])
endif
pg_prewarm = shared_module('pg_prewarm',
files(
'autoprewarm.c',
'pg_prewarm.c',
),
pg_prewarm_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pg_prewarm

View File

@ -1,5 +1,15 @@
pg_stat_statements_sources = files(
'pg_stat_statements.c',
)
if host_system == 'windows'
pg_stat_statements_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_stat_statements',
'--FILEDESC', 'pg_stat_statements - execution statistics of SQL statements',])
endif
pg_stat_statements = shared_module('pg_stat_statements',
files('pg_stat_statements.c'),
pg_stat_statements_sources,
kwargs: contrib_mod_args + {
'dependencies': contrib_mod_args['dependencies'],
},

View File

@ -1,7 +1,15 @@
pg_surgery_sources = files(
'heap_surgery.c',
)
if host_system == 'windows'
pg_surgery_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_surgery',
'--FILEDESC', 'pg_surgery - perform surgery on a damaged relation',])
endif
pg_surgery = shared_module('pg_surgery',
files(
'heap_surgery.c',
),
pg_surgery_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pg_surgery

View File

@ -1,10 +1,18 @@
pg_trgm_sources = files(
'trgm_gin.c',
'trgm_gist.c',
'trgm_op.c',
'trgm_regexp.c',
)
if host_system == 'windows'
pg_trgm_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_trgm',
'--FILEDESC', 'pg_trgm - trigram matching',])
endif
pg_trgm = shared_module('pg_trgm',
files(
'trgm_gin.c',
'trgm_gist.c',
'trgm_op.c',
'trgm_regexp.c',
),
pg_trgm_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pg_trgm

View File

@ -1,7 +1,15 @@
pg_visibility_sources = files(
'pg_visibility.c',
)
if host_system == 'windows'
pg_visibility_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_visibility',
'--FILEDESC', 'pg_visibility - page visibility information',])
endif
pg_visibility = shared_module('pg_visibility',
files(
'pg_visibility.c',
),
pg_visibility_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pg_visibility

View File

@ -1,5 +1,11 @@
pg_walinspect_sources = files('pg_walinspect.c')
if host_system == 'windows'
pg_walinspect_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_walinspect',
'--FILEDESC', 'pg_walinspect - functions to inspect contents of PostgreSQL Write-Ahead Log',])
endif
pg_walinspect = shared_module('pg_walinspect',
pg_walinspect_sources,
kwargs: contrib_mod_args + {

View File

@ -69,6 +69,12 @@ else
pgcrypto_regress += 'pgp-zlib-DISABLED'
endif
if host_system == 'windows'
pgcrypto_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgcrypto',
'--FILEDESC', 'pgcrypto - cryptographic functions',])
endif
pgcrypto = shared_module('pgcrypto',
pgcrypto_sources,
link_with: pgcrypto_link_with,

View File

@ -1,7 +1,15 @@
pgrowlocks_sources = files(
'pgrowlocks.c',
)
if host_system == 'windows'
pgrowlocks_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgrowlocks',
'--FILEDESC', 'pgrowlocks - display row locking information',])
endif
pgrowlocks = shared_module('pgrowlocks',
files(
'pgrowlocks.c',
),
pgrowlocks_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pgrowlocks

View File

@ -1,9 +1,17 @@
pgstattuple_sources = files(
'pgstatapprox.c',
'pgstatindex.c',
'pgstattuple.c',
)
if host_system == 'windows'
pgstattuple_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgstattuple',
'--FILEDESC', 'pgstattuple - tuple-level statistics',])
endif
pgstattuple = shared_module('pgstattuple',
files(
'pgstatapprox.c',
'pgstatindex.c',
'pgstattuple.c',
),
pgstattuple_sources,
kwargs: contrib_mod_args,
)
contrib_targets += pgstattuple

View File

@ -6,6 +6,12 @@ postgres_fdw_sources = files(
'shippable.c',
)
if host_system == 'windows'
postgres_fdw_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'postgres_fdw',
'--FILEDESC', 'postgres_fdw - foreign data wrapper for PostgreSQL',])
endif
postgres_fdw = shared_module('postgres_fdw',
postgres_fdw_sources,
kwargs: contrib_mod_args + {

View File

@ -17,6 +17,12 @@ seg_parse = custom_target('segparse',
generated_sources += seg_parse.to_list()
seg_sources += seg_parse
if host_system == 'windows'
seg_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'seg',
'--FILEDESC', 'seg - line segment data type',])
endif
seg = shared_module('seg',
seg_sources,
include_directories: include_directories('.'),

View File

@ -14,6 +14,12 @@ sepgsql_sources = files(
'uavc.c',
)
if host_system == 'windows'
sepgsql_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'sepgsql',
'--FILEDESC', 'sepgsql - SELinux integration',])
endif
sepgsql = shared_module('sepgsql',
sepgsql_sources,
kwargs: contrib_mod_args + {

View File

@ -1,5 +1,15 @@
autoinc_sources = files(
'autoinc.c',
)
if host_system == 'windows'
autoinc_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'autoinc',
'--FILEDESC', 'spi - examples of using SPI and triggers',])
endif
autoinc = shared_module('autoinc',
['autoinc.c'],
autoinc_sources,
kwargs: contrib_mod_args,
)
contrib_targets += autoinc
@ -9,8 +19,18 @@ install_data('autoinc.control', 'autoinc--1.0.sql',
)
insert_username_sources = files(
'insert_username.c',
)
if host_system == 'windows'
insert_username_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'insert_username',
'--FILEDESC', 'spi - examples of using SPI and triggers',])
endif
insert_username = shared_module('insert_username',
['insert_username.c'],
insert_username_sources,
kwargs: contrib_mod_args,
)
contrib_targets += insert_username
@ -22,8 +42,18 @@ install_data(
)
moddatetime_sources = files(
'moddatetime.c',
)
if host_system == 'windows'
moddatetime_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'moddatetime',
'--FILEDESC', 'spi - examples of using SPI and triggers',])
endif
moddatetime = shared_module('moddatetime',
['moddatetime.c'],
moddatetime_sources,
kwargs: contrib_mod_args,
)
contrib_targets += moddatetime
@ -38,8 +68,18 @@ install_data(
# comment out if you want a quieter refint package for other uses
refint_cflags = ['-DREFINT_VERBOSE']
refint_sources = files(
'refint.c',
)
if host_system == 'windows'
refint_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'refint',
'--FILEDESC', 'spi - examples of using SPI and triggers',])
endif
refint = shared_module('refint',
['refint.c'],
refint_sources,
c_args: refint_cflags,
kwargs: contrib_mod_args,
)

View File

@ -2,10 +2,18 @@ if not ssl.found()
subdir_done()
endif
sslinfo_sources = files(
'sslinfo.c',
)
if host_system == 'windows'
sslinfo_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'sslinfo',
'--FILEDESC', 'sslinfo - information about client SSL certificate',])
endif
sslinfo = shared_module('sslinfo',
files(
'sslinfo.c',
),
sslinfo_sources,
kwargs: contrib_mod_args + {
'dependencies': [ssl, contrib_mod_args['dependencies']],
}

View File

@ -1,7 +1,15 @@
tablefunc_sources = files(
'tablefunc.c',
)
if host_system == 'windows'
tablefunc_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'tablefunc',
'--FILEDESC', 'tablefunc - various functions that return tables',])
endif
tablefunc = shared_module('tablefunc',
files(
'tablefunc.c',
),
tablefunc_sources,
kwargs: contrib_mod_args,
)
contrib_targets += tablefunc

View File

@ -1,7 +1,15 @@
tcn_sources = files(
'tcn.c',
)
if host_system == 'windows'
tcn_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'tcn',
'--FILEDESC', 'tcn - trigger function notifying listeners',])
endif
tcn = shared_module('tcn',
files(
'tcn.c',
),
tcn_sources,
kwargs: contrib_mod_args,
)
contrib_targets += tcn

View File

@ -2,6 +2,12 @@ test_decoding_sources = files(
'test_decoding.c',
)
if host_system == 'windows'
test_decoding_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'test_decoding',
'--FILEDESC', 'test_decoding - example of a logical decoding output plugin',])
endif
test_decoding = shared_module('test_decoding',
test_decoding_sources,
kwargs: contrib_mod_args,

View File

@ -1,7 +1,15 @@
tsm_system_rows_sources = files(
'tsm_system_rows.c',
)
if host_system == 'windows'
tsm_system_rows_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'tsm_system_rows',
'--FILEDESC', 'tsm_system_rows - TABLESAMPLE method which accepts number of rows as a limit',])
endif
tsm_system_rows = shared_module('tsm_system_rows',
files(
'tsm_system_rows.c',
),
tsm_system_rows_sources,
kwargs: contrib_mod_args,
)
contrib_targets += tsm_system_rows

View File

@ -1,7 +1,15 @@
tsm_system_time_sources = files(
'tsm_system_time.c',
)
if host_system == 'windows'
tsm_system_time_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'tsm_system_time',
'--FILEDESC', 'tsm_system_time - TABLESAMPLE method which accepts time in milliseconds as a limit',])
endif
tsm_system_time = shared_module('tsm_system_time',
files(
'tsm_system_time.c',
),
tsm_system_time_sources,
kwargs: contrib_mod_args,
)
contrib_targets += tsm_system_time

View File

@ -1,7 +1,15 @@
unaccent_sources = files(
'unaccent.c',
)
if host_system == 'windows'
unaccent_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'unaccent',
'--FILEDESC', 'unaccent - text search dictionary that removes accents',])
endif
unaccent = shared_module('unaccent',
files(
'unaccent.c',
),
unaccent_sources,
kwargs: contrib_mod_args,
)
contrib_targets += unaccent

View File

@ -2,10 +2,18 @@ if not uuid.found()
subdir_done()
endif
uuid_ossp_sources = files(
'uuid-ossp.c',
)
if host_system == 'windows'
uuid_ossp_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'uuid-ossp',
'--FILEDESC', 'uuid-ossp - UUID generation',])
endif
uuid_ossp = shared_module('uuid-ossp',
files(
'uuid-ossp.c',
),
uuid_ossp_sources,
kwargs: contrib_mod_args + {
'dependencies': [uuid, contrib_mod_args['dependencies']],
},

View File

@ -1,5 +1,15 @@
vacuumlo_sources = files(
'vacuumlo.c',
)
if host_system == 'windows'
vacuumlo_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'vacuumlo',
'--FILEDESC', 'vacuumlo - removes orphaned large objects',])
endif
vacuumlo = executable('vacuumlo',
['vacuumlo.c'],
vacuumlo_sources,
dependencies: [frontend_code, libpq],
kwargs: default_bin_args,
)

View File

@ -2,11 +2,19 @@ if not libxml.found()
subdir_done()
endif
xml2_sources = files(
'xpath.c',
'xslt_proc.c',
)
if host_system == 'windows'
xml2_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgxml',
'--FILEDESC', 'xml2 - XPath querying and XSLT',])
endif
xml2 = shared_module('pgxml',
files(
'xpath.c',
'xslt_proc.c',
),
xml2_sources,
kwargs: contrib_mod_args + {
'dependencies': [libxml, libxslt, contrib_mod_args['dependencies']],
},

View File

@ -2564,6 +2564,65 @@ gen_export_kwargs = {
###
### windows resources related stuff
###
if host_system == 'windows'
pg_ico = meson.source_root() / 'src' / 'port' / 'win32.ico'
win32ver_rc = files('src/port/win32ver.rc')
rcgen = find_program('src/tools/rcgen', native: true)
rcgen_base_args = [
'--srcdir', '@SOURCE_DIR@',
'--builddir', meson.build_root(),
'--rcout', '@OUTPUT0@',
'--out', '@OUTPUT1@',
'--input', '@INPUT@',
'@EXTRA_ARGS@',
]
if cc.get_argument_syntax() == 'msvc'
rc = find_program('rc', required: true)
rcgen_base_args += ['--rc', rc.path()]
rcgen_outputs = ['@BASENAME@.rc', '@BASENAME@.res']
else
windres = find_program('windres', required: true)
rcgen_base_args += ['--windres', windres.path()]
rcgen_outputs = ['@BASENAME@.rc', '@BASENAME@.obj']
endif
# msbuild backend doesn't support this atm
if meson.backend() == 'ninja'
rcgen_base_args += ['--depfile', '@DEPFILE@']
endif
rcgen_bin_args = rcgen_base_args + [
'--VFT_TYPE', 'VFT_APP',
'--FILEENDING', 'exe',
'--ICO', pg_ico
]
rcgen_lib_args = rcgen_base_args + [
'--VFT_TYPE', 'VFT_DLL',
'--FILEENDING', 'dll',
]
rc_bin_gen = generator(rcgen,
depfile: '@BASENAME@.d',
arguments: rcgen_bin_args,
output: rcgen_outputs,
)
rc_lib_gen = generator(rcgen,
depfile: '@BASENAME@.d',
arguments: rcgen_lib_args,
output: rcgen_outputs,
)
endif
# headers that the whole build tree depends on
generated_headers = []
# headers that the backend build depends on

View File

@ -20,6 +20,12 @@ llvmjit_sources += files(
'llvmjit_expr.c',
)
if host_system == 'windows'
llvmjit_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'llvmjit',
'--FILEDESC', 'llvmjit - JIT using LLVM',])
endif
llvmjit = shared_module('llvmjit',
llvmjit_sources,
kwargs: pg_mod_args + {

View File

@ -2,6 +2,12 @@ libpqwalreceiver_sources = files(
'libpqwalreceiver.c',
)
if host_system == 'windows'
libpqwalreceiver_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pqwalreceiver',
'--FILEDESC', 'libpqwalreceiver - receive WAL during streaming replication',])
endif
libpqwalreceiver = shared_module('pqwalreceiver',
libpqwalreceiver_sources,
kwargs: pg_mod_args + {

View File

@ -2,6 +2,12 @@ pgoutput_sources = files(
'pgoutput.c',
)
if host_system == 'windows'
pgoutput_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgoutput',
'--FILEDESC', 'pgoutput - standard logical replication output plugin',])
endif
pgoutput = shared_module('pgoutput',
pgoutput_sources,
kwargs: pg_mod_args,

View File

@ -58,6 +58,12 @@ dict_snowball_sources += files(
# see comment in src/include/snowball/header.h
stemmer_inc = include_directories('../../include/snowball')
if host_system == 'windows'
dict_snowball_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'dict_snowball',
'--FILEDESC', 'snowball - natural language stemmers',])
endif
dict_snowball = shared_module('dict_snowball',
dict_snowball_sources,
kwargs: pg_mod_args + {

View File

@ -29,8 +29,15 @@ encodings = {
}
foreach encoding, sources : encodings
source_files = files(sources)
if host_system == 'windows'
source_files += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', encoding])
endif
backend_targets += shared_module(encoding,
sources,
source_files,
kwargs: pg_mod_args,
)
endforeach

View File

@ -7,6 +7,12 @@ initdb_sources += timezone_localtime_source
#fixme: reimplement libpq_pgport logic
if host_system == 'windows'
initdb_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'initdb',
'--FILEDESC', 'initdb - initialize a new database cluster',])
endif
initdb = executable('initdb',
initdb_sources,
include_directories: [timezone_inc],

View File

@ -1,7 +1,13 @@
pg_amcheck_sources = files(
'pg_amcheck.c'
'pg_amcheck.c',
)
if host_system == 'windows'
pg_amcheck_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_amcheck',
'--FILEDESC', 'pg_amcheck - detect corruption within database relations',])
endif
pg_amcheck = executable('pg_amcheck',
pg_amcheck_sources,
dependencies: [frontend_code, libpq],

View File

@ -1,5 +1,15 @@
pg_archivecleanup_sources = files(
'pg_archivecleanup.c',
)
if host_system == 'windows'
pg_archivecleanup_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_archivecleanup',
'--FILEDESC', 'pg_archivecleanup - cleans archive when used with streaming replication',])
endif
pg_archivecleanup = executable('pg_archivecleanup',
['pg_archivecleanup.c'],
pg_archivecleanup_sources,
dependencies: [frontend_code],
kwargs: default_bin_args,
)

View File

@ -17,24 +17,56 @@ pg_basebackup_common = static_library('libpg_basebackup_common',
kwargs: internal_lib_args,
)
pg_basebackup = executable('pg_basebackup',
pg_basebackup_sources = files(
'pg_basebackup.c',
)
if host_system == 'windows'
pg_basebackup_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_basebackup',
'--FILEDESC', 'pg_basebackup - streaming WAL and backup receivers',])
endif
pg_basebackup = executable('pg_basebackup',
pg_basebackup_sources,
link_with: [pg_basebackup_common],
dependencies: pg_basebackup_deps,
kwargs: default_bin_args,
)
bin_targets += pg_basebackup
pg_receivewal = executable('pg_receivewal',
pg_receivewal_sources = files(
'pg_receivewal.c',
)
if host_system == 'windows'
pg_receivewal_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_receivewal',
'--FILEDESC', 'pg_receivewal - streaming WAL and backup receivers',])
endif
pg_receivewal = executable('pg_receivewal',
pg_receivewal_sources,
link_with: [pg_basebackup_common],
dependencies: pg_basebackup_deps,
kwargs: default_bin_args,
)
bin_targets += pg_receivewal
pg_recvlogical = executable('pg_recvlogical',
pg_recvlogical_sources = files(
'pg_recvlogical.c',
)
if host_system == 'windows'
pg_recvlogical_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_recvlogical',
'--FILEDESC', 'pg_recvlogical - streaming WAL and backup receivers',])
endif
pg_recvlogical = executable('pg_recvlogical',
pg_recvlogical_sources,
link_with: [pg_basebackup_common],
dependencies: pg_basebackup_deps,
kwargs: default_bin_args,

View File

@ -1,5 +1,15 @@
pg_checksums_sources = files(
'pg_checksums.c',
)
if host_system == 'windows'
pg_checksums_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_checksums',
'--FILEDESC', 'pg_checksums - verify data checksums in an offline cluster',])
endif
pg_checksums = executable('pg_checksums',
['pg_checksums.c'],
pg_checksums_sources,
include_directories: [timezone_inc],
dependencies: [frontend_code],
kwargs: default_bin_args,

View File

@ -1,5 +1,15 @@
pg_config_sources = files(
'pg_config.c',
)
if host_system == 'windows'
pg_config_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_config',
'--FILEDESC', 'pg_config - report configuration information',])
endif
pg_config = executable('pg_config',
['pg_config.c'],
pg_config_sources,
dependencies: [frontend_code],
kwargs: default_bin_args,
)

View File

@ -1,5 +1,15 @@
pg_controldata_sources = files(
'pg_controldata.c',
)
if host_system == 'windows'
pg_controldata_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_controldata',
'--FILEDESC', 'pg_controldata - reads the data from pg_control',])
endif
pg_controldata = executable('pg_controldata',
['pg_controldata.c'],
pg_controldata_sources,
dependencies: [frontend_code],
kwargs: default_bin_args,
)

View File

@ -1,5 +1,15 @@
pg_ctl_sources = files(
'pg_ctl.c',
)
if host_system == 'windows'
pg_ctl_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_ctl',
'--FILEDESC', 'pg_ctl - starts/stops/restarts the PostgreSQL server',])
endif
pg_ctl = executable('pg_ctl',
['pg_ctl.c'],
pg_ctl_sources,
dependencies: [frontend_code, libpq],
kwargs: default_bin_args,
)

View File

@ -24,6 +24,12 @@ pg_dump_sources = files(
'pg_dump_sort.c',
)
if host_system == 'windows'
pg_dump_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_dump',
'--FILEDESC', 'pg_dump - backup one PostgreSQL database',])
endif
pg_dump = executable('pg_dump',
pg_dump_sources,
link_with: [pg_dump_common],
@ -37,6 +43,12 @@ pg_dumpall_sources = files(
'pg_dumpall.c',
)
if host_system == 'windows'
pg_dumpall_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_dumpall',
'--FILEDESC', 'pg_dumpall - backup PostgreSQL databases'])
endif
pg_dumpall = executable('pg_dumpall',
pg_dumpall_sources,
link_with: [pg_dump_common],
@ -50,6 +62,12 @@ pg_restore_sources = files(
'pg_restore.c',
)
if host_system == 'windows'
pg_restore_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_restore',
'--FILEDESC', 'pg_restore - restore PostgreSQL databases'])
endif
pg_restore = executable('pg_restore',
pg_restore_sources,
link_with: [pg_dump_common],

View File

@ -1,5 +1,15 @@
pg_resetwal_sources = files(
'pg_resetwal.c',
)
if host_system == 'windows'
pg_resetwal_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_resetwal',
'--FILEDESC', 'pg_resetwal - reset PostgreSQL WAL log'])
endif
pg_resetwal = executable('pg_resetwal',
files('pg_resetwal.c'),
pg_resetwal_sources,
dependencies: [frontend_code],
kwargs: default_bin_args,
)

View File

@ -11,6 +11,12 @@ pg_rewind_sources = files(
pg_rewind_sources += xlogreader_sources
if host_system == 'windows'
pg_rewind_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_rewind',
'--FILEDESC', 'pg_rewind - synchronize a data directory with another one forked from'])
endif
pg_rewind = executable('pg_rewind',
pg_rewind_sources,
dependencies: [frontend_code, libpq, lz4, zstd],

View File

@ -1,4 +1,12 @@
test_fsync_sources = files('pg_test_fsync.c')
test_fsync_sources = files(
'pg_test_fsync.c',
)
if host_system == 'windows'
test_fsync_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_test_fsync',
'--FILEDESC', 'pg_test_fsync - test various disk sync methods'])
endif
pg_test_fsync = executable('pg_test_fsync',
test_fsync_sources,

View File

@ -1,5 +1,15 @@
pg_test_timing_sources = files(
'pg_test_timing.c'
)
if host_system == 'windows'
pg_test_timing_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_test_timing',
'--FILEDESC', 'pg_test_timing - test timing overhead'])
endif
pg_test_timing = executable('pg_test_timing',
['pg_test_timing.c'],
pg_test_timing_sources,
dependencies: [frontend_code],
kwargs: default_bin_args,
)

View File

@ -16,6 +16,12 @@ pg_upgrade_sources = files(
'version.c',
)
if host_system == 'windows'
pg_upgrade_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_upgrade',
'--FILEDESC', 'pg_upgrade - an in-place binary upgrade utility'])
endif
pg_upgrade = executable('pg_upgrade',
pg_upgrade_sources,
dependencies: [frontend_code, libpq],

View File

@ -3,6 +3,12 @@ pg_verifybackup_sources = files(
'pg_verifybackup.c'
)
if host_system == 'windows'
pg_verifybackup_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_verifybackup',
'--FILEDESC', 'pg_verifybackup - verify a backup against using a backup manifest'])
endif
pg_verifybackup = executable('pg_verifybackup',
pg_verifybackup_sources,
dependencies: [frontend_code, libpq],

View File

@ -8,6 +8,12 @@ pg_waldump_sources += rmgr_desc_sources
pg_waldump_sources += xlogreader_sources
pg_waldump_sources += files('../../backend/access/transam/xlogstats.c')
if host_system == 'windows'
pg_waldump_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_waldump',
'--FILEDESC', 'pg_waldump - decode and display WA'])
endif
pg_waldump = executable('pg_waldump',
pg_waldump_sources,
dependencies: [frontend_code, lz4, zstd],

View File

@ -17,6 +17,12 @@ exprparse = custom_target('exprparse',
generated_sources += exprparse.to_list()
pgbench_sources += exprparse
if host_system == 'windows'
pgbench_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgbench',
'--FILEDESC', 'pgbench - a simple program for running benchmark tests'])
endif
pgbench = executable('pgbench',
pgbench_sources,
dependencies: [frontend_code, libpq, thread_dep],

View File

@ -6,6 +6,12 @@ pgevent_sources = files(
'pgevent.c',
)
pgevent_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgevent',
'--FILEDESC', 'Eventlog message formatter',])
pgevent_sources += windows.compile_resources('pgmsgevent.rc')
# FIXME: copied from Mkvcbuild.pm, but I don't think that's the right approach
pgevent_link_args = []
if cc.get_id() == 'msvc'

View File

@ -36,6 +36,12 @@ sql_help = custom_target('psql_help',
generated_sources += sql_help.to_list()
psql_sources += sql_help
if host_system == 'windows'
psql_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'psql',
'--FILEDESC', 'psql - the PostgreSQL interactive terminal',])
endif
psql = executable('psql',
psql_sources,
include_directories: include_directories('.'),

View File

@ -16,8 +16,16 @@ binaries = [
]
foreach binary : binaries
binary_sources = files('@0@.c'.format(binary))
if host_system == 'windows'
binary_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', binary,
'--FILEDESC', '@0@ - PostgreSQL utility'.format(binary),])
endif
binary = executable(binary,
files(binary + '.c'),
binary_sources,
link_with: [scripts_common],
dependencies: [frontend_code, libpq],
kwargs: default_bin_args,

View File

@ -7,6 +7,12 @@ ecpg_compat_inc = [include_directories('.'), ecpg_inc, libpq_inc]
ecpg_compat_c_args = ['-DSO_MAJOR_VERSION=3']
export_file = custom_target('libecpg_compat.exports', kwargs: gen_export_kwargs)
if host_system == 'windows'
ecpg_compat_so_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'libecpg_compat',
'--FILEDESC', 'ECPG compat - compatibility library for ECPG',])
endif
# see src/interfaces/libpq/meson.build
ecpg_compat_st = static_library('libecpg_compat',
ecpg_compat_sources,

View File

@ -16,6 +16,12 @@ ecpglib_inc = [include_directories('.'), ecpg_inc]
ecpglib_c_args = ['-DSO_MAJOR_VERSION=6']
export_file = custom_target('libecpg.exports', kwargs: gen_export_kwargs)
if host_system == 'windows'
ecpglib_so_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'libecpg',
'--FILEDESC', 'ECPG - embedded SQL in C',])
endif
# see src/interfaces/libpq/meson.build
ecpglib_st = static_library('libecpg',
ecpglib_sources,

View File

@ -12,6 +12,12 @@ export_file = custom_target('libpgtypes.exports', kwargs: gen_export_kwargs)
ecpg_pgtypes_inc = [include_directories('.'), ecpg_inc]
ecpg_pgtypes_c_args = ['-DSO_MAJOR_VERSION=3']
if host_system == 'windows'
ecpg_pgtypes_so_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pgtypes',
'--FILEDESC', 'pgtypes - library for data type mapping',])
endif
# see src/interfaces/libpq/meson.build
ecpg_pgtypes_st = static_library('libpgtypes',
ecpg_pgtypes_sources,

View File

@ -93,6 +93,12 @@ ecpg_kwlist = custom_target('ecpg_kwlist_d.h',
generated_sources += ecpg_kwlist
ecpg_sources += ecpg_kwlist
if host_system == 'windows'
ecpg_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'ecpg',
'--FILEDESC', 'ecpg - embedded SQL precompiler for C',])
endif
ecpg_exe = executable('ecpg',
ecpg_sources,
include_directories: ['.', ecpg_inc, postgres_inc, libpq_inc],

View File

@ -7,6 +7,11 @@ pg_regress_ecpg_sources = pg_regress_c + files(
'pg_regress_ecpg.c',
)
if host_system == 'windows'
pg_regress_ecpg_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_regress_ecpg',])
endif
pg_regress_ecpg = executable('pg_regress_ecpg',
pg_regress_ecpg_sources,
c_args: pg_regress_cflags,

View File

@ -16,9 +16,13 @@ libpq_sources = files(
'libpq-events.c',
'pqexpbuffer.c',
)
libpq_so_sources = [] # for shared lib, in addition to the above
if host_system == 'windows'
libpq_sources += files('pthread-win32.c', 'win32.c')
libpq_so_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'libpq',
'--FILEDESC', 'PostgreSQL Access Library',])
endif
if ssl.found()
@ -59,7 +63,7 @@ libpq_st = static_library('libpq',
)
libpq_so = shared_library('libpq',
libpq_sources,
libpq_sources + libpq_so_sources,
include_directories: [libpq_inc, postgres_inc],
c_args: libpq_c_args,
version: '5.' + pg_version_major.to_string(),

View File

@ -1,13 +1,34 @@
libpq_uri_regress_sources = files(
'libpq_uri_regress.c',
)
if host_system == 'windows'
libpq_uri_regress_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'libpq_uri_regress',
'--FILEDESC', 'libpq test program',])
endif
executable('libpq_uri_regress',
files('libpq_uri_regress.c'),
libpq_uri_regress_sources,
dependencies: [frontend_code, libpq],
kwargs: default_bin_args + {
'install': false,
}
)
libpq_testclient_sources = files(
'libpq_testclient.c',
)
if host_system == 'windows'
libpq_testclient_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'libpq_testclient',
'--FILEDESC', 'libpq test program',])
endif
executable('libpq_testclient',
files('libpq_testclient.c'),
libpq_testclient_sources,
dependencies: [frontend_code, libpq],
kwargs: default_bin_args + {
'install': false,

View File

@ -36,6 +36,13 @@ foreach n : ['SPI', 'Util']
endforeach
plperl_inc = include_directories('.')
if host_system == 'windows'
plperl_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'plperl',
'--FILEDESC', 'PL/Perl - procedural language',])
endif
plperl = shared_module('plperl',
plperl_sources,
include_directories: [plperl_inc, postgres_inc],

View File

@ -40,6 +40,12 @@ pl_unreserved = custom_target('pl_unreserved_kwlist',
generated_sources += pl_unreserved
plpgsql_sources += pl_unreserved
if host_system == 'windows'
plpgsql_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'plpgsql',
'--FILEDESC', 'PL/pgSQL - procedural language',])
endif
plpgsql = shared_module('plpgsql',
plpgsql_sources,
include_directories: include_directories('.'),

View File

@ -28,6 +28,12 @@ plpython_sources += custom_target('spiexceptions.h',
# FIXME: need to duplicate import library ugliness?
plpython_inc = include_directories('.')
if host_system == 'windows'
plpython_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'plpython3',
'--FILEDESC', 'PL/Python - procedural language',])
endif
plpython = shared_module('plpython3',
plpython_sources,
include_directories: [plpython_inc, postgres_inc],

View File

@ -14,6 +14,12 @@ pltcl_sources += custom_target('pltclerrcodes.h',
command: [perl, gen_pltclerrcodes, '@INPUT@']
)
if host_system == 'windows'
pltcl_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pltcl',
'--FILEDESC', 'PL/Tcl - procedural language',])
endif
pltcl = shared_module('pltcl',
pltcl_sources,
include_directories: [include_directories('.'), postgres_inc],

View File

@ -23,6 +23,12 @@ spec_parser = custom_target('specparse',
isolationtester_sources += spec_parser
generated_sources += spec_parser.to_list()
if host_system == 'windows'
isolation_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'pg_isolation_regress',
'--FILEDESC', 'pg_isolation_regress - multi-client test driver',])
endif
pg_isolation_regress = executable('pg_isolation_regress',
isolation_sources,
c_args: pg_regress_cflags,
@ -34,6 +40,13 @@ pg_isolation_regress = executable('pg_isolation_regress',
)
bin_targets += pg_isolation_regress
if host_system == 'windows'
isolationtester_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'isolationtester',
'--FILEDESC', 'isolationtester - multi-client test driver',])
endif
isolationtester = executable('isolationtester',
isolationtester_sources,
include_directories: include_directories('.'),

View File

@ -1,6 +1,17 @@
# FIXME: prevent install during main install, but not during test :/
delay_execution_sources = files(
'delay_execution.c',
)
if host_system == 'windows'
delay_execution_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'delay_execution',
'--FILEDESC', 'delay_execution - allow delay between parsing and execution',])
endif
delay_execution = shared_module('delay_execution',
['delay_execution.c'],
delay_execution_sources,
kwargs: pg_mod_args,
)
testprep_targets += delay_execution

View File

@ -1,6 +1,17 @@
# FIXME: prevent install during main install, but not during test :/
dummy_index_am_sources = files(
'dummy_index_am.c',
)
if host_system == 'windows'
dummy_index_am_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'dummy_index_am',
'--FILEDESC', 'dummy_index_am - index access method template',])
endif
dummy_index_am = shared_module('dummy_index_am',
['dummy_index_am.c'],
dummy_index_am_sources,
kwargs: pg_mod_args,
)
testprep_targets += dummy_index_am

View File

@ -1,6 +1,17 @@
# FIXME: prevent install during main install, but not during test :/
dummy_seclabel_sources = files(
'dummy_seclabel.c',
)
if host_system == 'windows'
dummy_seclabel_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'dummy_seclabel',
'--FILEDESC', 'dummy_seclabel - regression testing of the SECURITY LABEL statement',])
endif
dummy_seclabel = shared_module('dummy_seclabel',
['dummy_seclabel.c'],
dummy_seclabel_sources,
kwargs: pg_mod_args,
)
testprep_targets += dummy_seclabel

View File

@ -1,7 +1,15 @@
libpq_pipeline_sources = files(
'libpq_pipeline.c',
)
if host_system == 'windows'
libpq_pipeline_sources += rc_bin_gen.process(win32ver_rc, extra_args: [
'--NAME', 'libpq_pipeline',
'--FILEDESC', 'libpq_pipeline - test program for pipeline execution',])
endif
libpq_pipeline = executable('libpq_pipeline',
files(
'libpq_pipeline.c',
),
libpq_pipeline_sources,
dependencies: [frontend_code, libpq],
kwargs: default_bin_args + {
'install': false,

View File

@ -1,6 +1,17 @@
# FIXME: prevent install during main install, but not during test :/
plsample_sources = files(
'plsample.c',
)
if host_system == 'windows'
plsample_sources += rc_lib_gen.process(win32ver_rc, extra_args: [
'--NAME', 'plsample',
'--FILEDESC', 'PL/Sample - template for procedural language',])
endif
plsample = shared_module('plsample',
['plsample.c'],
plsample_sources,
kwargs: pg_mod_args,
)
testprep_targets += plsample

Some files were not shown because too many files have changed in this diff Show More