diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2008-11-14 20:21:07 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2008-11-14 20:21:07 +0000 |
commit | 62533d34a5893db7ada08cacab379bb77a67a6e7 (patch) | |
tree | 28b36b88208d2bbc08dfaaddde8891f6a567264f /src | |
parent | 32cc9e553323c40beba4a98a5859fafe6e4e1855 (diff) | |
download | postgresql-62533d34a5893db7ada08cacab379bb77a67a6e7.tar.gz postgresql-62533d34a5893db7ada08cacab379bb77a67a6e7.zip |
Second try at fixing DLLIMPORT problem for pg_crc.h on Cygwin.
Diffstat (limited to 'src')
-rw-r--r-- | src/include/utils/pg_crc.h | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/include/utils/pg_crc.h b/src/include/utils/pg_crc.h index 3de95969ecf..0b3501d4562 100644 --- a/src/include/utils/pg_crc.h +++ b/src/include/utils/pg_crc.h @@ -17,11 +17,17 @@ * Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/utils/pg_crc.h,v 1.19 2008/11/13 14:42:28 tgl Exp $ + * $PostgreSQL: pgsql/src/include/utils/pg_crc.h,v 1.20 2008/11/14 20:21:07 tgl Exp $ */ #ifndef PG_CRC_H #define PG_CRC_H +/* ugly hack to let this be used in frontend and backend code on Cygwin */ +#ifdef FRONTEND +#define CRCDLLIMPORT +#else +#define CRCDLLIMPORT PGDLLIMPORT +#endif typedef uint32 pg_crc32; @@ -48,7 +54,7 @@ do { \ #define EQ_CRC32(c1,c2) ((c1) == (c2)) /* Constant table for CRC calculation */ -extern PGDLLIMPORT const uint32 pg_crc32_table[]; +extern CRCDLLIMPORT const uint32 pg_crc32_table[]; #ifdef PROVIDE_64BIT_CRC @@ -106,8 +112,8 @@ do { \ #define EQ_CRC64(c1,c2) ((c1).crc0 == (c2).crc0 && (c1).crc1 == (c2).crc1) /* Constant table for CRC calculation */ -extern PGDLLIMPORT const uint32 pg_crc64_table0[]; -extern PGDLLIMPORT const uint32 pg_crc64_table1[]; +extern CRCDLLIMPORT const uint32 pg_crc64_table0[]; +extern CRCDLLIMPORT const uint32 pg_crc64_table1[]; #else /* int64 works */ typedef struct pg_crc64 @@ -140,7 +146,7 @@ do { \ #define EQ_CRC64(c1,c2) ((c1).crc0 == (c2).crc0) /* Constant table for CRC calculation */ -extern PGDLLIMPORT const uint64 pg_crc64_table[]; +extern CRCDLLIMPORT const uint64 pg_crc64_table[]; #endif /* INT64_IS_BUSTED */ #endif /* PROVIDE_64BIT_CRC */ |