[vlc-devel] [RFC] Plugins linking

Rémi Denis-Courmont rdenis at simphalempin.com
Fri Feb 13 18:10:34 CET 2009


There has been much trolling (especially from my own self) on the linking
of VLC plugins against the VLC core since I changed to try to fix static
builds a while ago. I would euphemistically say that this was probably not
the brightest idea of mine.

There are basically to somewhat dependent issues here:
- Do we link plugins against libvlccore?
- Do we include (accurate) revision information in the run-time?
Lets try to summarize the pros and cons of each combination.

Not linking the plugins against libvlccore:
+ avoids relinking all plugins whenever libvlccore is changed,
+ is necessary to link libvlccore statically into vlc (or another binary),
- is considered ugly by some,
- breaks the browsers plugins and some language bindings, unless some ugly
run-time linking hack is used (see the JPD patch thread),
- prevents missing symbols detection at build-time of plugins,
- does not work on Windows (hence a special hack for Windows currently).

Including the VCS revision information:
+ may be helpful for bug reports against non-release builds (not so much,
since we don't ship debug symbols though),
+ looks cool in the About dialog,
- breaks parallel make in some unclear cases (not sure how to fix this),
- forces a relink of anything that links against libvlccore at every make

What's the link between these two? If we include revision infos, we need to
relink every plugin (200+) at every make. In my opinion, this is completely
unacceptable. And then, when doing one-shot release builds, revision infos
are hardly any use, since we have the release version number. Hence, I
think, we can realistically only choose between.

If we do keep not linking plugins, removing revision infos would fix the
make race condition. On the other hand, it is perhaps silly to remove the
revision infos in that case, as they're not nearly as harmful as if we did
link plugins properly.

In retrospect, I would prefer to remove revision infos and resume linking
plugins. This is sorta what we had in 0.9. More exactly 0.9 had incorrect
revision infos, which I think is worse than none at all. Another option is
keep things as are, and merge JPD's hack on top of my earlier hack.

Rémi Denis-Courmont

More information about the vlc-devel mailing list