tinycc: generate a pkgconfig file for libtcc

This commit is contained in:
Joachim Fasting 2019-05-05 10:27:39 +02:00
parent 8b1000432b
commit f73f525b72
No known key found for this signature in database
GPG Key ID: 5C204DF675C90294

View File

@ -32,6 +32,17 @@ stdenv.mkDerivation rec {
configureFlagsArray+=("--libpaths=${getLib stdenv.cc.libc}/lib")
'';
postFixup = ''
cat >libtcc.pc <<EOF
Name: libtcc
Description: Tiny C compiler backend
Version: ${version}
Libs: -L$out/lib -Wl,--rpath $out/lib -ltcc -ldl
Cflags: -I$out/include
EOF
install -Dt $out/lib/pkgconfig libtcc.pc
'';
doCheck = true;
checkTarget = "test";