Re: Revert addition of -lpgport, which breaks the build - Mailing list pgsql-committers

From Bruce Momjian
Subject Re: Revert addition of -lpgport, which breaks the build
Date
Msg-id 200405210311.i4L3B7V07723@candle.pha.pa.us
Whole thread Raw
In response to Re: Revert addition of -lpgport, which breaks the build  (Neil Conway <neilc@samurai.com>)
Responses Re: Revert addition of -lpgport, which breaks the build
List pgsql-committers
I modified to code so only Win32 will do it.

---------------------------------------------------------------------------

Neil Conway wrote:
> Tom Lane wrote:
> > Revert addition of -lpgport, which breaks the build on platforms that
> > are sticky about non-PIC code in shared libraries.  Windows will have
> > to find another solution (probably similar to the way libpq does it).
>
> I need to apply the attached patch to get ecpg to link successfully on
> my machine (OSX 10.3). Is this a known issue?
>
> -Neil

> Index: src/interfaces/ecpg/ecpglib/Makefile
> ===================================================================
> RCS file: /Users/neilc/local/cvs/pgsql-server/src/interfaces/ecpg/ecpglib/Makefile,v
> retrieving revision 1.19
> diff -c -r1.19 Makefile
> *** src/interfaces/ecpg/ecpglib/Makefile    21 May 2004 00:14:38 -0000    1.19
> --- src/interfaces/ecpg/ecpglib/Makefile    21 May 2004 00:47:23 -0000
> ***************
> *** 23,29 ****
>   OBJS= execute.o typename.o descriptor.o data.o error.o prepare.o memory.o \
>       connect.o misc.o
>
> ! SHLIB_LINK = -L../pgtypeslib -lpgtypes $(libpq) \
>       $(filter -lintl -lssl -lcrypto -lkrb5 -lcrypt -lm, $(LIBS)) $(PTHREAD_LIBS)
>
>   all: all-lib
> --- 23,29 ----
>   OBJS= execute.o typename.o descriptor.o data.o error.o prepare.o memory.o \
>       connect.o misc.o
>
> ! SHLIB_LINK = -L../pgtypeslib -lpgtypes -lpgport $(libpq) \
>       $(filter -lintl -lssl -lcrypto -lkrb5 -lcrypt -lm, $(LIBS)) $(PTHREAD_LIBS)
>
>   all: all-lib
> Index: src/interfaces/ecpg/compatlib/Makefile
> ===================================================================
> RCS file: /Users/neilc/local/cvs/pgsql-server/src/interfaces/ecpg/compatlib/Makefile,v
> retrieving revision 1.17
> diff -c -r1.17 Makefile
> *** src/interfaces/ecpg/compatlib/Makefile    30 Apr 2004 04:14:05 -0000    1.17
> --- src/interfaces/ecpg/compatlib/Makefile    21 May 2004 00:48:08 -0000
> ***************
> *** 19,25 ****
>   override CPPFLAGS := -I$(top_srcdir)/src/interfaces/ecpg/include -I$(libpq_srcdir) \
>       -I$(top_srcdir)/src/include/utils $(CPPFLAGS)
>   override CFLAGS += $(PTHREAD_CFLAGS)
> ! SHLIB_LINK = -L../ecpglib -lecpg -L../pgtypeslib -lpgtypes $(libpq) \
>       $(filter -lintl -lssl -lcrypto -lkrb5 -lcrypt -lm, $(LIBS)) $(PTHREAD_LIBS)
>
>   OBJS= informix.o
> --- 19,25 ----
>   override CPPFLAGS := -I$(top_srcdir)/src/interfaces/ecpg/include -I$(libpq_srcdir) \
>       -I$(top_srcdir)/src/include/utils $(CPPFLAGS)
>   override CFLAGS += $(PTHREAD_CFLAGS)
> ! SHLIB_LINK = -L../ecpglib -lecpg -L../pgtypeslib -lpgtypes -lpgport $(libpq) \
>       $(filter -lintl -lssl -lcrypto -lkrb5 -lcrypt -lm, $(LIBS)) $(PTHREAD_LIBS)
>
>   OBJS= informix.o

>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

pgsql-committers by date:

Previous
From: momjian@svr1.postgresql.org (Bruce Momjian)
Date:
Subject: Add -lpgport to ecpglib link only on win32.
Next
From: Bruce Momjian
Date:
Subject: Re: Revert addition of -lpgport, which breaks the build