meson: build oss plugin

https://bugzilla.gnome.org/show_bug.cgi?id=784134
This commit is contained in:
Tim-Philipp Müller 2017-06-23 19:23:52 +01:00
parent c438545dc9
commit 1fa24b0be3
2 changed files with 30 additions and 2 deletions

View file

@ -1,9 +1,9 @@
subdir('directsound')
subdir('oss')
subdir('v4l2') subdir('v4l2')
subdir('ximage') subdir('ximage')
subdir('directsound')
# FIXME: Implement these # FIXME: Implement these
#subdir('oss')
#subdir('oss4') #subdir('oss4')
#subdir('osxaudio') #subdir('osxaudio')
#subdir('osxvideo') #subdir('osxvideo')

28
sys/oss/meson.build Normal file
View file

@ -0,0 +1,28 @@
oss_header_locations = [
# Linux and newer BSD versions
['sys/soundcard.h', 'HAVE_OSS_INCLUDE_IN_SYS', 'OSS includes are in sys/'],
# Some old BSD versions and also newer OpenBSD versions
['soundcard.h', 'HAVE_OSS_INCLUDE_IN_ROOT', 'OSS includes are in root'],
# Some old BSD versions
['machine/soundcard.h', 'HAVE_OSS_INCLUDE_IN_MACHINE', 'OSS includes are in machine/'],
]
have_oss = false
foreach hdr : oss_header_locations
if not have_oss
if cc.has_header(hdr[0])
cdata.set(hdr[1], 1, description: hdr[2])
have_oss = true
endif
endif
endforeach
if have_oss
library('gstossaudio',
'gstossaudio.c', 'gstosshelper.c', 'gstosssink.c', 'gstosssrc.c',
c_args : gst_plugins_good_args,
include_directories : [configinc, libsinc],
dependencies : [gstaudio_dep, gstbase_dep],
install : true,
install_dir : plugins_install_dir)
endif