[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] Start of freeze for libvirt-0.9.10 and availability of rc1



On 02/06/2012 08:46 PM, Alex Jia wrote:

>>> 4.
>>> *** Warning: Linking the shared library libvirt_test.la against the
>>> non-libtool
>>> *** objects  probes.o is not portable!
>>>    CCLD   libvirt-qemu.la
>>>
>>>
>>> Notes, I often meet the item 3 and 4 warnings when compiling, although I
>>> saw gcc book said
>>> they were common error and should use .o instead of .la, we can ignore
>>> these 2 warnings
>>> in here, right?
>> Not the gcc book.  But this has previously come up on this list, and the
> The common error is introduced in ch8 of "The Definitive Guide to GCC"
> v1 book.
> but I think it should be a warning not error.

It _is_ a warning, not an error, and the warning is coming from libtool,
with no way for us to shut it up unless we patch libtool, or else write
a probes.lo wrapper around probes.o.  It doesn't halt the build.

>> answer is still the same - libtool doesn't have a way to let us shut it
>> up when we _know_ that we are doing something that works on Linux, and
>> where we are not doing the non-portable action of using probes.o on
>> non-Linux because systemtap is Linux-specific.  You can ignore the
> Yeah, indeed.
>> warning, and any patch to silence it would have to come from upstream
>> libtool, or else finding a way to create a .lo file that wraps the
>> generated probes.o file but which libtool can still link with.
> However, libtool manual said we may silence this warning if specify link
> library the path
> with '-lm' option, I'm not sure whether we need to follow this, as you
> said, after all, libvirt
> also supports non-linux platform.

We support non-Linux platforms, which is why we are using libtool.  And
on other platforms, linking probes.o via libtool won't work, which is
why libtool is issuing the warning.  But probes.o is only generated on
Linux, and Linux happens to be a platform where libtool gets away with
linking probes.o without needing a wrapper .lo file.  We've been through
this before - the warning is annoying, but harmless, precisely because
we are doing something only on Linux, where we know that it works.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]