Mercurial > hg > orthanc-databases
comparison Framework/PostgreSQL/PostgreSQLIncludes.h @ 177:02ad3ea95fca
fix build on ubuntu 16.04
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Sat, 12 Dec 2020 19:45:47 +0100 |
parents | 0246923d4df9 |
children | 3236894320d6 |
comparison
equal
deleted
inserted
replaced
176:0246923d4df9 | 177:02ad3ea95fca |
---|---|
26 #include <vector> | 26 #include <vector> |
27 #include <map> | 27 #include <map> |
28 #include <cmath> | 28 #include <cmath> |
29 #include <Enumerations.h> | 29 #include <Enumerations.h> |
30 | 30 |
31 // Get "ntohl()" defined | |
32 #if defined(_WIN32) | |
33 # include <winsock.h> | |
34 #else | |
35 # include <arpa/inet.h> | |
36 #endif | |
37 | |
31 // PostgreSQL includes | 38 // PostgreSQL includes |
32 #include <pg_config.h> | 39 #include <pg_config.h> |
33 | 40 |
34 #if !defined(PG_VERSION_NUM) | 41 #if !defined(PG_VERSION_NUM) |
35 # error PG_VERSION_NUM is not defined | 42 # error PG_VERSION_NUM is not defined |
36 #endif | 43 #endif |
37 | 44 |
45 #if PG_VERSION_NUM >= 110000 | |
46 # include <catalog/pg_type_d.h> | |
47 #else | |
48 # include <postgres.h> | |
49 # undef LOG // This one comes from <postgres.h>, and conflicts with <Core/Logging.h> | |
50 # include <catalog/pg_type.h> | |
51 #endif | |
52 | |
38 #include <libpq-fe.h> | 53 #include <libpq-fe.h> |
39 #include <catalog/pg_type_d.h> |