summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.com>2017-01-05 20:34:14 +0000
committerTim-Philipp Müller <tim@centricular.com>2017-01-06 10:51:20 +0000
commita0a01af3e95cbad05a770f970c66afc60843a6f8 (patch)
treeeedd2173e612d824ce36f922ffaf78794e468359
parent94f678aa5a23fdfb9dc7870f49dce0f0566b52b6 (diff)
downloadgstreamer-plugins-bad-a0a01af3e95cbad05a770f970c66afc60843a6f8.tar.gz
meson: build decklink plugin
-rw-r--r--sys/decklink/meson.build43
-rw-r--r--sys/meson.build2
2 files changed, 44 insertions, 1 deletions
diff --git a/sys/decklink/meson.build b/sys/decklink/meson.build
new file mode 100644
index 000000000..2b795c4c6
--- /dev/null
+++ b/sys/decklink/meson.build
@@ -0,0 +1,43 @@
+decklink_sources = [
+ 'gstdecklink.cpp',
+ 'gstdecklinkaudiosink.cpp',
+ 'gstdecklinkvideosink.cpp',
+ 'gstdecklinkaudiosrc.cpp',
+ 'gstdecklinkvideosrc.cpp',
+]
+
+build_decklink = false
+decklink_ldflags = []
+decklink_cppargs = []
+libdl = cc.find_library('dl', required: false)
+have_pthread_h = cdata.has('HAVE_PTHREAD_H')
+
+if libdl.found() and have_pthread_h
+ if host_machine.system() == 'linux'
+ decklink_sources += ['linux/DeckLinkAPIDispatch.cpp']
+ build_decklink = true
+ elif host_machine.system() == 'darwin'
+ decklink_sources += ['osx/DeckLinkAPIDispatch.cpp']
+ decklink_ldflags = '-Wl,-framework,CoreFoundation'
+ build_decklink = true
+ else
+ message('Not building decklink plugin for system ' + host_machine.system())
+ endif
+endif
+
+cxx = meson.get_compiler('cpp')
+if cxx.has_argument('-Wno-non-virtual-dtor')
+ decklink_cppargs += ['-Wno-non-virtual-dtor']
+endif
+
+if build_decklink
+ decklink = library('gstdecklink',
+ decklink_sources,
+ cpp_args : gst_plugins_bad_args + decklink_cppargs,
+ link_args : decklink_ldflags + noseh_link_args,
+ include_directories : [configinc],
+ dependencies : [gstvideo_dep, gstaudio_dep, gstbase_dep, gst_dep, libm, libdl, dependency('threads')],
+ install : true,
+ install_dir : plugins_install_dir,
+ )
+endif
diff --git a/sys/meson.build b/sys/meson.build
index 403fd2b0b..47043997f 100644
--- a/sys/meson.build
+++ b/sys/meson.build
@@ -7,7 +7,7 @@
subdir('bluez')
#subdir('cdrom')
subdir('d3dvideosink')
-#subdir('decklink')
+subdir('decklink')
subdir('directsound')
#subdir('dshowdecwrapper')
#subdir('dshowsrcwrapper')