1 | /* $Id: ncurses_dll.h,v 1.4 2003/07/19 18:44:32 Charles.Wilson Exp $ */
|
---|
2 |
|
---|
3 | #ifndef NCURSES_DLL_H_incl
|
---|
4 | #define NCURSES_DLL_H_incl 1
|
---|
5 |
|
---|
6 | /* no longer needed on cygwin or mingw, thanks to auto-import */
|
---|
7 | /* but this structure may be useful at some point for an MSVC build */
|
---|
8 | /* so, for now unconditionally define the important flags */
|
---|
9 | /* "the right way" for proper static and dll+auto-import behavior */
|
---|
10 | #undef NCURSES_DLL
|
---|
11 | #define NCURSES_STATIC
|
---|
12 |
|
---|
13 | #if defined(__CYGWIN__)
|
---|
14 | # if defined(NCURSES_DLL)
|
---|
15 | # if defined(NCURSES_STATIC)
|
---|
16 | # undef NCURSES_STATIC
|
---|
17 | # endif
|
---|
18 | # endif
|
---|
19 | # undef NCURSES_IMPEXP
|
---|
20 | # undef NCURSES_API
|
---|
21 | # undef NCURSES_EXPORT
|
---|
22 | # undef NCURSES_EXPORT_VAR
|
---|
23 | # if defined(NCURSES_DLL)
|
---|
24 | /* building a DLL */
|
---|
25 | # define NCURSES_IMPEXP __declspec(dllexport)
|
---|
26 | # elif defined(NCURSES_STATIC)
|
---|
27 | /* building or linking to a static library */
|
---|
28 | # define NCURSES_IMPEXP /* nothing */
|
---|
29 | # else
|
---|
30 | /* linking to the DLL */
|
---|
31 | # define NCURSES_IMPEXP __declspec(dllimport)
|
---|
32 | # endif
|
---|
33 | # define NCURSES_API __cdecl
|
---|
34 | # define NCURSES_EXPORT(type) NCURSES_IMPEXP type NCURSES_API
|
---|
35 | # define NCURSES_EXPORT_VAR(type) NCURSES_IMPEXP type
|
---|
36 | #endif
|
---|
37 |
|
---|
38 | /* Take care of non-cygwin platforms */
|
---|
39 | #if !defined(NCURSES_IMPEXP)
|
---|
40 | # define NCURSES_IMPEXP /* nothing */
|
---|
41 | #endif
|
---|
42 | #if !defined(NCURSES_API)
|
---|
43 | # define NCURSES_API /* nothing */
|
---|
44 | #endif
|
---|
45 | #if !defined(NCURSES_EXPORT)
|
---|
46 | # define NCURSES_EXPORT(type) NCURSES_IMPEXP type NCURSES_API
|
---|
47 | #endif
|
---|
48 | #if !defined(NCURSES_EXPORT_VAR)
|
---|
49 | # define NCURSES_EXPORT_VAR(type) NCURSES_IMPEXP type
|
---|
50 | #endif
|
---|
51 |
|
---|
52 | #endif /* NCURSES_DLL_H_incl */
|
---|