This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: g++-mike-eh8-C test failure
- To: dave at hiauly1 dot hia dot nrc dot ca (John David Anglin)
- Subject: Re: g++-mike-eh8-C test failure
- From: "John David Anglin" <dave at hiauly1 dot hia dot nrc dot ca>
- Date: Sun, 30 Apr 2000 11:46:46 -0400 (EDT)
- Cc: jason at cygnus dot com, law at cygnus dot com, gcc-patches at gcc dot gnu dot org, egcs-bugs at egcs dot cygnus dot com
After all this grief with duplicate routines, I decided to change the
hpux configuration for libstdc++ so that the standard libraries are not
linked into libstdc++.sl. This resolves the problem.
I reran the tests. There was one new failure with "-threads":
FAIL: g++.law/profile1.C (test for excess errors)
However, this is expected since "-pg" and "-threads" are not compatible
(there are no profiling libraries for DCE threads). Of course, nobody
will get this far unless the configure patch for hpux threads gets
installed.
Regarding the installed location of libstdc++, there is a problem
under hpux when both shared and archive libraries are installed. For
the shared_archive or archive_shared linker preference mechanism to
work, both the archive and shared libraries must be in the same
directory. The archive version of libstdc++ is installed in
the compiler installation director as a link to a versioned archive
library in ${prefix}/lib (e.g., libstdc++.a.2.10.0). The shared
version is installed with no versioning in ${prefix}/lib. The
compiler location is searched first. As a result, the archive
version is found first and always selected.
My solution is to remove the link to the archive library in the
compiler directory, version the shared library, and add links in
${prefix}/lib to the versioned libraries. For example,
289 (hiauly1)dave> ll libstdc*
lrwxr-xr-x 1 bin bin 18 Apr 30 11:01 libstdc++.a -> libstdc++.a.2.10.0
-rw-r--r-- 1 bin bin 577896 Apr 30 10:40 libstdc++.a.2.10.0
lrwxr-xr-x 1 bin bin 19 Apr 30 11:01 libstdc++.sl -> libstdc++.sl.2.10.0
-r-xr-xr-x 1 bin bin 605244 Apr 30 10:40 libstdc++.sl.2.10.0
I did the same in ${prefix}/lib/threads.
This allows removing the version specific compiler stuff without affecting
previously linked apps. Any thoughts on this?
Dave
--
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)
--- hpux.ml.orig Sun Aug 30 17:18:44 1998
+++ hpux.ml Fri Apr 28 19:23:06 2000
@@ -3,4 +3,4 @@
SHLIB = libstdc++.sl
LIBS = $(ARLIB) $(ARLINK) $(SHLIB)
DEPLIBS = ../$(SHLIB)
-SHFLAGS = $(PICFLAG)
+SHFLAGS = -nostdlib $(PICFLAG)