From c459ca8338d09d9f52dfc8f4117deafb937b64fe Mon Sep 17 00:00:00 2001 From: Marijn Suijten Date: Wed, 25 Nov 2020 20:07:30 +0100 Subject: [PATCH] gir-files/fix: Autoamtically delete duplicate ONEFIELDs in GstVideo.gir --- DEVELOPMENT.md | 3 --- gir-files/fix.sh | 6 ++++++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/DEVELOPMENT.md b/DEVELOPMENT.md index ba19cc309..6c1ba3e12 100644 --- a/DEVELOPMENT.md +++ b/DEVELOPMENT.md @@ -3,9 +3,6 @@ * Take the updated .gir files (e.g. from your gst-build checkout) and put them in the gir-files directory * In the gir-files directory, run ./fix.sh - * In the GstVideo-1.0.gir file, the `GST_VIDEO_BUFFER_FLAG_ONEFIELD` and - `GST_VIDEO_FRAME_FLAG_ONEFIELD` flags are twice. This is a gir bug. Delete - the second one. * If there is a new GStreamer version: Manually update `gst*/Cargo.toml` * Run generator.py * Investigate the diff, fix any mess-ups, look at commented functions and diff --git a/gir-files/fix.sh b/gir-files/fix.sh index 4fec1b47e..4fde9f003 100755 --- a/gir-files/fix.sh +++ b/gir-files/fix.sh @@ -77,6 +77,12 @@ xmlstarlet ed --pf --inplace \ --insert '//_:record[@name="VideoAncillary"]/_:field[@name="data"]/_:array' \ --type attr --name 'fixed-size' --value '256' \ GstVideo-1.0.gir + +xmlstarlet ed --pf --inplace \ + --delete "//_:member[@c:identifier=\"GST_VIDEO_BUFFER_FLAG_ONEFIELD\"][2]" \ + --delete "//_:member[@c:identifier=\"GST_VIDEO_FRAME_FLAG_ONEFIELD\"][2]" \ + GstVideo-1.0.gir + xmlstarlet ed --pf --inplace \ --delete '//_:record[@name="ISO639LanguageDescriptor"]/_:field[@name="language"]/_:array/@c:type' \ --insert '//_:record[@name="ISO639LanguageDescriptor"]/_:field[@name="language"]/_:array' \