This is from the libreoffice-bin x86 build chroot (which is completely rebuilt from a minimal world file on each emerge). /usr/bin/g-ir-scanner --warn-all --add-include-path=. --add-include-path=. --namespace=Secret --nsversion=1 --libtool="/bin/sh ./libtool" --include=GObject-2.0 --include=Gio-2.0 --pkg-export=libsecret-1 --library=libsecret-1.la --c-include "libsecret/secret.h" --cflags-begin -I. -I. -DSECRET_COMPILATION --cflags-end libsecret/secret-attributes.h libsecr et/secret-attributes.c libsecret/secret-collection.h libsecret/secret-collection.c libsecret/secret-item.h libsecret/secret-item.c libsecret/secret-methods.c libsecret/secret-passw ord.h libsecret/secret-password.c libsecret/secret-prompt.h libsecret/secret-prompt.c libsecret/secret-schema.h libsecret/secret-schema.c libsecret/secret-schemas.h libsecret/secre t-schemas.c libsecret/secret-service.h libsecret/secret-service.c libsecret/secret-types.h libsecret/secret-value.h libsecret/secret-value.c libsecret/secret-paths.h libsecret/secr et-paths.c libsecret-1.la --output Secret-1.gir /bin/sh ./libtool --tag=CC --mode=link i686-pc-linux-gnu-gcc -march=i586 -mtune=generic -O2 -pipe -g -pthread -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/gl ib-2.0/include -DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_38 -DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_2_38 -Wall -Wmissing-declarations -Wmissing-prototypes -Wn ested-externs -Wpointer-arith -Wdeclaration-after-statement -Wformat=2 -Winit-self -Waggregate-return -Wmissing-include-dirs -Wundef -Wno-error -g -Wl,-O1 -Wl ,--as-needed -o secret-tool tool/secret-tool.o libsecret-1.la -lgio-2.0 -lgobject-2.0 -lglib-2.0 libtool: link: i686-pc-linux-gnu-gcc -march=i586 -mtune=generic -O2 -pipe -g -pthread -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -DGLIB_VERSIO N_MIN_REQUIRED=GLIB_VERSION_2_38 -DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_2_38 -Wall -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wdeclaration-after -statement -Wformat=2 -Winit-self -Waggregate-return -Wmissing-include-dirs -Wundef -Wno-error -g -Wl,-O1 -o .libs/secret-tool tool/secret-tool.o -Wl,--as-needed ./.libs/libsecret -1.so -lgcrypt -lgpg-error -lgio-2.0 -lgobject-2.0 -lglib-2.0 -pthread Traceback (most recent call last): File "/usr/bin/g-ir-scanner", line 55, in <module> sys.exit(scanner_main(sys.argv)) File "/usr/lib/gobject-introspection/giscanner/scannermain.py", line 508, in scanner_main transformer = create_transformer(namespace, options) File "/usr/lib/gobject-introspection/giscanner/scannermain.py", line 370, in create_transformer identifier_filter_cmd=options.identifier_filter_cmd) File "/usr/lib/gobject-introspection/giscanner/transformer.py", line 54, in __init__ self._cachestore = CacheStore() File "/usr/lib/gobject-introspection/giscanner/cachestore.py", line 83, in __init__ self._check_cache_version() File "/usr/lib/gobject-introspection/giscanner/cachestore.py", line 119, in _check_cache_version shutil.move(versiontmp, version) File "/usr/lib/python2.7/shutil.py", line 302, in move copy2(src, real_dst) File "/usr/lib/python2.7/shutil.py", line 130, in copy2 copyfile(src, dst) File "/usr/lib/python2.7/shutil.py", line 82, in copyfile with open(src, 'rb') as fsrc: IOError: [Errno 2] No such file or directory: '/var/tmp/portage/app-crypt/libsecret-0.18.2/homedir/.cache/g-ir-scanner/.cache-version.tmp' /usr/share/gobject-introspection-1.0/Makefile.introspection:153: recipe for target 'Secret-1.gir' failed make[2]: *** [Secret-1.gir] Error 1
Created attachment 407008 [details] build log
Created attachment 407012 [details] emerge --info
This is probably a parallel make problem; on a second run the build passed.
Had the same problem. If you set USE="-introspection", the build succeeded, too. I am not sure, however, if it would have succeeded anyway on the second attempt as indicated in comment #3.
With xdg.eclass inherited by gnome2.eclass, this should now be properly created in src_prepare. Please re-open if it still fails for you.