From d365bde5554fee1fc9e63a870f4b89d3d5e1f6ef Mon Sep 17 00:00:00 2001 From: Ross Burton Date: Tue, 26 Jun 2018 10:30:31 +0100 Subject: scripts/gtkdochelper: add support for --run gtkdoc-scangobj has a --run argument that specifies a wrapper to be used when executing the GObject scanner. Typically this can be libtool but it is also useful in cross-compilation environments. This patch adds support for this argument to the gtkdochelper so that tools using the helper can pass --run if required. --- mesonbuild/scripts/gtkdochelper.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'mesonbuild/scripts') diff --git a/mesonbuild/scripts/gtkdochelper.py b/mesonbuild/scripts/gtkdochelper.py index 4c5cbdf..371d95d 100644 --- a/mesonbuild/scripts/gtkdochelper.py +++ b/mesonbuild/scripts/gtkdochelper.py @@ -45,6 +45,7 @@ parser.add_argument('--ignore-headers', dest='ignore_headers', default='') parser.add_argument('--namespace', dest='namespace', default='') parser.add_argument('--mode', dest='mode', default='') parser.add_argument('--installdir', dest='install_dir') +parser.add_argument('--run', dest='run', default='') def gtkdoc_run_check(cmd, cwd, library_path=None): env = dict(os.environ) @@ -64,7 +65,7 @@ def gtkdoc_run_check(cmd, cwd, library_path=None): def build_gtkdoc(source_root, build_root, doc_subdir, src_subdirs, main_file, module, html_args, scan_args, fixxref_args, mkdb_args, - gobject_typesfile, scanobjs_args, ld, cc, ldflags, cflags, + gobject_typesfile, scanobjs_args, run, ld, cc, ldflags, cflags, html_assets, content_files, ignore_headers, namespace, expand_content_files, mode): print("Building documentation for %s" % module) @@ -125,6 +126,7 @@ def build_gtkdoc(source_root, build_root, doc_subdir, src_subdirs, if gobject_typesfile: scanobjs_cmd = ['gtkdoc-scangobj'] + scanobjs_args + ['--types=' + gobject_typesfile, '--module=' + module, + '--run=' + run, '--cflags=' + cflags, '--ldflags=' + ldflags, '--cc=' + cc, @@ -231,6 +233,7 @@ def run(args): mkdbargs, options.gobject_typesfile, scanobjsargs, + options.run, options.ld, options.cc, options.ldflags, -- cgit v1.1