X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=subprojects%2Fgst-plugins-base%2Fmeson.build;h=e1ad9e1f33d51708025e5eeb904740ff7cc206f0;hb=1f65d7cc5c30efa4f86bfbd9a592b46d63ec2268;hp=7f48c7d14f8a3a63776000352d7bb6340bc16d3f;hpb=a7b376011b3de28c333e9b738d7bd6fd585935c5;p=platform%2Fupstream%2Fgstreamer.git diff --git a/subprojects/gst-plugins-base/meson.build b/subprojects/gst-plugins-base/meson.build index 7f48c7d..e1ad9e1 100644 --- a/subprojects/gst-plugins-base/meson.build +++ b/subprojects/gst-plugins-base/meson.build @@ -1,6 +1,6 @@ project('gst-plugins-base', 'c', - version : '1.19.3.1', - meson_version : '>= 0.59', + version : '1.21.3.1', + meson_version : '>= 0.62', default_options : [ 'warning_level=1', 'buildtype=debugoptimized' ]) @@ -27,7 +27,7 @@ else have_objc = false endif -glib_req = '>= 2.56.0' +glib_req = '>= 2.62.0' orc_req = '>= 0.4.24' if gst_version_is_stable @@ -47,7 +47,7 @@ osxversion = curversion + 1 plugins_install_dir = join_paths(get_option('libdir'), 'gstreamer-1.0') static_build = get_option('default_library') == 'static' plugins = [] -libraries = [] +gst_libraries = [] cc = meson.get_compiler('c') @@ -62,12 +62,27 @@ if cc.get_id() == 'msvc' '/wd4244', # lossy type conversion (e.g. double -> int) '/wd4305', # truncating type conversion (e.g. double -> float) cc.get_supported_arguments(['/utf-8']), # set the input encoding to utf-8 - - # Enable some warnings on MSVC to match GCC/Clang behaviour - '/w14062', # enumerator 'identifier' in switch of enum 'enumeration' is not handled - '/w14101', # 'identifier' : unreferenced local variable - '/w14189', # 'identifier' : local variable is initialized but not referenced ] + + if gst_version_is_dev + # Enable some warnings on MSVC to match GCC/Clang behaviour + msvc_args += cc.get_supported_arguments([ + '/we4002', # too many actual parameters for macro 'identifier' + '/we4003', # not enough actual parameters for macro 'identifier' + '/we4013', # 'function' undefined; assuming extern returning int + '/we4020', # 'function' : too many actual parameters + '/we4027', # function declared without formal parameter list + '/we4029', # declared formal parameter list different from definition + '/we4033', # 'function' must return a value + '/we4045', # 'array' : array bounds overflow + '/we4047', # 'operator' : 'identifier1' differs in levels of indirection from 'identifier2' + '/we4053', # one void operand for '?:' + '/we4062', # enumerator 'identifier' in switch of enum 'enumeration' is not handled + '/we4098', # 'function' : void function returning a value + '/we4101', # 'identifier' : unreferenced local variable + '/we4189', # 'identifier' : local variable is initialized but not referenced + ]) + endif add_project_arguments(msvc_args, language: ['c', 'cpp']) # Disable SAFESEH with MSVC for plugins and libs that use external deps that # are built with MinGW @@ -80,7 +95,14 @@ if cc.has_link_argument('-Wl,-Bsymbolic-functions') add_project_link_arguments('-Wl,-Bsymbolic-functions', language : 'c') endif +# glib doesn't support unloading, which means that unloading and reloading +# any library that registers static types will fail +if cc.has_link_argument('-Wl,-z,nodelete') + add_project_link_arguments('-Wl,-z,nodelete', language: 'c') +endif + core_conf = configuration_data() +core_conf.set('ENABLE_NLS', 1) # Symbol visibility if cc.get_id() == 'msvc' @@ -235,7 +257,6 @@ warning_flags = [ warning_c_flags = [ '-Wmissing-prototypes', - '-Wdeclaration-after-statement', ] warning_cxx_flags = [ @@ -294,19 +315,13 @@ endif # X11 checks are for sys/ and tests/ x11_dep = dependency('x11', required : get_option('x11')) -# GLib checks are for the entire project -# Almost everything that uses glib also uses gobject -glib_deps = [dependency('glib-2.0', version : glib_req, fallback: ['glib', 'libglib_dep']), - dependency('gobject-2.0', fallback: ['glib', 'libgobject_dep'])] # GIO is used by the GIO plugin, and by the TCP, SDP, and RTSP plugins -gio_dep = dependency('gio-2.0', fallback: ['glib', 'libgio_dep']) +gio_dep = dependency('gio-2.0', version: glib_req) giounix_dep = dependency('', required: false) if host_system != 'windows' - giounix_dep = dependency('gio-unix-2.0', version : glib_req, - fallback: ['glib', 'libgiounix_dep']) + giounix_dep = dependency('gio-unix-2.0') endif -gmodule_dep = dependency('gmodule-no-export-2.0', - fallback: ['glib', 'libgmodule_dep']) +gmodule_dep = dependency('gmodule-no-export-2.0') # some of the examples can use gdk-pixbuf and GTK+3 gdk_pixbuf_dep = dependency('gdk-pixbuf-2.0', required : get_option('examples')) @@ -445,14 +460,14 @@ if get_option('default_library') == 'shared' plugins_pkgconfig_install_dir = disabler() endif -pkgconfig_variables = ['exec_prefix=${prefix}', - 'toolsdir=${exec_prefix}/bin', - 'pluginsdir=${libdir}/gstreamer-1.0', - 'datarootdir=${prefix}/share', - 'datadir=${datarootdir}', - 'girdir=${datadir}/gir-1.0', - 'typelibdir=${libdir}/girepository-1.0', - 'libexecdir=${prefix}/libexec'] +pkgconfig_variables = [ + 'exec_prefix=${prefix}', + 'toolsdir=${exec_prefix}/bin', + 'pluginsdir=${libdir}/gstreamer-1.0', + 'girdir=${datadir}/gir-1.0', + 'typelibdir=${libdir}/girepository-1.0', + 'pluginscannerdir=${libexecdir}/gstreamer-1.0' +] pkgconfig_subdirs = ['gstreamer-1.0'] meson_pkg_config_file_fixup_script = find_program('scripts/meson-pkg-config-file-fixup.py') @@ -462,14 +477,11 @@ subdir('gst-libs') subdir('gst') subdir('ext') subdir('sys') -if not get_option('tools').disabled() - subdir('tools') -endif +subdir('tools') subdir('tests') # xgettext is optional (on Windows for instance) if find_program('xgettext', required : get_option('nls')).found() - core_conf.set('ENABLE_NLS', 1) subdir('po') endif subdir('docs') @@ -477,6 +489,7 @@ subdir('scripts') base_libraries = ['allocators', 'app', 'audio', 'fft', 'pbutils', 'riff', 'rtp', 'rtsp', 'sdp', 'tag', 'video'] if build_gstgl + core_conf.set('HAVE_GL', 1) base_libraries += 'gl' endif @@ -524,15 +537,10 @@ endif # Set release date if gst_version_nano == 0 extract_release_date = find_program('scripts/extract-release-date-from-doap-file.py') - run_result = run_command(extract_release_date, gst_version, files('gst-plugins-base.doap')) - if run_result.returncode() == 0 - release_date = run_result.stdout().strip() - core_conf.set_quoted('GST_PACKAGE_RELEASE_DATETIME', release_date) - message('Package release date: ' + release_date) - else - # Error out if our release can't be found in the .doap file - error(run_result.stderr()) - endif + run_result = run_command(extract_release_date, gst_version, files('gst-plugins-base.doap'), check: true) + release_date = run_result.stdout().strip() + core_conf.set_quoted('GST_PACKAGE_RELEASE_DATETIME', release_date) + message('Package release date: ' + release_date) endif if gio_dep.version().version_compare('< 2.67.4') @@ -542,8 +550,15 @@ endif # Use core_conf after all subdirs have set values configure_file(output : 'config.h', configuration : core_conf) +meson.add_dist_script('scripts/gen-changelog.py', meson.project_name(), '1.20.0', meson.project_version()) + plugin_names = [] +gst_plugins = [] foreach plugin: plugins + pkgconfig.generate(plugin, install_dir: plugins_pkgconfig_install_dir) + dep = declare_dependency(link_with: plugin, variables: {'full_path': plugin.full_path()}) + meson.override_dependency(plugin.name(), dep) + gst_plugins += [dep] if plugin.name().startswith('gst') plugin_names += [plugin.name().substring(3)] else