[0.11] gstreamer: gstconfig.h: adds and uses SunPro visibility attribute for proper function exports

Sebastian Dröge slomo at kemper.freedesktop.org
Tue Jan 10 04:03:27 PST 2012


Module: gstreamer
Branch: 0.11
Commit: c8c961ac816ec911f00ec06852779e16d181432d
URL:    http://cgit.freedesktop.org/gstreamer/gstreamer/commit/?id=c8c961ac816ec911f00ec06852779e16d181432d

Author: Idar Tollefsen <itollefs at cisco.com>
Date:   Sun Jan  1 16:46:04 2012 +0100

gstconfig.h: adds and uses SunPro visibility attribute for proper function exports

Define GST_EXPORT for SunPro.

https://bugzilla.gnome.org/show_bug.cgi?id=667289

---

 gst/gst_private.h  |    2 +-
 gst/gstconfig.h.in |    4 ++++
 2 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/gst/gst_private.h b/gst/gst_private.h
index 6bd6725..c36a72d 100644
--- a/gst/gst_private.h
+++ b/gst/gst_private.h
@@ -141,7 +141,7 @@ gint priv_gst_date_time_compare (gconstpointer dt1, gconstpointer dt2);
 
 #ifndef GST_DISABLE_REGISTRY
 /* Secret variable to initialise gst without registry cache */
-extern gboolean _gst_disable_registry_cache;
+GST_EXPORT gboolean _gst_disable_registry_cache;
 #endif
 
 /* provide inline gst_g_value_get_foo_unchecked(), used in gststructure.c */
diff --git a/gst/gstconfig.h.in b/gst/gstconfig.h.in
index 4138b18..37db17e 100644
--- a/gst/gstconfig.h.in
+++ b/gst/gstconfig.h.in
@@ -229,7 +229,11 @@
 #endif
 #else /* not _MSC_VER */
 #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
 
 #endif /* __GST_CONFIG_H__ */



More information about the gstreamer-commits mailing list