diff --git a/srcpkgs/libmirage/patches/girpath.patch b/srcpkgs/libmirage/patches/girpath.patch new file mode 100644 index 00000000000..70e9a73dc5d --- /dev/null +++ b/srcpkgs/libmirage/patches/girpath.patch @@ -0,0 +1,24 @@ +The girdir in the .pc file is defined like this: + +${pc_sysrootdir}/${datadir}/gir-1.0 + +If you replace pc_sysrootdir with a /, and datadir with /usr/share, you end +up with ///usr/share/gir-1.0, which cmake treats as a network path, and +breaks when used with destdir + +So replace a useless substitute (we don't use a non-standard prefix) with +a useful one + +--- cmake/GObjectIntrospection.cmake 2019-02-11 02:04:33.574070141 +0100 ++++ cmake/GObjectIntrospection.cmake 2019-02-11 02:05:26.556485411 +0100 +@@ -44,8 +44,8 @@ + _pkg_config_variable(girdir GIR_GIRDIR) + _pkg_config_variable(typelibdir GIR_TYPELIBDIR) + +-string (REPLACE "/usr" "${CMAKE_INSTALL_PREFIX}" GIR_GIRDIR "${GIR_GIRDIR}") +-string (REPLACE "/usr" "${CMAKE_INSTALL_PREFIX}" GIR_TYPELIBDIR "${GIR_TYPELIBDIR}") ++string (REPLACE "///" "/" GIR_GIRDIR "${GIR_GIRDIR}") ++string (REPLACE "///" "/" GIR_TYPELIBDIR "${GIR_TYPELIBDIR}") + + ############################################################################### + # The main function