From d7ac3b473afff8000338f1038e78a22556a5c4a3 Mon Sep 17 00:00:00 2001 From: Yureka Date: Sat, 7 Aug 2021 13:26:45 +0200 Subject: [PATCH] emscriptenPackages.json_c: fix build Co-authored-by: Alexander Khovansky --- pkgs/top-level/emscripten-packages.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pkgs/top-level/emscripten-packages.nix b/pkgs/top-level/emscripten-packages.nix index 0d2197faae09..7cf60df98dbf 100644 --- a/pkgs/top-level/emscripten-packages.nix +++ b/pkgs/top-level/emscripten-packages.nix @@ -10,12 +10,11 @@ rec { stdenv = pkgs.emscriptenStdenv; }).overrideDerivation (old: { - nativeBuildInputs = [ autoreconfHook pkg-config ]; + nativeBuildInputs = [ pkg-config cmake ]; propagatedBuildInputs = [ zlib ]; - buildInputs = old.buildInputs ++ [ automake autoconf ]; configurePhase = '' HOME=$TMPDIR - emconfigure ./configure --prefix=$out + emcmake cmake . $cmakeFlags -DCMAKE_INSTALL_PREFIX=$out -DCMAKE_INSTALL_INCLUDEDIR=$dev/include ''; checkPhase = '' echo "================= testing json_c using node =================" @@ -26,7 +25,7 @@ rec { `pkg-config zlib --cflags` \ `pkg-config zlib --libs` \ -I . \ - .libs/libjson-c.so \ + libjson-c.a \ -o ./test1.js echo "Using node to execute the test which basically outputs an error on stderr which we grep for"