fontforge-fonttools: use $CC

This commit is contained in:
Daiderd Jordan 2017-09-09 23:59:04 +02:00
parent c0e7983359
commit 2317a07fbb
No known key found for this signature in database
GPG Key ID: D02435D05B810C96

View File

@ -1,4 +1,4 @@
{stdenv, fetchFromGitHub, zlib}:
{ stdenv, fetchFromGitHub, zlib }:
stdenv.mkDerivation rec {
version = "20160404";
@ -11,14 +11,14 @@ stdenv.mkDerivation rec {
sha256 = "15nacq84n9gvlzp3slpmfrrbh57kfb6lbdlc46i7aqgci4qv6fg0";
};
buildInputs = [zlib];
buildInputs = [ zlib ];
setSourceRoot = ''export sourceRoot="$(echo */contrib/fonttools)"'';
installPhase = ''
mkdir -p "$out"/{bin,share/doc/fontforge-fonttools}
for i in *.c; do
gcc "$i" -lz -lm --std=c99 -o "$out"/bin/$(basename "$i" .c)
$CC "$i" -lz -lm --std=c99 -o "$out"/bin/$(basename "$i" .c)
done
cp README* "$out/share/doc/fontforge-fonttools"
'';