libvterm: fix cross compilation

+15 -6
+15 -6
pkgs/development/libraries/libvterm/default.nix
··· 9 9 sha256 = "10gaqygmmwp0cwk3j8qflri5caf8vl3f7pwfl2svw5whv8wkn0k2"; 10 10 }; 11 11 12 - patchPhase = '' 13 - sed -i -e s@/usr@$out@ -e /ldconfig/d Makefile 12 + preInstall = '' 13 + mkdir -p $out/include $out/lib 14 14 ''; 15 15 16 - preInstall = '' 17 - mkdir -p $out/include 18 - mkdir -p $out/lib 16 + postPatch = '' 17 + substituteInPlace Makefile \ 18 + --replace "gcc" "${stdenv.cc.targetPrefix}cc" \ 19 + --replace "ldconfig" "" \ 20 + --replace "/usr" "$out" 21 + 22 + makeFlagsArray+=("PKG_CFG=`${stdenv.cc.targetPrefix}pkg-config --cflags glib-2.0`") 19 23 ''; 20 24 25 + # For headers 26 + propagatedBuildInputs = [ glib ]; 27 + 28 + strictDeps = true; 29 + 21 30 nativeBuildInputs = [ pkg-config ]; 22 - buildInputs = [ glib ncurses ]; 31 + buildInputs = [ ncurses ]; 23 32 24 33 meta = with lib; { 25 34 homepage = "http://libvterm.sourceforge.net/";