Unverified Commit 6cb55fa5 authored by FlameFlag's avatar FlameFlag
Browse files

libtar: fix Darwin build by setting -std=gnu17

The autoconf update on staging-next forces Clang into C23 mode, which
rejects K&R-style function declarations in compat/basename.c

Pin to gnu17 to restore the previous default

Refs: https://github.com/NixOS/nixpkgs/issues/511329
parent f9981bba
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -49,6 +49,8 @@ stdenv.mkDerivation (finalAttrs: {

  nativeBuildInputs = [ autoreconfHook ];

  configureFlags = [ "CFLAGS=-std=gnu17" ];

  # libtar/Makefile.in hardcodes `INSTALL_PROGRAM = @INSTALL_PROGRAM@ -s`,
  # which runs bare `strip` during `make install`. This fails in cross builds
  # where only the prefixed strip (e.g. aarch64-unknown-linux-gnu-strip) is