[vlc-devel] _pic, $(pic), BUILD_PIC
rem at videolan.org
Mon Feb 20 10:50:15 CET 2006
I'm currently trying to make sense out of all this PIC stuff in the
As far as I understand, VLC supports three kind of architectures as
regard Position Independent Code:
- those that don't need it (Windows, and seemingly Darwin),
- those that need it for shared objects (ELF, incl. Linux, *BSD, ...),
- those where we don't support plugins, but only builtins.
It doesn't make sense to build PIC object code in the first or third
cases. As for the second case, is there any reason why we should still
build non-PIC code at all ? I presume plugins always have to be built
as PIC, and vlc itself always as non-PIC; so the difference only
matters for libvlc. As such, would there be any problem if we removed
the _pic.a build targets within modules/ ?
In the longer term, should we keep non-PIC (static) libvlc *and* a PIC
libvlc that seems to needed for the Mozilla plugin ? Can't we just
remove the non-PIC version ? I am aware that it makes the static
libvlc.a bigger, but it speeds up compilation, and you should probably
rather use the shared libvlc if disk/memory space is an issue. Or is
there any platform needing PIC where shared libvlc sucks ?
As for BUILD_PIC (the automake conditionnal) and $(pic), does anyone
sees a reason why there values would not match ? $(pic) appears to
contains pic when PIC is needed for shared objects, and no otherwise.
But BUILD_PIC is sometimes true when pic is no, which doesn't make
sense to me.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
More information about the vlc-devel