diff options
| author | Robert Haas <rhaas@postgresql.org> | 2022-04-08 08:16:38 -0400 |
|---|---|---|
| committer | Robert Haas <rhaas@postgresql.org> | 2022-04-08 08:16:38 -0400 |
| commit | 8ec569479fc28ddd634a13dc100b36352ec3a3c2 (patch) | |
| tree | 2cde3957ed4071478d647c305161eb24df35be15 /src/include/libpq | |
| parent | 80900d4690916a30f278d877eb5a7a42b14c3f0a (diff) | |
Apply PGDLLIMPORT markings broadly.
Up until now, we've had a policy of only marking certain variables
in the PostgreSQL header files with PGDLLIMPORT, but now we've
decided to mark them all. This means that extensions running on
Windows should no longer operate at a disadvantage as compared to
extensions running on Linux: if the variable is present in a header
file, it should be accessible.
Discussion: http://postgr.es/m/CA+TgmoYanc1_FSfimhgiWSqVyP5KKmh5NP2BWNwDhO8Pg2vGYQ@mail.gmail.com
Diffstat (limited to 'src/include/libpq')
| -rw-r--r-- | src/include/libpq/auth.h | 6 | ||||
| -rw-r--r-- | src/include/libpq/libpq-be.h | 2 | ||||
| -rw-r--r-- | src/include/libpq/libpq.h | 28 | ||||
| -rw-r--r-- | src/include/libpq/pqcomm.h | 2 | ||||
| -rw-r--r-- | src/include/libpq/scram.h | 2 |
5 files changed, 20 insertions, 20 deletions
diff --git a/src/include/libpq/auth.h b/src/include/libpq/auth.h index 6d7ee1acb9d..d3c189efe32 100644 --- a/src/include/libpq/auth.h +++ b/src/include/libpq/auth.h @@ -16,9 +16,9 @@ #include "libpq/libpq-be.h" -extern char *pg_krb_server_keyfile; -extern bool pg_krb_caseins_users; -extern char *pg_krb_realm; +extern PGDLLIMPORT char *pg_krb_server_keyfile; +extern PGDLLIMPORT bool pg_krb_caseins_users; +extern PGDLLIMPORT char *pg_krb_realm; extern void ClientAuthentication(Port *port); extern void sendAuthRequest(Port *port, AuthRequest areq, const char *extradata, diff --git a/src/include/libpq/libpq-be.h b/src/include/libpq/libpq-be.h index c3bf5146528..90c20da22bf 100644 --- a/src/include/libpq/libpq-be.h +++ b/src/include/libpq/libpq-be.h @@ -326,7 +326,7 @@ extern ssize_t be_gssapi_read(Port *port, void *ptr, size_t len); extern ssize_t be_gssapi_write(Port *port, void *ptr, size_t len); #endif /* ENABLE_GSS */ -extern ProtocolVersion FrontendProtocol; +extern PGDLLIMPORT ProtocolVersion FrontendProtocol; /* TCP keepalives configuration. These are no-ops on an AF_UNIX socket. */ diff --git a/src/include/libpq/libpq.h b/src/include/libpq/libpq.h index d348a55812e..2de7d9bad2c 100644 --- a/src/include/libpq/libpq.h +++ b/src/include/libpq/libpq.h @@ -58,7 +58,7 @@ extern const PGDLLIMPORT PQcommMethods *PqCommMethods; /* * prototypes for functions in pqcomm.c */ -extern WaitEventSet *FeBeWaitSet; +extern PGDLLIMPORT WaitEventSet *FeBeWaitSet; #define FeBeWaitSetSocketPos 0 #define FeBeWaitSetLatchPos 1 @@ -87,17 +87,17 @@ extern bool pq_check_connection(void); /* * prototypes for functions in be-secure.c */ -extern char *ssl_library; -extern char *ssl_cert_file; -extern char *ssl_key_file; -extern char *ssl_ca_file; -extern char *ssl_crl_file; -extern char *ssl_crl_dir; -extern char *ssl_dh_params_file; +extern PGDLLIMPORT char *ssl_library; +extern PGDLLIMPORT char *ssl_cert_file; +extern PGDLLIMPORT char *ssl_key_file; +extern PGDLLIMPORT char *ssl_ca_file; +extern PGDLLIMPORT char *ssl_crl_file; +extern PGDLLIMPORT char *ssl_crl_dir; +extern PGDLLIMPORT char *ssl_dh_params_file; extern PGDLLIMPORT char *ssl_passphrase_command; extern PGDLLIMPORT bool ssl_passphrase_command_supports_reload; #ifdef USE_SSL -extern bool ssl_loaded_verify_locations; +extern PGDLLIMPORT bool ssl_loaded_verify_locations; #endif extern int secure_initialize(bool isServerStart); @@ -118,11 +118,11 @@ extern ssize_t secure_open_gssapi(Port *port); #endif /* GUCs */ -extern char *SSLCipherSuites; -extern char *SSLECDHCurve; -extern bool SSLPreferServerCiphers; -extern int ssl_min_protocol_version; -extern int ssl_max_protocol_version; +extern PGDLLIMPORT char *SSLCipherSuites; +extern PGDLLIMPORT char *SSLECDHCurve; +extern PGDLLIMPORT bool SSLPreferServerCiphers; +extern PGDLLIMPORT int ssl_min_protocol_version; +extern PGDLLIMPORT int ssl_max_protocol_version; enum ssl_protocol_versions { diff --git a/src/include/libpq/pqcomm.h b/src/include/libpq/pqcomm.h index ed26ad22567..b418283d5ff 100644 --- a/src/include/libpq/pqcomm.h +++ b/src/include/libpq/pqcomm.h @@ -135,7 +135,7 @@ typedef ProtocolVersion MsgType; typedef uint32 PacketLen; -extern bool Db_user_namespace; +extern PGDLLIMPORT bool Db_user_namespace; /* * In protocol 3.0 and later, the startup packet length is not fixed, but diff --git a/src/include/libpq/scram.h b/src/include/libpq/scram.h index e60992a0d2d..c51e848c24d 100644 --- a/src/include/libpq/scram.h +++ b/src/include/libpq/scram.h @@ -18,7 +18,7 @@ #include "libpq/sasl.h" /* SASL implementation callbacks */ -extern const pg_be_sasl_mech pg_be_scram_mech; +extern PGDLLIMPORT const pg_be_sasl_mech pg_be_scram_mech; /* Routines to handle and check SCRAM-SHA-256 secret */ extern char *pg_be_scram_build_secret(const char *password); |
