# Don't need vs_module_defs for gstgl because we do symbol exporting in the
# function definitions via __declspec(dllexport/import)
)
- # TODO: generate gir
+ gen_sources = []
+ if build_gir
+ gl_gir = gnome.generate_gir(gstgl,
+ sources : gl_sources + gl_headers,
+ namespace : 'GstGL',
+ nsversion : api_version,
+ identifier_prefix : 'Gst',
+ symbol_prefix : 'gst',
+ export_packages : 'gstreamer-gl-1.0',
+ includes : ['Gst-1.0', 'GstBase-1.0', 'GstVideo-1.0'],
+ install : true,
+ extra_args : gir_init_section + ['-DGST_USE_UNSTABLE_API',
+ '--c-include=gst/gl/gl.h'],
+ dependencies : [gst_dep, gstbase_dep, gstvideo_dep]
+ )
+ gen_sources += gl_gir
+ endif
+
gstgl_dep = declare_dependency(link_with : gstgl,
include_directories : [libsinc],
+ sources: gen_sources,
dependencies : [gstbase_dep, gstvideo_dep] + gl_winsys_deps)
endif
dependencies : [gst_dep],
vs_module_defs: vs_module_defs_dir + 'libgstinsertbin.def',
)
-# TODO: generate gir
+
+gen_sources = []
+if build_gir
+ insertbin_gir = gnome.generate_gir(gstinsertbin,
+ sources : insert_sources + insert_headers,
+ namespace : 'GstInsertBin',
+ nsversion : api_version,
+ identifier_prefix : 'Gst',
+ symbol_prefix : 'gst',
+ export_packages : 'gstreamer-insertbin-1.0',
+ includes : ['Gst-1.0'],
+ install : true,
+ extra_args : gir_init_section + ['-DGST_USE_UNSTABLE_API'],
+ dependencies : [gst_dep]
+ )
+ gen_sources += insertbin_gir
+endif
gstinsertbin_dep = declare_dependency(link_with : gstinsertbin,
include_directories : [libsinc],
+ sources: gen_sources,
dependencies : [gst_dep])
install : true,
install_dir : 'include/gstreamer-1.0/gst/mpegts',
command : [mkenums, glib_mkenums, '@OUTPUT@', '@INPUT@'])
+gen_sources = [mpegts_h]
mpegts_c = custom_target('mpegtsenum_c',
output : 'gstmpegts-enumtypes.c',
dependencies : [gst_dep],
vs_module_defs: vs_module_defs_dir + 'libgstmpegts.def',
)
-# TODO: generate gir
+if build_gir
+ mpegts_gir = gnome.generate_gir(gstmpegts,
+ sources : mpegts_sources + mpegts_headers,
+ namespace : 'GstMpegts',
+ nsversion : api_version,
+ identifier_prefix : 'Gst',
+ symbol_prefix : 'gst',
+ export_packages : 'gstreamer-mpegts-1.0',
+ includes : ['Gst-1.0'],
+ install : true,
+ extra_args : gir_init_section + ['-DGST_USE_UNSTABLE_API'],
+ dependencies : [gst_dep]
+ )
+ gen_sources += mpegts_gir
+endif
+
gstmpegts_dep = declare_dependency(link_with : gstmpegts,
include_directories : [libsinc],
dependencies : [gst_dep],
- sources : [mpegts_h])
+ sources : gen_sources)
gsttag_dep, gstpbutils_dep],
vs_module_defs: vs_module_defs_dir + 'libgstplayer.def',
)
-# TODO: gir
+
+gen_sources = []
+if build_gir
+ player_gir = gnome.generate_gir(gstplayer,
+ sources : gstplayer_sources + gstplayer_headers,
+ namespace : 'GstPlayer',
+ nsversion : api_version,
+ identifier_prefix : 'Gst',
+ symbol_prefix : 'gst',
+ export_packages : 'gstreamer-player-1.0',
+ includes : ['Gst-1.0', 'GstPbutils-1.0', 'GstBase-1.0', 'GstVideo-1.0',
+ 'GstAudio-1.0', 'GstTag-1.0'],
+ install : true,
+ extra_args : gir_init_section + ['-DGST_USE_UNSTABLE_API'],
+ dependencies : [gstbase_dep, gstvideo_dep, gstaudio_dep,
+ gsttag_dep, gstpbutils_dep]
+ )
+ gen_sources += player_gir
+endif
gstplayer_dep = declare_dependency(link_with : gstplayer,
include_directories : [libsinc],
+ sources: gen_sources,
dependencies : [gstbase_dep, gstvideo_dep, gstaudio_dep,
gsttag_dep, gstpbutils_dep])
# Used by the *_mkenum.py helper scripts
glib_mkenums = find_program('glib-mkenums')
+gir = find_program('g-ir-scanner', required : false)
+gnome = import('gnome')
+build_gir = gir.found() and not meson.is_cross_build() and not get_option('disable_introspection')
+gir_init_section = [ '--add-init-section=extern void gst_init(gint*,gchar**);' + \
+ 'g_setenv("GST_REGISTRY_1.0", "@0@", TRUE);'.format(meson.current_build_dir() + '/gir_empty_registry.reg') + \
+ 'g_setenv("GST_PLUGIN_PATH_1_0", "", TRUE);' + \
+ 'g_setenv("GST_PLUGIN_SYSTEM_PATH_1_0", "", TRUE);' + \
+ 'gst_init(NULL,NULL);' ]
subdir('gst-libs')
subdir('gst')
subdir('sys')
option('with_egl_module_name', type : 'string', value : '', description : 'The file to pass to g_module_open to open the libEGL.so library (default: libEGL.so)')
option('with_opengl_module_name', type : 'string', value : '', description : 'The file to pass to g_module_open to open the libGL.so library (default: libGL.so)')
option('with_gles2_module_name', type : 'string', value : '', description : 'The file to pass to g_module_open to open the libGLESv2.so library (default: libGLESv2.so)')
+option('disable_introspection',
+ type : 'boolean', value : false,
+ description : 'Whether to disable the introspection generation')