Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit77e50a6

Browse files
committed
Mark PG_MODULE_MAGIC and PG_FUNCTION_INFO_V1 with PGDLLEXPORT
independently from BUILDING_DLL. It is always __declspec(dllexport).
1 parentaa5bec6 commit77e50a6

File tree

4 files changed

+17
-9
lines changed

4 files changed

+17
-9
lines changed

‎src/include/c.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
1313
* Portions Copyright (c) 1994, Regents of the University of California
1414
*
15-
* $PostgreSQL: pgsql/src/include/c.h,v 1.240 2010/02/26 02:01:20 momjian Exp $
15+
* $PostgreSQL: pgsql/src/include/c.h,v 1.241 2010/05/27 07:59:48 itagaki Exp $
1616
*
1717
*-------------------------------------------------------------------------
1818
*/
@@ -784,8 +784,12 @@ extern intvsnprintf(char *str, size_t count, const char *fmt, va_list args);
784784
#definememmove(d,s,c)bcopy(s, d, c)
785785
#endif
786786

787+
/* no special DLL markers on most ports */
787788
#ifndefPGDLLIMPORT
788-
#definePGDLLIMPORT/* no special DLL markers on most ports */
789+
#definePGDLLIMPORT
790+
#endif
791+
#ifndefPGDLLEXPORT
792+
#definePGDLLEXPORT
789793
#endif
790794

791795
/*

‎src/include/fmgr.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
1212
* Portions Copyright (c) 1994, Regents of the University of California
1313
*
14-
* $PostgreSQL: pgsql/src/include/fmgr.h,v 1.65 2010/02/26 02:01:20 momjian Exp $
14+
* $PostgreSQL: pgsql/src/include/fmgr.h,v 1.66 2010/05/27 07:59:48 itagaki Exp $
1515
*
1616
*-------------------------------------------------------------------------
1717
*/
@@ -328,7 +328,7 @@ typedef const Pg_finfo_record *(*PGFInfoFunction) (void);
328328
*doesn't hurt to add PGDLLIMPORT in case they don't.
329329
*/
330330
#definePG_FUNCTION_INFO_V1(funcname) \
331-
externPGDLLIMPORT const Pg_finfo_record * CppConcat(pg_finfo_,funcname)(void); \
331+
externPGDLLEXPORT const Pg_finfo_record * CppConcat(pg_finfo_,funcname)(void); \
332332
const Pg_finfo_record * \
333333
CppConcat(pg_finfo_,funcname) (void) \
334334
{ \
@@ -397,7 +397,7 @@ typedef const Pg_magic_struct *(*PGModuleMagicFunction) (void);
397397
#definePG_MAGIC_FUNCTION_NAME_STRING "Pg_magic_func"
398398

399399
#definePG_MODULE_MAGIC \
400-
externPGDLLIMPORT const Pg_magic_struct *PG_MAGIC_FUNCTION_NAME(void); \
400+
externPGDLLEXPORT const Pg_magic_struct *PG_MAGIC_FUNCTION_NAME(void); \
401401
const Pg_magic_struct * \
402402
PG_MAGIC_FUNCTION_NAME(void) \
403403
{ \

‎src/include/port/cygwin.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* $PostgreSQL: pgsql/src/include/port/cygwin.h,v 1.7 2007/07/25 12:22:53 mha Exp $ */
1+
/* $PostgreSQL: pgsql/src/include/port/cygwin.h,v 1.8 2010/05/27 07:59:48 itagaki Exp $ */
22

33
#include<cygwin/version.h>
44

@@ -17,5 +17,6 @@
1717
#definePGDLLIMPORT __declspec (dllexport)
1818
#else
1919
#definePGDLLIMPORT __declspec (dllimport)
20-
2120
#endif
21+
22+
#definePGDLLEXPORT __declspec (dllexport)

‎src/include/port/win32.h

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* $PostgreSQL: pgsql/src/include/port/win32.h,v 1.93 2010/02/16 19:26:02 mha Exp $ */
1+
/* $PostgreSQL: pgsql/src/include/port/win32.h,v 1.94 2010/05/27 07:59:48 itagaki Exp $ */
22

33
#if defined(_MSC_VER)|| defined(__BORLANDC__)
44
#defineWIN32_ONLY_COMPILER
@@ -57,9 +57,12 @@
5757
#else/* not BUILDING_DLL */
5858
#definePGDLLIMPORT __declspec (dllimport)
5959
#endif
60-
#else/* not CYGWIN, not MSVC, not MingW */
6160

61+
#definePGDLLEXPORT __declspec (dllexport)
62+
63+
#else/* not CYGWIN, not MSVC, not MingW */
6264
#definePGDLLIMPORT
65+
#definePGDLLEXPORT
6366
#endif
6467

6568

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp