File tree 3 files changed +17
-4
lines changed
3 files changed +17
-4
lines changed Original file line number Diff line number Diff line change 1
1
#ifndef POSTGRES_SQLCA_H
2
2
#define POSTGRES_SQLCA_H
3
3
4
+ #ifndef DLLIMPORT
5
+ #ifdef __CYGWIN__
6
+ #define DLLIMPORT __declspec (dllimport)
7
+ #else
8
+ #define DLLIMPORT
9
+ #endif /* __CYGWIN__ */
10
+ #endif /* DLLIMPORT */
11
+
4
12
#define SQLERRMC_LEN 70
5
13
6
14
#ifdef __cplusplus
@@ -45,7 +53,7 @@ extern "C"
45
53
char sqlext [8 ];
46
54
};
47
55
48
- extern struct sqlca sqlca ;
56
+ extern DLLIMPORT struct sqlca sqlca ;
49
57
50
58
51
59
#ifdef __cplusplus
Original file line number Diff line number Diff line change 1
1
all : test1 test2 test3 test4 perftest dyntest dyntest2 test_notice test_code100 test_init
2
2
3
3
# LDFLAGS=-g -I /usr/local/pgsql/include -L/usr/local/pgsql/lib -lecpg -lpq
4
- LDFLAGS =-g -I ../include -I /usr/include/postgresql -L /usr/lib -lecpg -lpq
4
+ LDFLAGS =-g -I ../include
5
+ LDLIBS =-L ../lib -lecpg -L ../../libpq -lpq
5
6
6
7
# ECPG=/usr/local/pgsql/bin/ecpg -I../include
7
8
ECPG =../preproc/ecpg -I../include
@@ -24,4 +25,4 @@ test_text: test_text.c
24
25
$(ECPG ) $?
25
26
26
27
clean :
27
- rm -f test1 test2 test3 test4 perftest * .c log dyntest dyntest2 test_notice test_code100 test_init test_text
28
+ rm -f test1 test2 test3 test4 perftest * .c log dyntest dyntest2 test_notice test_code100 test_init test_text * .exe
Original file line number Diff line number Diff line change 1
- # $Header: /cvsroot/pgsql/src/makefiles/Attic/Makefile.win,v 1.10 2001/04/04 21:15:56 tgl Exp $
1
+ # $Header: /cvsroot/pgsql/src/makefiles/Attic/Makefile.win,v 1.11 2001/05/03 16:07:52 tgl Exp $
2
2
LDFLAGS+= -g
3
3
DLLTOOL= dlltool
4
4
DLLWRAP= dllwrap
@@ -23,3 +23,7 @@ CFLAGS_SL =
23
23
ifeq ($(findstring backend,$(subdir)), backend)
24
24
override CPPFLAGS+= -DBUILDING_DLL=1
25
25
endif
26
+
27
+ ifeq ($(findstring ecpg/lib,$(subdir)), ecpg/lib)
28
+ override CPPFLAGS+= -DBUILDING_DLL=1
29
+ endif
You can’t perform that action at this time.
0 commit comments