nixpkgs/pkgs/development/libraries/ucl/default.nix
Rahul Butani aef1a40ddb
ucl: fix on Darwin/with pkgsLLVM
Modern clang versions error with `-Wimplicit-function-declaration`
[by default]; this causes `ucl`'s `configure` scripts check for ANSI C
headers (`stddef.h`) to fail because its test assumes `exit` is
implicitly declared leading to build failures:
```console
checking for ANSI C header files... no
```

[by default]: https://reviews.llvm.org/D122983
2024-05-10 02:26:11 -07:00

23 lines
676 B
Nix

{ lib, stdenv, fetchurl }:
stdenv.mkDerivation rec {
pname = "ucl";
version = "1.03";
src = fetchurl {
url = "https://www.oberhumer.com/opensource/ucl/download/ucl-${version}.tar.gz";
sha256 = "b865299ffd45d73412293369c9754b07637680e5c826915f097577cd27350348";
};
# needed to successfully compile with gcc 6+ and modern clang versions where
# `-Wimplicit-function-declaration` is otherwise on and errors by default
env.CFLAGS = "-std=c89";
meta = {
homepage = "http://www.oberhumer.com/opensource/ucl/";
description = "Portable lossless data compression library";
license = lib.licenses.gpl2;
platforms = lib.platforms.unix;
};
}