Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
889f0381
Commit
889f0381
authored
Jan 26, 2005
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use SHGetFolderPath instead of SHGetSpecialFolderPath to find the
APPDATA directory on Windows. Magnus Hagander
parent
c0e0d3e2
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
20 additions
and
14 deletions
+20
-14
src/Makefile.global.in
src/Makefile.global.in
+4
-3
src/bin/psql/win32.mak
src/bin/psql/win32.mak
+1
-1
src/interfaces/ecpg/ecpglib/Makefile
src/interfaces/ecpg/ecpglib/Makefile
+6
-1
src/interfaces/libpq/Makefile
src/interfaces/libpq/Makefile
+2
-2
src/interfaces/libpq/fe-connect.c
src/interfaces/libpq/fe-connect.c
+3
-3
src/interfaces/libpq/win32.mak
src/interfaces/libpq/win32.mak
+1
-1
src/port/path.c
src/port/path.c
+3
-3
No files found.
src/Makefile.global.in
View file @
889f0381
# -*-makefile-*-
# -*-makefile-*-
# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.20
8 2004/12/19 02:16:18 momjian
Exp $
# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.20
9 2005/01/26 19:23:59 tgl
Exp $
#------------------------------------------------------------------------------
#------------------------------------------------------------------------------
# All PostgreSQL makefiles include this file and use the variables it sets,
# All PostgreSQL makefiles include this file and use the variables it sets,
...
@@ -384,9 +384,10 @@ override LDFLAGS := -L$(top_builddir)/src/port $(LDFLAGS)
...
@@ -384,9 +384,10 @@ override LDFLAGS := -L$(top_builddir)/src/port $(LDFLAGS)
endif
endif
endif
endif
# to make ws2_32.lib the last library
# to make ws2_32.lib the last library, and always link with shfolder,
# so SHGetFolderName isn't picked up from shell32.dll
ifeq
($(PORTNAME),win32)
ifeq
($(PORTNAME),win32)
LIBS
+=
-lws2_32
LIBS
+=
-lws2_32
-lshfolder
endif
endif
# Not really standard libc functions, used by the backend.
# Not really standard libc functions, used by the backend.
...
...
src/bin/psql/win32.mak
View file @
889f0381
...
@@ -79,7 +79,7 @@ CPP_SBRS=.
...
@@ -79,7 +79,7 @@ CPP_SBRS=.
LINK32
=
link.exe
LINK32
=
link.exe
LINK32_FLAGS
=
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib
\
LINK32_FLAGS
=
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib
\
advapi32.lib sh
ell32
.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib
\
advapi32.lib sh
folder
.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib
\
odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:no
\
odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:no
\
/pdb:
"
$(OUTDIR)
\p
sql.pdb"
/machine:I386
$(LOPT)
/out:
"
$(OUTDIR)
\p
sql.exe"
/pdb:
"
$(OUTDIR)
\p
sql.pdb"
/machine:I386
$(LOPT)
/out:
"
$(OUTDIR)
\p
sql.exe"
LINK32_OBJS
=
\
LINK32_OBJS
=
\
...
...
src/interfaces/ecpg/ecpglib/Makefile
View file @
889f0381
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
#
#
# Copyright (c) 1994, Regents of the University of California
# Copyright (c) 1994, Regents of the University of California
#
#
# $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/Makefile,v 1.3
0 2005/01/18 05:00:17 momjian
Exp $
# $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/Makefile,v 1.3
1 2005/01/26 19:24:01 tgl
Exp $
#
#
#-------------------------------------------------------------------------
#-------------------------------------------------------------------------
...
@@ -30,6 +30,11 @@ OBJS= execute.o typename.o descriptor.o data.o error.o prepare.o memory.o \
...
@@ -30,6 +30,11 @@ OBJS= execute.o typename.o descriptor.o data.o error.o prepare.o memory.o \
SHLIB_LINK
=
-L
../pgtypeslib
-lpgtypes
$(libpq)
\
SHLIB_LINK
=
-L
../pgtypeslib
-lpgtypes
$(libpq)
\
$(
filter
-lintl
-lssl
-lcrypto
-lkrb5
-lcrypt
-lm
,
$(LIBS)
)
$(PTHREAD_LIBS)
$(
filter
-lintl
-lssl
-lcrypto
-lkrb5
-lcrypt
-lm
,
$(LIBS)
)
$(PTHREAD_LIBS)
ifeq
($(PORTNAME), win32)
# Link to shfolder.dll instead of shell32.dll
SHLIB_LINK
+=
-lshfolder
endif
all
:
all-lib
all
:
all-lib
# Shared library stuff
# Shared library stuff
...
...
src/interfaces/libpq/Makefile
View file @
889f0381
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
# Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
# Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
# Portions Copyright (c) 1994, Regents of the University of California
#
#
# $PostgreSQL: pgsql/src/interfaces/libpq/Makefile,v 1.12
7 2005/01/18 05:00:30 momjian
Exp $
# $PostgreSQL: pgsql/src/interfaces/libpq/Makefile,v 1.12
8 2005/01/26 19:24:02 tgl
Exp $
#
#
#-------------------------------------------------------------------------
#-------------------------------------------------------------------------
...
@@ -55,7 +55,7 @@ endif
...
@@ -55,7 +55,7 @@ endif
# matter.)
# matter.)
SHLIB_LINK
+=
$(
filter
-lcrypt
-ldes
-lkrb
-lcom_err
-lcrypto
-lk5crypto
-lkrb5
-lssl
-lsocket
-lnsl
-lresolv
-lintl
,
$(LIBS)
)
$(PTHREAD_LIBS)
SHLIB_LINK
+=
$(
filter
-lcrypt
-ldes
-lkrb
-lcom_err
-lcrypto
-lk5crypto
-lkrb5
-lssl
-lsocket
-lnsl
-lresolv
-lintl
,
$(LIBS)
)
$(PTHREAD_LIBS)
ifeq
($(PORTNAME), win32)
ifeq
($(PORTNAME), win32)
SHLIB_LINK
+=
-l
wsock32
-lws2_32
-lshell
32
$(
filter
-leay32
-lssleay32
,
$(LIBS)
)
SHLIB_LINK
+=
-l
shfolder
-lwsock32
-lws2_
32
$(
filter
-leay32
-lssleay32
,
$(LIBS)
)
endif
endif
...
...
src/interfaces/libpq/fe-connect.c
View file @
889f0381
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
*
*
*
*
* IDENTIFICATION
* IDENTIFICATION
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-connect.c,v 1.30
1 2005/01/14 00:25:56 momjian
Exp $
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-connect.c,v 1.30
2 2005/01/26 19:24:02 tgl
Exp $
*
*
*-------------------------------------------------------------------------
*-------------------------------------------------------------------------
*/
*/
...
@@ -38,7 +38,7 @@
...
@@ -38,7 +38,7 @@
#ifdef _WIN32_IE
#ifdef _WIN32_IE
#undef _WIN32_IE
#undef _WIN32_IE
#endif
#endif
#define _WIN32_IE 0x0
4
00
#define _WIN32_IE 0x0
5
00
#ifdef near
#ifdef near
#undef near
#undef near
#endif
#endif
...
@@ -3296,7 +3296,7 @@ pqGetHomeDirectory(char *buf, int bufsize)
...
@@ -3296,7 +3296,7 @@ pqGetHomeDirectory(char *buf, int bufsize)
char
tmppath
[
MAX_PATH
];
char
tmppath
[
MAX_PATH
];
ZeroMemory
(
tmppath
,
sizeof
(
tmppath
));
ZeroMemory
(
tmppath
,
sizeof
(
tmppath
));
if
(
!
SHGetSpecialFolderPath
(
NULL
,
tmppath
,
CSIDL_APPDATA
,
FALSE
)
)
if
(
SHGetFolderPath
(
NULL
,
CSIDL_APPDATA
,
NULL
,
0
,
tmppath
)
!=
S_OK
)
return
false
;
return
false
;
snprintf
(
buf
,
bufsize
,
"%s/postgresql"
,
tmppath
);
snprintf
(
buf
,
bufsize
,
"%s/postgresql"
,
tmppath
);
return
true
;
return
true
;
...
...
src/interfaces/libpq/win32.mak
View file @
889f0381
...
@@ -138,7 +138,7 @@ LIB32_OBJS= \
...
@@ -138,7 +138,7 @@ LIB32_OBJS= \
RSC_PROJ
=
/l 0x409 /fo
"
$(INTDIR)
\l
ibpq.res"
RSC_PROJ
=
/l 0x409 /fo
"
$(INTDIR)
\l
ibpq.res"
LINK32
=
link.exe
LINK32
=
link.exe
LINK32_FLAGS
=
kernel32.lib user32.lib advapi32.lib sh
ell32
.lib wsock32.lib
$(SSL_LIBS)
\
LINK32_FLAGS
=
kernel32.lib user32.lib advapi32.lib sh
folder
.lib wsock32.lib
$(SSL_LIBS)
\
/nologo /subsystem:windows /dll
$(LOPT)
/incremental:no
\
/nologo /subsystem:windows /dll
$(LOPT)
/incremental:no
\
/pdb:
"
$(OUTDIR)
\l
ibpqdll.pdb"
/machine:I386 /out:
"
$(OUTDIR)
\$
(OUTFILENAME).dll"
\
/pdb:
"
$(OUTDIR)
\l
ibpqdll.pdb"
/machine:I386 /out:
"
$(OUTDIR)
\$
(OUTFILENAME).dll"
\
/implib:
"
$(OUTDIR)
\$
(OUTFILENAME)dll.lib"
/def:
$(OUTFILENAME)
dll.def
/implib:
"
$(OUTDIR)
\$
(OUTFILENAME)dll.lib"
/def:
$(OUTFILENAME)
dll.def
...
...
src/port/path.c
View file @
889f0381
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
*
*
*
*
* IDENTIFICATION
* IDENTIFICATION
* $PostgreSQL: pgsql/src/port/path.c,v 1.5
0 2005/01/10 00:19:51
tgl Exp $
* $PostgreSQL: pgsql/src/port/path.c,v 1.5
1 2005/01/26 19:24:03
tgl Exp $
*
*
*-------------------------------------------------------------------------
*-------------------------------------------------------------------------
*/
*/
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
#ifdef _WIN32_IE
#ifdef _WIN32_IE
#undef _WIN32_IE
#undef _WIN32_IE
#endif
#endif
#define _WIN32_IE 0x0
4
00
#define _WIN32_IE 0x0
5
00
#ifdef near
#ifdef near
#undef near
#undef near
#endif
#endif
...
@@ -476,7 +476,7 @@ get_home_path(char *ret_path)
...
@@ -476,7 +476,7 @@ get_home_path(char *ret_path)
char
tmppath
[
MAX_PATH
];
char
tmppath
[
MAX_PATH
];
ZeroMemory
(
tmppath
,
sizeof
(
tmppath
));
ZeroMemory
(
tmppath
,
sizeof
(
tmppath
));
if
(
!
SHGetSpecialFolderPath
(
NULL
,
tmppath
,
CSIDL_APPDATA
,
FALSE
)
)
if
(
SHGetFolderPath
(
NULL
,
CSIDL_APPDATA
,
NULL
,
0
,
tmppath
)
!=
S_OK
)
return
false
;
return
false
;
snprintf
(
ret_path
,
MAXPGPATH
,
"%s/postgresql"
,
tmppath
);
snprintf
(
ret_path
,
MAXPGPATH
,
"%s/postgresql"
,
tmppath
);
return
true
;
return
true
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment