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

Commit0e04ee4

Browse files
committed
Create two separate libpq.rc's: One that is built at build time, and one
that is shipped in the distribution, named libpq-dist.rc. This way thebuild system doesn't get upset when a distributed file is forciblyoverwritten by during a normal build.
1 parentbdaf90b commit0e04ee4

File tree

4 files changed

+18
-14
lines changed

4 files changed

+18
-14
lines changed

‎src/interfaces/libpq/.cvsignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
libpqdll.def
22
libpqddll.def
33
blibpqdll.def
4-
libpq.rc
4+
libpq-dist.rc

‎src/interfaces/libpq/Makefile

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group
66
# Portions Copyright (c) 1994, Regents of the University of California
77
#
8-
# $PostgreSQL: pgsql/src/interfaces/libpq/Makefile,v 1.161 2008/02/2606:41:24 petere Exp $
8+
# $PostgreSQL: pgsql/src/interfaces/libpq/Makefile,v 1.162 2008/02/2613:31:40 petere Exp $
99
#
1010
#-------------------------------------------------------------------------
1111

@@ -44,7 +44,7 @@ ifeq ($(PORTNAME), win32)
4444
OBJS += win32.o pgsleep.o libpqrc.o
4545

4646
libpqrc.o: libpq.rc
47-
windres -ilibpq.rc -olibpqrc.o
47+
windres -i$< -o$@
4848

4949
ifeq ($(enable_thread_safety), yes)
5050
OBJS += pthread-win32.o
@@ -66,7 +66,7 @@ endif
6666

6767
SHLIB_EXPORTS = exports.txt
6868

69-
all:$(srcdir)/libpq.rc all-lib
69+
all:$(srcdir)/libpq-dist.rc all-lib
7070

7171
# Shared library stuff
7272
include$(top_srcdir)/src/Makefile.shlib
@@ -90,11 +90,15 @@ encnames.c wchar.c : % : $(backend_src)/utils/mb/%
9090
rm -f$@&&$(LN_S)$<.
9191

9292

93-
distprep:$(srcdir)/libpq.rc
93+
distprep:$(srcdir)/libpq-dist.rc
9494

95-
# depend on Makefile.global to force rebuild on re-run of configure
96-
$(srcdir)/libpq.rc: libpq.rc.in$(top_builddir)/src/Makefile.global
97-
sed -e's/\(VERSION.*\),0 *$$/\1,'`date'+%y%j'| sed's/^0*//'`'/'<$<>$@
95+
libpq.rc$(srcdir)/libpq-dist.rc: libpq.rc.in
96+
sed -e's/\(VERSION.*\),0 *$$/\1,'`date'+%y%j'| sed's/^0*//'`'/'$<>$@
97+
98+
# Depend on Makefile.global to force rebuild on re-run of configure.
99+
# (But libpq-dist.rc is shipped in the distribution for shell-less
100+
# installations and is only updated by distprep.)
101+
libpq.rc:$(top_builddir)/src/Makefile.global
98102

99103
fe-connect.o: fe-connect.c$(top_builddir)/src/port/pg_config_paths.h
100104

@@ -114,9 +118,9 @@ uninstall: uninstall-lib
114118
rm -f'$(DESTDIR)$(includedir)/libpq-fe.h''$(DESTDIR)$(includedir_internal)/libpq-int.h''$(DESTDIR)$(includedir_internal)/pqexpbuffer.h''$(DESTDIR)$(datadir)/pg_service.conf.sample'
115119

116120
cleandistclean: clean-lib
117-
rm -f$(OBJS) pg_config_paths.h crypt.c getaddrinfo.c inet_aton.c noblock.c open.c pgstrcasecmp.c snprintf.c strerror.c strlcpy.c thread.c md5.c ip.c encnames.c wchar.c win32error.c pgsleep.c pthread.h
121+
rm -f$(OBJS) pg_config_paths.h crypt.c getaddrinfo.c inet_aton.c noblock.c open.c pgstrcasecmp.c snprintf.c strerror.c strlcpy.c thread.c md5.c ip.c encnames.c wchar.c win32error.c pgsleep.c pthread.h libpq.rc
118122
# Might be left over from a Win32 client-only build
119123
rm -f pg_config_paths.h
120124

121125
maintainer-clean: distclean maintainer-clean-lib
122-
rm -f$(srcdir)/libpq.rc
126+
rm -f$(srcdir)/libpq-dist.rc

‎src/interfaces/libpq/bcc32.mak

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,8 @@ LINK32_FLAGS = -Gn -L$(BCB)\lib;$(INTDIR); -x -Tpd -v
170170
<<
171171
implib -w "$(OUTDIR)\blibpqdll.lib" blibpqdll.def $@
172172

173-
"$(INTDIR)\libpq.res" : "$(INTDIR)" libpq.rc
174-
$(RSC)$(RSC_PROJ) libpq.rc
173+
"$(INTDIR)\libpq.res" : "$(INTDIR)" libpq-dist.rc
174+
$(RSC)$(RSC_PROJ) libpq-dist.rc
175175

176176
"$(OUTDIR)\blibpq.lib":$(LIB32_OBJS)
177177
$(LIB32)$@ @<<

‎src/interfaces/libpq/win32.mak

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,8 +203,8 @@ LINK32_OBJS= \
203203
$(LIB32_FLAGS)$(DEF_FLAGS)$(LIB32_OBJS)
204204
<<
205205

206-
"$(INTDIR)\libpq.res" : "$(INTDIR)" libpq.rc
207-
$(RSC)$(RSC_PROJ) libpq.rc
206+
"$(INTDIR)\libpq.res" : "$(INTDIR)" libpq-dist.rc
207+
$(RSC)$(RSC_PROJ) libpq-dist.rc
208208

209209

210210
"$(OUTDIR)\$(OUTFILENAME).dll" : "$(OUTDIR)" "$(INTDIR)\libpq.res"

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp