GObjectIntrospection: Makefile.introspection missing dependencies definition for libraries and programs?


On Gentoo, some people are seeing distcc-related failures when
building >Polkit-0.105 when gir is doing its thing

GISCAN Polkit-1.0.gir
libtool: link: cannot find the library `libpolkit-gobject-1.la' or
unhandled argument `libpolkit-gobject-1.la'
linking of temporary binary failed: Command '['/bin/sh',
'../../libtool', '--mode=link', '--tag=CC', '--silent', 'gcc', '-o',
'-export-dynamic', '-O2', '-march=corei7-avx', '-pipe',
'-frecord-gcc-switches', '-mno-movbe', '-mno-abm', '-mno-lwp',
'-mno-fma', '-mno-fma4', '-mno-xop', '-mno-bmi', '-mno-tbm',
'--param', 'l1-cache-size=32', '--param', 'l1-cache-line-size=64',
'--param', 'l2-cache-size=8192', '-mtune=corei7-avx',
'-fgcse-after-reload', '-fpredictive-commoning', '-ftree-vectorize',
'-funswitch-loops', '-fgraphite-identity', '-floop-block',
'-floop-interchange', '-floop-strip-mine', '-ggdb', '-gdwarf-4',
'-fvar-tracking-assignments', '-Wall', '-Wchar-subscripts',
'-Wmissing-declarations', '-Wnested-externs', '-Wpointer-arith',
'-Wcast-align', '-Wsign-compare', '-Wformat', '-Wformat-security',
'-L.', 'libpolkit-gobject-1.la', '-pthread', '-Wl,--export-dynamic',
'-lgio-2.0', '-lgobject-2.0', '-lgthread-2.0', '-lgmodule-2.0',
'-lrt', '-lglib-2.0']' returned non-zero exit status 1
make[4]: *** [Polkit-1.0.gir] Error 1

It seems to occur with a sufficiently high -j number, with or without
distcc; I've managed to reproduce it on a single host by using `make

My automake is rusty, but it seems to me Makefile.introspection does
not take the value of *_gir_PROGRAMS or *_gir_LIBS into the dependency
list, which appears to the root of the problem. I can see no other way
to inject the proper file dependencies using the automake interface

Can anyone confirm this, or is it a case of misuse?

Relevant section of Makefile.introspection pasted for convenience, below:

# Only dependencies we know are actually filenames goes into _FILES, make
# sure these are built before running the scanner. Libraries and programs
# needs to be added manually.
$(1): $$($(_gir_name)_FILES)
        @ $(MKDIR_P) $(dir $(1))
        $(_gir_silent_scanner_prefix) $(INTROSPECTION_SCANNER_ENV)
$(INTROSPECTION_SCANNER) $(_gir_silent_scanner_opts) \
          --namespace=$(_gir_namespace) \
          --nsversion=$(_gir_version) \
          $(_gir_libtool) \
          $(_gir_packages) \
          $(_gir_includes) \
          $(_gir_export_packages) \
          $(_gir_program) \
          $(_gir_libraries) \
          $($(_gir_name)_SCANNERFLAGS) \
          $($(_gir_name)_CFLAGS) \
          $($(_gir_name)_LDFLAGS) \
          $$^ \
          --output $(1)

Yang Zhao

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]