Skip site navigation (1) Skip section navigation (2)

Re: [PORTS] Re: patch for minor Win32 makefile bug

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Fred Yankowski <fred(at)ontosys(dot)com>
Cc: Jason(dot)Tishler(at)dothill(dot)com, pgsql-patches(at)postgresql(dot)org, pgsql-ports(at)postgresql(dot)org
Subject: Re: [PORTS] Re: patch for minor Win32 makefile bug
Date: 2001-04-03 22:03:45
Message-ID: 29072.986335425@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-patchespgsql-ports
Fred Yankowski <fred(at)ontosys(dot)com> writes:
> I don't understand the several uses of DLLLIBS as well as I'd like,
> but here's what I think is going on.

> In makefiles/Makefile.win, DLLLIBS lists the libraries needed to build
> the various DLLs associated with the interfaces/* and pl/plpgsql
> directories.  As such it includes '-L$(top_builddir)/src/backend -lpostgres'
> as well as several Cygwin utility libraries.

Hmm.  It seems a little bit weird (no, a lot weird) to be referencing
-lpostgres for the client-side interface library builds.  I can see that
the PL-language DLLs might need to reference -lpostgres during their
links, but I've got severe doubts that this is a good idea anyplace
else.

My thought is that Makefile.win ought to have

DLLLIBS=-lcygipc -lcygwin -lcrypt -lkernel32

which is what will be used by Makefile.shlib to build the interfaces
libraries.  Then in the makefiles for the PL directories we should write

DLLLIBS:= -L$(top_builddir)/src/backend -lpostgres $(DLLLIBS)

so that -lpostgres is added just for the links of those shlibs.  And
finally backend/Makefile could use the Makefile.win definition as-is.

Comments?  If this seems plausible, could you test it?

BTW, I see that the prior version of backend/Makefile actually defined
DLLLIBS as

DLLLIBS := -L/usr/local/lib -lcygipc -lcrypt -lcygwin -lkernel32

as compared to what Makefile.win offers (shorn of the backend):

DLLLIBS=-lcygipc -lcygwin -lcrypt -lkernel32

Any comments on whether -L/usr/local/lib is appropriate here or not?
What about the ordering of these libraries, does that matter?

			regards, tom lane

In response to

Responses

pgsql-ports by date

Next:From: Peter EisentrautDate: 2001-04-03 22:16:52
Subject: Re: Re: [PATCHES] patch for minor Win32 makefile bug
Previous:From: Fred YankowskiDate: 2001-04-03 21:18:04
Subject: Re: [PORTS] Re: patch for minor Win32 makefile bug

pgsql-patches by date

Next:From: Peter EisentrautDate: 2001-04-03 22:16:52
Subject: Re: Re: [PATCHES] patch for minor Win32 makefile bug
Previous:From: Fred YankowskiDate: 2001-04-03 21:18:04
Subject: Re: [PORTS] Re: patch for minor Win32 makefile bug

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group