diff options
author | Thibault Saunier <tsaunier@igalia.com> | 2018-05-17 12:03:55 -0400 |
---|---|---|
committer | Thibault Saunier <tsaunier@igalia.com> | 2018-06-05 10:55:15 -0400 |
commit | 29f0c340ab9dfe93eef396da8b46b10aa0a89f0d (patch) | |
tree | d6a145310e8e99d1853378b0d038bb803391af53 | |
parent | 9439399cd50b3d6c056aa1857b02e305555d2e39 (diff) |
Use bindinator as a subproject
-rw-r--r-- | README.md | 7 | ||||
-rw-r--r-- | meson.build | 50 | ||||
-rw-r--r-- | subprojects/bindinator.wrap | 4 |
3 files changed, 34 insertions, 27 deletions
@@ -34,13 +34,12 @@ is triggered right after. Updating to new GStreamer version -------------------------------- -* Make sure [bindinator] is installed on the system - -Make sure you are in an environement where latest `.gir` files are available (either install -or through the `$GI_TYPELIB_PATH` env var). +Make sure you are in an environement where latest `.gir` files are available (either installed +or through the `$GI_TYPELIB_PATH` env var), those files are automatically copied to `girs/`. ninja -C update-all +* Verify newly copied gir files in `girs/` and `git add` them * Verify newly generated code and `git add` files in `sources/generated/` and `ges/generated` * Commit diff --git a/meson.build b/meson.build index ea9314e..0b92311 100644 --- a/meson.build +++ b/meson.build @@ -157,26 +157,30 @@ custom_target('GstSharp-nuget', ) subdir('samples') - -bindinate = find_program('bindinate', required: false) -if bindinate.found() - run_target('bindinate_gstreamer', - command: [bindinate, - '--name=gstreamer', '--regenerate=true', - '--merge-with=GstApp-1.0,GstAudio-1.0,GstBase-1.0,GstController-1.0,GstNet-1.0,GstPbutils-1.0,GstRtp-1.0,GstRtsp-1.0,GstSdp-1.0,GstTag-1.0,GstVideo-1.0', - '--gir=Gst-1.0', - '--copy-girs=@0@'.format(join_paths(meson.current_source_dir(), 'girs'))], - depends: [] -) -run_target('bindinate_ges', - command: ['sh', '-c', - '''bindinate --name=gst-editing-services --regenerate=true --gir=GES-1.0 && mv @0@/sources/gst-editing-services-sharp-api.raw @0@/ges/gst-editing-services-api.raw '''.format( - meson.current_source_dir()) - ] - ) - python3 = import('python3').find_python() - run_target('update-code', command: [find_program('update_sources.py')]) - run_target('update-all', command: [find_program('update_sources.py'), 'bindinate']) -endif - -subdir('Tests')
\ No newline at end of file +subdir('Tests') + +bindinator = subproject('bindinator', default_options: ['gapi_fixup=@0@'.format(gapi_fixup)]) +if bindinator.get_variable('found') + bindinate = bindinator.get_variable('bindinate') + run_target('bindinate_gstreamer', + command: [bindinate, + '--name=gstreamer', '--regenerate=true', + '--merge-with=GstApp-1.0,GstAudio-1.0,GstBase-1.0,GstController-1.0,GstNet-1.0,GstPbutils-1.0,GstRtp-1.0,GstRtsp-1.0,GstSdp-1.0,GstTag-1.0,GstVideo-1.0', + '--gir=Gst-1.0', + '--copy-girs=@0@'.format(join_paths(meson.current_source_dir(), 'girs'))], + depends: [] + ) + run_target('bindinate_ges', + command: ['sh', '-c', + '''@0@ --name=gst-editing-services --regenerate=true --gir=GES-1.0 && mv @1@/sources/gst-editing-services-sharp-api.raw @1@/ges/gst-editing-services-api.raw '''.format( + bindinate.path(), + meson.current_source_dir()), + ], + depends: [] + ) + python3 = import('python3').find_python() + run_target('update-code', command: [find_program('update_sources.py')]) + run_target('update-all', command: [find_program('update_sources.py'), 'bindinate']) +else + warning('Bindinator not usable as some required dependencies are not avalaible.') +endif
\ No newline at end of file diff --git a/subprojects/bindinator.wrap b/subprojects/bindinator.wrap new file mode 100644 index 0000000..c407526 --- /dev/null +++ b/subprojects/bindinator.wrap @@ -0,0 +1,4 @@ +[wrap-git] +directory=bindinator +url=https://github.com/GLibSharp/bindinator.git +revision=master |