diff --git a/common/hooks/post-install/00-fixup-gir-path.sh b/common/hooks/post-install/00-fixup-gir-path.sh new file mode 100644 index 00000000000..6fdb111fa0b --- /dev/null +++ b/common/hooks/post-install/00-fixup-gir-path.sh @@ -0,0 +1,11 @@ +# This hook removes the symlink necessary to fix the wrong install path of +# 'gir' files when cross building packages (see pre-install hook). It's a +# workaround and not a proper fix. Remove it once the root cause of the problem +# is fixed. + +# Has to be a low number so it runs before remove-empty-dirs + +hook() { + [ -z "$CROSS_BUILD" ] && return + rm -f "${PKGDESTDIR}/usr/${XBPS_CROSS_TRIPLET}/usr" +} diff --git a/common/hooks/pre-install/98-fixup-gir-path.sh b/common/hooks/pre-install/98-fixup-gir-path.sh index c81c8257294..64fd1405c4c 100644 --- a/common/hooks/pre-install/98-fixup-gir-path.sh +++ b/common/hooks/pre-install/98-fixup-gir-path.sh @@ -5,8 +5,6 @@ hook() { [ -z "$CROSS_BUILD" ] && return - if [ -d "${DESTDIR}/usr/${XBPS_CROSS_TRIPLET}/usr" ]; then - cp -a "${DESTDIR}"/usr/{${XBPS_CROSS_TRIPLET}/usr/*,} - rm -rf "${DESTDIR}"/usr/${XBPS_CROSS_TRIPLET}/usr - fi + vmkdir usr/${XBPS_CROSS_TRIPLET} + ln -sf ".." "${PKGDESTDIR}/usr/${XBPS_CROSS_TRIPLET}/usr" }