Skip to content

Commit 70c8fcb

Browse files
committed
An include path got missed out of the patch - see the attached fix.
This also adds debug build support to src/bin/psql/win32.mak. Dave Page
1 parent bb46756 commit 70c8fcb

File tree

2 files changed

+24
-9
lines changed

2 files changed

+24
-9
lines changed

src/bin/psql/bcc32.mak

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,9 @@ CLEAN :
103103
USERDEFINES = WIN32;_CONSOLE;_MBCS;HAVE_STRDUP
104104

105105
# ---------------------------------------------------------------------------
106-
CPP_PROJ = -I$(BCB)\include;..\..\include;..\..\interfaces\libpq -c -D$(USERDEFINES) -DFRONTEND \
107-
-tWM -tWC -q -5 -a8 -pc -X -w-use -w-par -w-pia -w-csu -w-aus -w-ccc
106+
CPP_PROJ = -I$(BCB)\include;..\..\include;..\..\interfaces\libpq;..\..\include\port\win32 \
107+
-c -D$(USERDEFINES) -DFRONTEND -tWM -tWC -q -5 -a8 -pc -X -w-use -w-par -w-pia \
108+
-w-csu -w-aus -w-ccc
108109

109110
!IFDEF DEBUG
110111
CPP_PROJ = $(CPP_PROJ) -Od -r- -k -v -y -vi- -D_DEBUG

src/bin/psql/win32.mak

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,21 @@ CPP=cl.exe
1010
PERL=perl.exe
1111
FLEX=flex.exe
1212

13+
!IFDEF DEBUG
14+
OPT=/Od /Zi /MDd
15+
LOPT=/DEBUG
16+
DEBUGDEF=/D _DEBUG
17+
OUTDIR=.\Debug
18+
INTDIR=.\Debug
19+
!ELSE
20+
OPT=/O2 /MD
21+
LOPT=
22+
DEBUGDEF=/D NDEBUG
1323
OUTDIR=.\Release
1424
INTDIR=.\Release
25+
!ENDIF
26+
1527
REFDOCDIR= ../../../doc/src/sgml/ref
16-
# Begin Custom Macros
17-
OutDir=.\Release
18-
# End Custom Macros
1928

2029
ALL : sql_help.h psqlscan.c "..\..\port\pg_config_paths.h" "$(OUTDIR)\psql.exe"
2130

@@ -60,18 +69,19 @@ CLEAN :
6069
"$(OUTDIR)" :
6170
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
6271

63-
CPP_PROJ=/nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D\
72+
CPP_PROJ=/nologo $(OPT) /W3 /GX /D "WIN32" $(DEBUGDEF) /D "_CONSOLE" /D\
6473
"_MBCS" /Fp"$(INTDIR)\psql.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c \
65-
/I ..\..\include /I ..\..\interfaces\libpq /D "HAVE_STRDUP" /D "FRONTEND"
74+
/I ..\..\include /I ..\..\interfaces\libpq /I ..\..\include\port\win32 \
75+
/D "HAVE_STRDUP" /D "FRONTEND"
6676

67-
CPP_OBJS=.\Release/
77+
CPP_OBJS=$(INTDIR)/
6878
CPP_SBRS=.
6979

7080
LINK32=link.exe
7181
LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\
7282
advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\
7383
odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:no\
74-
/pdb:"$(OUTDIR)\psql.pdb" /machine:I386 /out:"$(OUTDIR)\psql.exe"
84+
/pdb:"$(OUTDIR)\psql.pdb" /machine:I386 $(LOPT) /out:"$(OUTDIR)\psql.exe"
7585
LINK32_OBJS= \
7686
"$(INTDIR)\command.obj" \
7787
"$(INTDIR)\common.obj" \
@@ -95,7 +105,11 @@ LINK32_OBJS= \
95105
"$(INTDIR)\path.obj" \
96106
"$(INTDIR)\pgstrcasecmp.obj" \
97107
"$(INTDIR)\sprompt.obj" \
108+
!IFDEF DEBUG
109+
"..\..\interfaces\libpq\Debug\libpqddll.lib"
110+
!ELSE
98111
"..\..\interfaces\libpq\Release\libpqdll.lib"
112+
!ENDIF
99113

100114
"$(OUTDIR)\psql.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
101115
$(LINK32) @<<

0 commit comments

Comments
 (0)