1 { lib, stdenv, fetchFromGitHub, libxcrypt }:
3 stdenv.mkDerivation rec {
7 src = fetchFromGitHub {
11 sha256 = "sha256-s375gtqBWx0GGXALXR+fN4bb3tmpvPNu/3bNz+75UWU=";
14 # The build is small, so there should be no problem
15 # running this locally. There is also a use case for
16 # older systems, where modern binaries might not be
18 preferLocalBuild = true;
20 buildInputs = [ libxcrypt ];
23 sed -i -e '/install/d' $src/Makefile
30 # Workaround build failure on -fno-common toolchains like upstream
31 # gcc-10. Otherwise build fails as:
32 # ld: ../readelf-mini/libreadelf-mini.a(dwarf.o):/build/source/readelf-mini/dwarf.c:64:
33 # multiple definition of `do_wide'; ../readelf-mini/libreadelf-mini.a(readelf-mini.o):/build/source/readelf-mini/readelf-mini.c:170: first defined here
34 env.NIX_CFLAGS_COMPILE = "-fcommon";
38 install -t $out/bin cde cde-exec
42 homepage = "https://github.com/usnistgov/corr-CDE";
43 description = "Packaging tool for building portable packages";
44 license = licenses.gpl3Plus;
45 maintainers = [ maintainers.rlupton20 ];
46 platforms = platforms.linux;
47 # error: architecture aarch64 is not supported by bundled strace
48 badPlatforms = [ "aarch64-linux" ];