gobjectIntrospection: add giDiscoverSelf preFixupPhase hook

Some derivations need to discover their own typelibs. giDiscoverSelf
runs as a preFixupPhase and populates GI_TYPELIB_PATH with an entry
pointing to $prefix/lib/girepository-1.0, if it exists.
This commit is contained in:
Yegor Timoshenko 2017-12-18 02:30:53 +00:00
parent 61bb8115c5
commit 0dff26daa4
No known key found for this signature in database
GPG Key ID: C34BF9DCC9DF8210

View File

@ -1,5 +1,4 @@
make_gobject_introspection_find_gir_files() {
# required for .typelib files, eg mypaint git version
if [ -d "$1/lib/girepository-1.0" ]; then
addToSearchPath GI_TYPELIB_PATH $1/lib/girepository-1.0
@ -13,9 +12,16 @@ make_gobject_introspection_find_gir_files() {
envHooks+=(make_gobject_introspection_find_gir_files)
giDiscoverSelf() {
if [ -d "$prefix/lib/girepository-1.0" ]; then
addToSearchPath GI_TYPELIB_PATH $prefix/lib/girepository-1.0
fi
}
preFixupHooks+=(giDiscoverSelf)
_multioutMoveGlibGir() {
moveToOutput share/gir-1.0 "${!outputDev}"
}
preFixupHooks+=(_multioutMoveGlibGir)