3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request #212592 from wegank/cmus-clang

cmus: remove clangGCC hack
This commit is contained in:
Jörg Thalheim 2023-01-25 14:49:53 +00:00 committed by GitHub
commit 715f7e1ea0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -88,14 +88,6 @@ let
#(mkFlag vtxSupport "CONFIG_VTX=y" libayemu)
];
clangGCC = runCommand "clang-gcc" {} ''
#! ${stdenv.shell}
mkdir -p $out/bin
ln -s ${stdenv.cc}/bin/clang $out/bin/gcc
ln -s ${stdenv.cc}/bin/clang++ $out/bin/g++
'';
in
stdenv.mkDerivation rec {
@ -111,17 +103,18 @@ stdenv.mkDerivation rec {
patches = [ ./option-debugging.patch ];
configurePhase = "./configure " + lib.concatStringsSep " " ([
"prefix=$out"
"CONFIG_WAV=y"
] ++ lib.concatMap (a: a.flags) opts);
nativeBuildInputs = [ pkg-config ];
buildInputs = [ ncurses ]
++ lib.optional stdenv.cc.isClang clangGCC
++ lib.optionals stdenv.isDarwin [ libiconv CoreAudio AudioUnit VideoToolbox ]
++ lib.flatten (lib.concatMap (a: a.deps) opts);
prefixKey = "prefix=";
configureFlags = [
"CONFIG_WAV=y"
"HOSTCC=${stdenv.cc.targetPrefix}cc"
] ++ lib.concatMap (a: a.flags) opts;
makeFlags = [ "LD=$(CC)" ];
meta = with lib; {