Merge pull request #24185 from LnL7/atomicparsley-clang

atomicparsley: fix build with llvm 4
This commit is contained in:
Daniel Peebles 2017-03-21 20:24:59 -04:00 committed by GitHub
commit 16a0c38324

View File

@ -1,4 +1,4 @@
{ stdenv, pkgs, fetchurl }: { stdenv, fetchurl, unzip, darwin }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "atomicparsley-${version}"; name = "atomicparsley-${version}";
@ -10,10 +10,13 @@ stdenv.mkDerivation rec {
sha256 = "de83f219f95e6fe59099b277e3ced86f0430ad9468e845783092821dff15a72e"; sha256 = "de83f219f95e6fe59099b277e3ced86f0430ad9468e845783092821dff15a72e";
}; };
buildInputs = with pkgs; [ unzip ] patches = stdenv.lib.optional (!stdenv.cc.isClang) ./casts.patch;
++ stdenv.lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.Cocoa ];
patches = [ ./casts.patch ]; buildInputs = [ unzip ]
++ stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.Cocoa;
setSourceRoot = "sourceRoot=${product}-source-${version}"; setSourceRoot = "sourceRoot=${product}-source-${version}";
buildPhase = "bash build"; buildPhase = "bash build";
installPhase = "install -D AtomicParsley $out/bin/AtomicParsley"; installPhase = "install -D AtomicParsley $out/bin/AtomicParsley";