[Bug 779344] plugin: Unify static and dynamic plugin interface
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Tue Mar 7 01:48:10 UTC 2017
https://bugzilla.gnome.org/show_bug.cgi?id=779344
--- Comment #24 from Nicolas Dufresne (stormer) <nicolas at ndufresne.ca> ---
So I just removed the need-work as all the review comments are about the
generated xml, the "from git" will be back to release upon next release, as I
expect "make update" to be run for each major version.
About the snippet that I'm worried about:
>/* Only use __declspec(dllexport/import) when we have been built with MSVC or
> * the user is linking to us with MSVC. The only remaining case is when we were
> * built with MinGW and are linking with MinGW in which case we rely on the
> * linker to auto-export/import symbols. Of course all this is only used when
> * not linking statically.
> *
> * NOTE: To link to GStreamer statically on Windows, you must define
> * GST_STATIC_COMPILATION or the prototypes will cause the compiler to search
> * for the symbol inside a DLL.
> */
>#if (@GSTCONFIG_BUILT_WITH_MSVC@ || defined(_MSC_VER)) && >!defined(GST_STATIC_COMPILATION)
># define GST_PLUGIN_EXPORT __declspec(dllexport)
># ifdef GST_EXPORTS
># define GST_EXPORT __declspec(dllexport)
># else
># define GST_EXPORT __declspec(dllimport) extern
># endif
>#else
># define GST_PLUGIN_EXPORT
># if (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590))
># define GST_EXPORT extern __attribute__ ((visibility ("default")))
># else
># define GST_EXPORT extern
># endif
>#endif
Re-reading this, I can only conclude that with MSVC, you can build static or
dynamic, but not both at the same time, while with MingW it's the same as with
GCC / CLANG. So basically, with MSVC, you need to build GStreamer twice if you
want both static and dynamic, the -static recipes were not helping much.
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list