summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.com>2018-03-12 23:03:26 +0000
committerTim-Philipp Müller <tim@centricular.com>2018-03-13 00:57:37 +0000
commitd86a90550bf7e2cba312801a0861fa2ece99d7a3 (patch)
tree8ddb05ead37593a2dc37823dd1c01cbf72243f1f
parent6b286fb7ddeae1d45907465c49b8a414ae208332 (diff)
net: GST_EXPORT -> GST_NET_API
We need different export decorators for the different libs. For now no actual change though, just rename before the release, and add prelude headers to define the new decorator to GST_EXPORT.
-rw-r--r--libs/gst/net/Makefile.am1
-rw-r--r--libs/gst/net/gstnet.h2
-rw-r--r--libs/gst/net/gstnetaddressmeta.h9
-rw-r--r--libs/gst/net/gstnetclientclock.h9
-rw-r--r--libs/gst/net/gstnetcontrolmessagemeta.h7
-rw-r--r--libs/gst/net/gstnettimepacket.h15
-rw-r--r--libs/gst/net/gstnettimeprovider.h5
-rw-r--r--libs/gst/net/gstptpclock.h17
-rw-r--r--libs/gst/net/meson.build1
-rw-r--r--libs/gst/net/net-prelude.h31
-rw-r--r--libs/gst/net/net.h2
11 files changed, 71 insertions, 28 deletions
diff --git a/libs/gst/net/Makefile.am b/libs/gst/net/Makefile.am
index 35ed9062d..de254e9ed 100644
--- a/libs/gst/net/Makefile.am
+++ b/libs/gst/net/Makefile.am
@@ -3,6 +3,7 @@ lib_LTLIBRARIES = libgstnet-@GST_API_VERSION@.la
libgstnet_@GST_API_VERSION@_includedir = $(includedir)/gstreamer-@GST_API_VERSION@/gst/net
libgstnet_@GST_API_VERSION@_include_HEADERS = \
net.h \
+ net-prelude.h \
gstnet.h \
gstnetaddressmeta.h \
gstnetclientclock.h \
diff --git a/libs/gst/net/gstnet.h b/libs/gst/net/gstnet.h
index 96cc8b8e9..28173809c 100644
--- a/libs/gst/net/gstnet.h
+++ b/libs/gst/net/gstnet.h
@@ -21,6 +21,8 @@
#ifndef __GST_NET_H__
#define __GST_NET_H__
+#include <gst/net/net-prelude.h>
+
#include <gst/net/gstnetaddressmeta.h>
#include <gst/net/gstnetclientclock.h>
#include <gst/net/gstnettimepacket.h>
diff --git a/libs/gst/net/gstnetaddressmeta.h b/libs/gst/net/gstnetaddressmeta.h
index e89141368..e949b3117 100644
--- a/libs/gst/net/gstnetaddressmeta.h
+++ b/libs/gst/net/gstnetaddressmeta.h
@@ -22,6 +22,7 @@
#include <gst/gst.h>
#include <gio/gio.h>
+#include <gst/net/net-prelude.h>
G_BEGIN_DECLS
@@ -40,20 +41,20 @@ struct _GstNetAddressMeta {
GSocketAddress *addr;
};
-GST_EXPORT
+GST_NET_API
GType gst_net_address_meta_api_get_type (void);
#define GST_NET_ADDRESS_META_API_TYPE (gst_net_address_meta_api_get_type())
/* implementation */
-GST_EXPORT
+GST_NET_API
const GstMetaInfo *gst_net_address_meta_get_info (void);
#define GST_NET_ADDRESS_META_INFO (gst_net_address_meta_get_info())
-GST_EXPORT
+GST_NET_API
GstNetAddressMeta * gst_buffer_add_net_address_meta (GstBuffer *buffer,
GSocketAddress *addr);
-GST_EXPORT
+GST_NET_API
GstNetAddressMeta * gst_buffer_get_net_address_meta (GstBuffer *buffer);
G_END_DECLS
diff --git a/libs/gst/net/gstnetclientclock.h b/libs/gst/net/gstnetclientclock.h
index 0a9a26cfc..b741e6b7b 100644
--- a/libs/gst/net/gstnetclientclock.h
+++ b/libs/gst/net/gstnetclientclock.h
@@ -29,6 +29,7 @@
#include <gst/gst.h>
#include <gst/gstsystemclock.h>
+#include <gst/net/net-prelude.h>
G_BEGIN_DECLS
@@ -68,10 +69,10 @@ struct _GstNetClientClockClass {
gpointer _gst_reserved[GST_PADDING];
};
-GST_EXPORT
+GST_NET_API
GType gst_net_client_clock_get_type (void);
-GST_EXPORT
+GST_NET_API
GstClock* gst_net_client_clock_new (const gchar *name, const gchar *remote_address,
gint remote_port, GstClockTime base_time);
@@ -89,10 +90,10 @@ GstClock* gst_net_client_clock_new (const gchar *name, const gchar *remote_addre
typedef struct _GstNetClientClock GstNtpClock;
typedef struct _GstNetClientClockClass GstNtpClockClass;
-GST_EXPORT
+GST_NET_API
GType gst_ntp_clock_get_type (void);
-GST_EXPORT
+GST_NET_API
GstClock* gst_ntp_clock_new (const gchar *name, const gchar *remote_address,
gint remote_port, GstClockTime base_time);
diff --git a/libs/gst/net/gstnetcontrolmessagemeta.h b/libs/gst/net/gstnetcontrolmessagemeta.h
index 39fe66d8a..b51b87683 100644
--- a/libs/gst/net/gstnetcontrolmessagemeta.h
+++ b/libs/gst/net/gstnetcontrolmessagemeta.h
@@ -22,6 +22,7 @@
#include <gst/gst.h>
#include <gio/gio.h>
+#include <gst/net/net-prelude.h>
G_BEGIN_DECLS
@@ -41,7 +42,7 @@ struct _GstNetControlMessageMeta {
GSocketControlMessage *message;
};
-GST_EXPORT
+GST_NET_API
GType gst_net_control_message_meta_api_get_type (void);
#define GST_NET_CONTROL_MESSAGE_META_API_TYPE \
@@ -52,13 +53,13 @@ GType gst_net_control_message_meta_api_get_type (void);
/* implementation */
-GST_EXPORT
+GST_NET_API
const GstMetaInfo *gst_net_control_message_meta_get_info (void);
#define GST_NET_CONTROL_MESSAGE_META_INFO \
(gst_net_control_message_meta_get_info())
-GST_EXPORT
+GST_NET_API
GstNetControlMessageMeta * gst_buffer_add_net_control_message_meta (GstBuffer * buffer,
GSocketControlMessage * message);
diff --git a/libs/gst/net/gstnettimepacket.h b/libs/gst/net/gstnettimepacket.h
index 36ceef83b..a04ea030d 100644
--- a/libs/gst/net/gstnettimepacket.h
+++ b/libs/gst/net/gstnettimepacket.h
@@ -23,6 +23,7 @@
#include <gst/gst.h>
#include <gio/gio.h>
+#include <gst/net/net-prelude.h>
G_BEGIN_DECLS
@@ -47,26 +48,26 @@ struct _GstNetTimePacket {
GstClockTime remote_time;
};
-GST_EXPORT
+GST_NET_API
GType gst_net_time_packet_get_type (void);
-GST_EXPORT
+GST_NET_API
GstNetTimePacket* gst_net_time_packet_new (const guint8 *buffer);
-GST_EXPORT
+GST_NET_API
GstNetTimePacket* gst_net_time_packet_copy (const GstNetTimePacket *packet);
-GST_EXPORT
+GST_NET_API
void gst_net_time_packet_free (GstNetTimePacket *packet);
-GST_EXPORT
+GST_NET_API
guint8* gst_net_time_packet_serialize (const GstNetTimePacket *packet);
-GST_EXPORT
+GST_NET_API
GstNetTimePacket* gst_net_time_packet_receive (GSocket * socket,
GSocketAddress ** src_address,
GError ** error);
-GST_EXPORT
+GST_NET_API
gboolean gst_net_time_packet_send (const GstNetTimePacket * packet,
GSocket * socket,
GSocketAddress * dest_address,
diff --git a/libs/gst/net/gstnettimeprovider.h b/libs/gst/net/gstnettimeprovider.h
index 9343306f8..d1f6de34f 100644
--- a/libs/gst/net/gstnettimeprovider.h
+++ b/libs/gst/net/gstnettimeprovider.h
@@ -24,6 +24,7 @@
#define __GST_NET_TIME_PROVIDER_H__
#include <gst/gst.h>
+#include <gst/net/net-prelude.h>
G_BEGIN_DECLS
@@ -62,10 +63,10 @@ struct _GstNetTimeProviderClass {
gpointer _gst_reserved[GST_PADDING];
};
-GST_EXPORT
+GST_NET_API
GType gst_net_time_provider_get_type (void);
-GST_EXPORT
+GST_NET_API
GstNetTimeProvider* gst_net_time_provider_new (GstClock *clock,
const gchar *address,
gint port);
diff --git a/libs/gst/net/gstptpclock.h b/libs/gst/net/gstptpclock.h
index 6a1c83906..06ca5cf8b 100644
--- a/libs/gst/net/gstptpclock.h
+++ b/libs/gst/net/gstptpclock.h
@@ -23,6 +23,7 @@
#include <gst/gst.h>
#include <gst/gstsystemclock.h>
+#include <gst/net/net-prelude.h>
G_BEGIN_DECLS
@@ -75,19 +76,19 @@ struct _GstPtpClockClass {
*/
#define GST_PTP_CLOCK_ID_NONE ((guint64) -1)
-GST_EXPORT
+GST_NET_API
GType gst_ptp_clock_get_type (void);
-GST_EXPORT
+GST_NET_API
gboolean gst_ptp_is_supported (void);
-GST_EXPORT
+GST_NET_API
gboolean gst_ptp_is_initialized (void);
-GST_EXPORT
+GST_NET_API
gboolean gst_ptp_init (guint64 clock_id,
gchar ** interfaces);
-GST_EXPORT
+GST_NET_API
void gst_ptp_deinit (void);
#define GST_PTP_STATISTICS_NEW_DOMAIN_FOUND "GstPtpStatisticsNewDomainFound"
@@ -142,13 +143,13 @@ void gst_ptp_deinit (void);
typedef gboolean (*GstPtpStatisticsCallback) (guint8 domain,
const GstStructure * stats,
gpointer user_data);
-GST_EXPORT
+GST_NET_API
gulong gst_ptp_statistics_callback_add (GstPtpStatisticsCallback callback,
gpointer user_data, GDestroyNotify destroy_data);
-GST_EXPORT
+GST_NET_API
void gst_ptp_statistics_callback_remove (gulong id);
-GST_EXPORT
+GST_NET_API
GstClock* gst_ptp_clock_new (const gchar *name,
guint domain);
diff --git a/libs/gst/net/meson.build b/libs/gst/net/meson.build
index c32bef25e..0a76fd291 100644
--- a/libs/gst/net/meson.build
+++ b/libs/gst/net/meson.build
@@ -17,6 +17,7 @@ gst_net_headers = [
'gstnettimepacket.h',
'gstnettimeprovider.h',
'gstptpclock.h',
+ 'net-prelude.h',
'net.h',
]
install_headers(gst_net_headers, subdir : 'gstreamer-1.0/gst/net/')
diff --git a/libs/gst/net/net-prelude.h b/libs/gst/net/net-prelude.h
new file mode 100644
index 000000000..8db756574
--- /dev/null
+++ b/libs/gst/net/net-prelude.h
@@ -0,0 +1,31 @@
+/* GStreamer Net Library
+ * Copyright (C) 2018 GStreamer developers
+ *
+ * net-prelude.h: prelude include header for gst-net library
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
+ */
+
+#ifndef __GST_NET_PRELUDE_H__
+#define __GST_NET_PRELUDE_H__
+
+#include <gst/gst.h>
+
+#ifndef GST_NET_API
+#define GST_NET_API GST_EXPORT
+#endif
+
+#endif /* __GST_NET_PRELUDE_H__ */
diff --git a/libs/gst/net/net.h b/libs/gst/net/net.h
index 8af032e79..abecd3235 100644
--- a/libs/gst/net/net.h
+++ b/libs/gst/net/net.h
@@ -22,6 +22,8 @@
#ifndef __GST_NET__H__
#define __GST_NET__H__
+#include <gst/net/net-prelude.h>
+
#include <gst/net/gstnet.h>
#include <gst/net/gstnetaddressmeta.h>
#include <gst/net/gstnetclientclock.h>