This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug bootstrap/37660] [4.4 Regression] Error Building libssp, recent update
- From: "dave dot korn dot cygwin at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Jan 2009 13:41:33 -0000
- Subject: [Bug bootstrap/37660] [4.4 Regression] Error Building libssp, recent update
- References: <bug-37660-6183@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #6 from dave dot korn dot cygwin at gmail dot com 2009-01-16 13:41 -------
(In reply to comment #5)
> If you look at the (static) libgcc.a, when shared libs are enabled, it
> contains only symbols that are not exported from the shared dll. Only the
> 'API-stable' symbols are exported. That is a good thing. So the libgcc.a code
> does not duplicate any code in libgcc_s.[a|dll].
Sorry Danny, I don't understand. I think what you're saying is that
shared linking: libgcc_s.dll.a + libgcc.a
supplies the same overall set of symbols as
static linking: libgcc_eh.a + libgcc.a
since if libgcc.a only contains stuff that is not exported from the DLL, then
-static-libgcc would fail - unless everything that is exported from the DLL is
available statically in libgcc_eh.a, which implies that the DLL could only
export the libgcc_eh functions? I must have a misunderstanding somewhere.
Also, I have been unable to verify your explanation. In my current build
directory:
/gnu/gcc/obj-ng-fix $ nm prev-i686-pc-cygwin/libgcc/libgcc.a | grep " T " | cu
t -d' ' -f3 > static-lib.txt
/gnu/gcc/obj-ng-fix $ nm prev-i686-pc-cygwin/libgcc/shlib/libgcc_s.dll.a | gre
p " T " | cut -d' ' -f3 > import-lib.txt
/gnu/gcc/obj-ng-fix $ cat static-lib.txt import-lib.txt | sort | uniq -d | wc
60 60 713
/gnu/gcc/obj-ng-fix $ cat static-lib.txt import-lib.txt | sort | uniq -u | wc
37 37 812
/gnu/gcc/obj-ng-fix $
there are 60 common functions and 37 unique ones - the unique ones are indeed
the contents of libgcc_eh, plus these:
___chkstk
___eprintf
___gcc_bcmp
___gnat_default_lock
___gnat_default_unlock
___gnat_install_locks
___gthread_active_p
___gthread_mutex_lock
___gthread_mutex_unlock
___udiv_w_sdiv
__alloca
which are only in the static libs at all.
Should I have understood you to mean that only the API-stable symbols are not
duplicated? Or only the EH-related symbols?
cheers,
DaveK
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37660