Issue 26675 - libpng.so is linked against unnecessary libraries ($STDSHL)
Summary: libpng.so is linked against unnecessary libraries ($STDSHL)
Status: CLOSED FIXED
Alias: None
Product: gsl
Classification: Code
Component: code (show other issues)
Version: current
Hardware: All Linux, all
: P3 Trivial (vote)
Target Milestone: OOo 2.0
Assignee: philipp.lohmann
QA Contact: issues@gsl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-03-18 14:17 UTC by taniguchi
Modified: 2004-05-12 13:45 UTC (History)
1 user (show)

See Also:
Issue Type: PATCH
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
libpng link library patch (599 bytes, patch)
2004-03-18 14:19 UTC, taniguchi
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description taniguchi 2004-03-18 14:17:51 UTC
A file libpng.so, which is built in gtk/libpng module, is linked against $STDSHL
that is unnecessary.

When I build OOo with Forte 8 on Solaris sparc, no error is reported.
But when I build it with gcc on Solaris x86, some symbol resolution error
 happens in gtk/gtk module.


Solaris 9 Sparc with Forte 8
[yasuaki@wind lib]$ ldd libpng.so 
        libpthread.so.1 =>       /usr/lib/libpthread.so.1
        libCrun.so.1 =>  /usr/lib/libCrun.so.1
        libm.so.1 =>     /usr/lib/libm.so.1
        libc.so.1 =>     /usr/lib/libc.so.1
        libstlport_sunpro.so =>  (file not found)
        libw.so.1 =>     /usr/lib/libw.so.1
        libdl.so.1 =>    /usr/lib/libdl.so.1
        libthread.so.1 =>        /usr/lib/libthread.so.1
        librt.so.1 =>    /usr/lib/librt.so.1
        libaio.so.1 =>   /usr/lib/libaio.so.1
        libmd5.so.1 =>   /usr/lib/libmd5.so.1
        /usr/platform/SUNW,Sun-Blade-100/lib/libc_psr.so.1
        /usr/platform/SUNW,Sun-Blade-100/lib/libmd5_psr.so.1
but, libpng.so is not needed to link agains libstlport_sunpro.so, libCrun.so and
so on.
Comment 1 taniguchi 2004-03-18 14:19:53 UTC
Created attachment 13904 [details]
libpng link library patch
Comment 2 taniguchi 2004-03-18 14:20:59 UTC
I'm sorry, I forgot to write cvs branch name.
CVS branch is cws_src680_nwf.
Comment 3 philipp.lohmann 2004-03-18 14:34:42 UTC
applied in CWS nwf
Comment 4 philipp.lohmann 2004-03-18 14:35:24 UTC
setting target, OS and type
Comment 5 taniguchi 2004-03-19 11:30:55 UTC
I found gtk_libpng-1.2.1.patch.patch has problem.

When I compile on Solaris with SunONE 8, I need to link against libm and libc
explicitly because $LINKFLAGS contains -library=no%Cstd.

Index: gtk/libpng-1.2.1.patch
===================================================================
RCS file: /cvs/external/gtk/Attic/libpng-1.2.1.patch,v
retrieving revision 1.1.2.2
diff -u -r1.1.2.2 libpng-1.2.1.patch
--- gtk/libpng-1.2.1.patch	18 Mar 2004 14:33:04 -0000	1.1.2.2
+++ gtk/libpng-1.2.1.patch	19 Mar 2004 11:25:04 -0000
@@ -3,7 +3,7 @@
 ***************
 *** 1 ****
 ! dummy
---- 1,38 ----
+--- 1,42 ----
 ! PRJ=../../../..
 ! 
 ! PRJNAME=libpng
@@ -38,7 +38,11 @@
 ! SHL1TARGET=png
 ! SHL1IMPLIB=ipng
 ! SHL1STDLIBS=-lzlib
+! .IF "$(OS)" == "SOLARIS" && "$(COM)"=="C52"
+! STDSHL=-lm -lc
+! .ELSE
 ! STDSHL=
+! .ENDIF
 ! SHL1OBJS=$(SLOFILES)
 ! 
 ! .INCLUDE :	target.mk
Comment 6 philipp.lohmann 2004-03-19 11:46:19 UTC
commited
Comment 7 philipp.lohmann 2004-04-05 08:57:52 UTC
verified
Comment 8 philipp.lohmann 2004-05-12 13:45:26 UTC
merged in 680m39