@@ -1,9 +1,6 @@
11{ stdenv, fetchurl, callPackage, libpng12, imagemagick,
22 autoreconfHook, glib, pstoedit, pkgconfig, gettext, darwin }:
33
4−# TODO: Solve that it cannot find pstoedit (as it is unable to find
5−# pstoedit-config)
6−
74# TODO: Figure out why the resultant binary is somehow linked against
85# libpng16.so.16 rather than libpng12.
96
@@ -49,7 +46,19 @@ stdenv.mkDerivation rec {
4946
5047 # This complains about various m4 files, but it appears to not be an
5148 # actual error.
52− preConfigure = "glib-gettextize --copy --force";
49+ preConfigure = ''
50+ glib-gettextize --copy --force
51+ # pstoedit-config no longer exists, it was replaced with pkg-config
52+ mkdir wrappers
53+ cat >wrappers/pstoedit-config <<'EOF'
54+ #!${stdenv.shell}
55+ # replace --version with --modversion for pkg-config
56+ args=''${@/--version/--modversion}
57+ exec pkg-config pstoedit "''${args[@]}"
58+ EOF
59+ chmod +x wrappers/pstoedit-config
60+ export PATH="$PATH:$PWD/wrappers"
61+ '';
5362
5463 meta = with stdenv.lib; {
5564 homepage = http://autotrace.sourceforge.net/;