1 { lib, stdenv, fetchurl, perl, freetype }:
3 stdenv.mkDerivation rec {
8 url = "mirror://sourceforge/ttf2pt1/ttf2pt1-${version}.tgz";
9 sha256 = "1l718n4k4widx49xz7qrj4mybzb8q67kp2jw7f47604ips4654mf";
13 find -type f | xargs sed -i 's@/usr/bin/perl@${perl}/bin/perl@'
15 sed -e 's/chown/true/' \
17 -e 's@^CFLAGS_FT =.*@CFLAGS_FT=-DUSE_FREETYPE -I${freetype.dev}/include/freetype2@' \
18 -i scripts/{inst_dir,inst_file} Makefile
19 makeFlags="INSTDIR=$out OWNER=`id -u`"
22 buildInputs = [ freetype ];
23 nativeBuildInputs = [ perl ];
25 patches = ./gentoo-makefile.patch; # also contains the freetype patch
28 description = "True Type to Postscript Type 3 converter, fpdf";
29 homepage = "https://ttf2pt1.sourceforge.net/index.html";
31 platforms = lib.platforms.linux;