From: | Richard Cook x261 <rcook(at)insightful(dot)com> |
---|---|
To: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
Cc: | pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: Bug #706: Wrong shlib flag for GCC compilation on Solaris |
Date: | 2002-07-10 17:18:06 |
Message-ID: | Pine.LNX.4.21.0207100949060.32726-100000@sprime.statsci.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
Bruce,
My apologies. The file I worked with was from the postgresql-7.1.3.tar.gz.
I had started out with the latest (7.2.1) tar, but after various failures
rolled back to the 7.1.3 source, since I found evidence on the net that
somebody had succeeded in building that on Solaris. I lost track of that
change in source over the holiday weekend. It looks like 7.2.1 has it
right.
Even so, I have not yet fully succeeded in building with the 7.2.1 source.
Using GCC, I got a running postgres, but failed to get pgaccess to work. I
think that may be due to a corrupt libssl.so, but have not gone back to
verify this. Using Sun tools, the compilation succeeded, but I got a
WriteControlFile failure (File exists) when running "make check", which I
never could diagnose.
So now I have a fully working 7.1.3 build, and I am tempted to leave well
enough alone. Are the changes in 7.2.1 worth yet another build attempt?
Richard
P.S. Thanks for your reply. I have your book right next to me.
On Tue, 9 Jul 2002, Bruce Momjian wrote:
>
> In current CVS I see this, which looks fine. Does yours look the same?
>
> ---------------------------------------------------------------------------
>
>
> ifeq ($(PORTNAME), solaris)
> shlib :=
> lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_
> VERSION)
> ifndef cplusplus
> ifeq ($(GCC), yes)
> LINK.shared = $(CC) -shared
> else
> LINK.shared = $(CC) -G
> endif
> else
> ifeq ($(GXX), yes)
> LINK.shared = $(CXX) -shared
> else
> LINK.shared = $(CXX) -G
> endif
> endif
> ifeq ($(with_gnu_ld), yes)
> LINK.shared += -Wl,-soname,$(soname)
> else
> LINK.shared += -h $(soname)
> endif
> endif
>
>
>
> ---------------------------------------------------------------------------
>
> pgsql-bugs(at)postgresql(dot)org wrote:
> > Richard Cook (rcook(at)insightful(dot)com) reports a bug with a severity of 2
> > The lower the number the more severe it is.
> >
> > Short Description
> > Wrong shlib flag for GCC compilation on Solaris
> >
> > Long Description
> > In the file .../src/Makefile.shlib, line 178, the "-G" flag is set for compilation of shared libraries on Solaris. This is okay if you are using the Sun toolset. Unfortunately GCC needs the flag "-shared" instead. The symptom that reveals this is that pgaccess won't work because libpgtcl.so contains the "main" symbol. My workaround was to edit in the new flag. Somebody on the team might want to modify the Makefile to account for use of the gcc toolset. This defect set me back three days. Please don't let anyone else suffer through this. It might be well to post it as a known problem on Solaris.
> >
> > Sample Code
> >
> >
> > No file was uploaded with this report
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 6: Have you searched our list archives?
> >
> > http://archives.postgresql.org
> >
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | pgsql-bugs | 2002-07-10 23:51:09 | Bug #707: Cannot connect Java Applet to Postgresql database |
Previous Message | Tatsuo Ishii | 2002-07-10 05:46:36 | Re: Multibyte characters handling bug in varchar() |