On Wednesday, February 5, 2003, at 10:47 PM, Josh Coalson wrote:> --- Matt Zimmerman <mdz@debian.org> wrote: > > good, very good. it may take me a little bit to get to it > since I'm starting a new job next week. > > Ben, can you inspect the patch and confirm that it covers > what you also suggested?The patch fixed the problem with your libs. However, when linking the xmms plugin i still get: *** Warning: This library needs some functionality provided by -lstdc++. *** I have the capability to make that library automatically link in when *** you link to this library. But I can only do this if you have a *** shared version of the library, which you do not appear to have. Which causes libtool to build a static library instead of the plugin. If i remember right this is some sort of libtool bug. I'll ask someone.. -Ben
On Tuesday, February 11, 2003, at 08:11 AM, Matt Zimmerman wrote:> On Tue, Feb 11, 2003 at 07:55:37AM -0800, Ben Hines wrote: > >> The patch fixed the problem with your libs. However, when linking the >> xmms plugin i still get: >> >> *** Warning: This library needs some functionality provided by >> -lstdc++. >> *** I have the capability to make that library automatically link in >> when >> *** you link to this library. But I can only do this if you have a >> *** shared version of the library, which you do not appear to have. > > Hmm...can you post the libtool command line and resulting gcc command > line > which caused this message? I did not think any C++ code was linked > into the > xmms plugin, but that may have changed since I last looked at it.I thnk it comes from the -lstdc++ which is added to ID3LIB_LIBS in configure.in. -lstdc++ is only needed on darwin for C++ code if you link with the "gcc" (or ld, of course) commands. If you link with the "g++", it is included implicitly. Additionally, darwin's stdc++ lib is static only. If i remove the -lstdc++ from the libtool line below, it links, and works in xmms. I think the -lstdc++ is not needed when linking to libid3 on darwin, even though its C++, because libstdc++.a is already (a static) part of libid3. You might be able to replicate this on the compile farm, even though it is only has gcc2/ darwin 10.1 currently. -Ben ../../libtool-disable-static --mode=link gcc -I../.. -I./include -I../../include -O3 -DNDEBUG -fomit-frame-pointer -funroll-loops -finline-functions -Wall -W -Winline -DFLaC__INLINE=__inline__ -g -O2 -I/sw/include -I/sw/include -I/sw/include/xmms -I/sw/include/gtk-1.2 -I/sw/include/glib-1.2 -I/sw/lib/glib/include -I/usr/X11R6/include -L/sw/src/flac-1.1.0-3/flac-1.1.0/src/libOggFLAC/.libs -L/sw/src/flac-1.1.0-3/flac-1.1.0/src/libFLAC/.libs -o libxmms-flac.la -rpath /sw/lib/xmms/Input -module -avoid-version charset.lo configure.lo plugin.lo wrap_id3.lo fileinfo.lo ../../src/plugin_common/libplugin_common.la ../../src/share/grabbag/libgrabbag.la ../../src/share/gain_analysis/libgain_analysis.la ../../src/share/utf8/libutf8.la ../../src/libFLAC/libFLAC.la -L../../src/libFLAC/.libs -L/sw/lib -L/sw/lib -L/usr/X11R6/lib -lgtk -lgdk -lgmodule -lglib -ldl -lintl -lXext -lX11 -lm -lxmms -L/sw/lib -lid3 -lz -lstdc++ -lstdc++ -lz mkdir .libs rm -fr .libs/libxmms-flac.la .libs/libxmms-flac.* .libs/libxmms-flac.* *** Warning: This library needs some functionality provided by -lstdc++. *** I have the capability to make that library automatically link in when *** you link to this library. But I can only do this if you have a *** shared version of the library, which you do not appear to have. *** Warning: This library needs some functionality provided by -lstdc++. *** I have the capability to make that library automatically link in when *** you link to this library. But I can only do this if you have a *** shared version of the library, which you do not appear to have. *** Warning: libtool could not satisfy all declared inter-library *** dependencies of module libxmms-flac. Therefore, libtool will create *** a static module, that should work as long as the dlopening *** application is linked with the -dlopen flag.
Christian Weisgerber
2004-Sep-10 16:45 UTC
[Flac-dev] Re: non-PIC code in shared libs again
Ben Hines <bhines@alumni.ucsd.edu> wrote:> The patch fixed the problem with your libs. However, when linking the > xmms plugin i still get: > > *** Warning: This library needs some functionality provided by -lstdc++.This is because of id3lib, which is written in C++. Mixing C and C++ is problematic. As far as I understand, the final linking should always be done with the C++ compiler in this case.> If i remember right this is some sort of libtool bug. I'll ask someone..I don't think so. Using something like "cc -o foo c.o c++.o -lstdc++" is highly questionable. -- Christian "naddy" Weisgerber naddy@mips.inka.de
On Tue, Feb 11, 2003 at 07:55:37AM -0800, Ben Hines wrote:> The patch fixed the problem with your libs. However, when linking the > xmms plugin i still get: > > *** Warning: This library needs some functionality provided by -lstdc++. > *** I have the capability to make that library automatically link in > when > *** you link to this library. But I can only do this if you have a > *** shared version of the library, which you do not appear to have.Hmm...can you post the libtool command line and resulting gcc command line which caused this message? I did not think any C++ code was linked into the xmms plugin, but that may have changed since I last looked at it. -- - mdz
On Tue, Feb 11, 2003 at 05:14:45PM +0000, Christian Weisgerber wrote:> Ben Hines <bhines@alumni.ucsd.edu> wrote: > > > The patch fixed the problem with your libs. However, when linking the > > xmms plugin i still get: > > > > *** Warning: This library needs some functionality provided by -lstdc++. > > This is because of id3lib, which is written in C++. Mixing C and > C++ is problematic. As far as I understand, the final linking > should always be done with the C++ compiler in this case.Yes, unfortunately, the current release of libtool does not handle this correctly. http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=128391 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=179735 etc. -- - mdz