Unverified Commit 13a1b39d authored by aszlig's avatar aszlig
Browse files

netrw: Fix including {stdlib,stdio,string}.h



With GCC 14 it is no longer possible to call a function that has not
been declared and thus we get build errors like these:

  netread.c:69:5: error: implicit declaration of function 'fprintf'
  netread.c:89:5: error: implicit declaration of function 'exit'
  ../version.h:37:9: error: implicit declaration of function 'puts'

Instead of ignoring this error, I looked around in the netrw code and
found that there is a STDC_HEADERS preprocessor variable that makes sure
that those includes are explicit.

The configure script confusingly calls the check "ANSI C header files",
so I made sure that the STDC_HEADERS variable really only adds
"#include" directives.

Signed-off-by: default avataraszlig <aszlig@nix.build>
parent d30faab9
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -15,6 +15,9 @@ stdenv.mkDerivation rec {
  version = "1.3.2";

  configureFlags = [
    # This is to add "#include" directives for stdlib.h, stdio.h and string.h.
    "ac_cv_header_stdc=yes"

    "--with-checksum=${checksumType}"
  ];