diff --git a/pkgs/servers/ftp/vsftpd/default.nix b/pkgs/servers/ftp/vsftpd/default.nix index 1a5bd4370d72..b87d11809b11 100644 --- a/pkgs/servers/ftp/vsftpd/default.nix +++ b/pkgs/servers/ftp/vsftpd/default.nix @@ -24,7 +24,11 @@ stdenv.mkDerivation rec { ''; NIX_LDFLAGS = "-lcrypt -lssl -lcrypto -lpam -lcap"; - NIX_CFLAGS_COMPILE = "-Wno-error=enum-conversion"; + + # On gcc9, this would produce + # error: '-Werror=enum-conversion': no option -Wenum-conversion + NIX_CFLAGS_COMPILE = lib.optionalString (lib.versionAtLeast stdenv.cc.version "10") + "-Wno-error=enum-conversion"; enableParallelBuilding = true;