3
0
Fork 0
forked from mirrors/nixpkgs

treewide: drop conditional makeFlag for darwin when specifiying cross-compiler

This commit is contained in:
Ben Siraphob 2021-02-16 18:51:23 +07:00
parent 223f25cf4a
commit 4b2c44c0a7
6 changed files with 7 additions and 7 deletions

View file

@ -6,7 +6,7 @@ stdenv.mkDerivation rec {
buildInputs = [ gmp perl ]; buildInputs = [ gmp perl ];
makeFlags = [ "PREFIX=$(out)" ] ++ lib.optionals stdenv.isDarwin [ "CC=${stdenv.cc.targetPrefix}cc" ]; makeFlags = [ "PREFIX=$(out)" "CC=${stdenv.cc.targetPrefix}cc" ];
src = fetchurl { src = fetchurl {
url = "https://github.com/kfl/mosml/archive/ver-${version}.tar.gz"; url = "https://github.com/kfl/mosml/archive/ver-${version}.tar.gz";

View file

@ -1,6 +1,6 @@
{ stdenv, lib, fetchFromGitHub, fetchpatch, which, sqlite, lua5_1, perl, python3, zlib, pkg-config, ncurses { stdenv, lib, fetchFromGitHub, fetchpatch, which, sqlite, lua5_1, perl, python3, zlib, pkg-config, ncurses
, dejavu_fonts, libpng, SDL2, SDL2_image, SDL2_mixer, libGLU, libGL, freetype, pngcrush, advancecomp , dejavu_fonts, libpng, SDL2, SDL2_image, SDL2_mixer, libGLU, libGL, freetype, pngcrush, advancecomp
, tileMode ? false, enableSound ? tileMode , tileMode ? false, enableSound ? tileMode, buildPackages
# MacOS / Darwin builds # MacOS / Darwin builds
, darwin ? null , darwin ? null
@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
fontsPath = lib.optionalString tileMode dejavu_fonts; fontsPath = lib.optionalString tileMode dejavu_fonts;
makeFlags = [ "prefix=${placeholder "out"}" "FORCE_CC=${stdenv.cc.targetPrefix}cc" "FORCE_CXX=${stdenv.cc.targetPrefix}c++" "HOSTCXX=${stdenv.cc.targetPrefix}c++" makeFlags = [ "prefix=${placeholder "out"}" "FORCE_CC=${stdenv.cc.targetPrefix}cc" "FORCE_CXX=${stdenv.cc.targetPrefix}c++" "HOSTCXX=${buildPackages.stdenv.cc.targetPrefix}c++"
"FORCE_PKGCONFIG=y" "FORCE_PKGCONFIG=y"
"SAVEDIR=~/.crawl" "sqlite=${sqlite.dev}" "SAVEDIR=~/.crawl" "sqlite=${sqlite.dev}"
"DATADIR=${placeholder "out"}" "DATADIR=${placeholder "out"}"

View file

@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
mv config.mk.template config.mk mv config.mk.template config.mk
''; '';
makeFlags = lib.optionals stdenv.isDarwin [ "CC=${stdenv.cc.targetPrefix}cc" ]; makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
installPhase = '' installPhase = ''
install -D hactool $out/bin/hactool install -D hactool $out/bin/hactool

View file

@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
"USE_GETADDRINFO=1" "USE_GETADDRINFO=1"
] ++ lib.optionals withPrometheusExporter [ ] ++ lib.optionals withPrometheusExporter [
"EXTRA_OBJS=contrib/prometheus-exporter/service-prometheus.o" "EXTRA_OBJS=contrib/prometheus-exporter/service-prometheus.o"
] ++ lib.optional stdenv.isDarwin "CC=${stdenv.cc.targetPrefix}cc"; ] ++ [ "CC=${stdenv.cc.targetPrefix}cc" ];
enableParallelBuilding = true; enableParallelBuilding = true;

View file

@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
configurePhase = '' configurePhase = ''
substituteInPlace Makefile --replace /usr/local "$out" substituteInPlace Makefile --replace /usr/local "$out"
''; '';
makeFlags = lib.optionals stdenv.isDarwin ["CC=${stdenv.cc.targetPrefix}cc"]; makeFlags = ["CC=${stdenv.cc.targetPrefix}cc"];
patches = [ patches = [
./apg.patch ./apg.patch

View file

@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
"GLOBALCONF=${placeholder "out"}/share/boxes/boxes-config" "GLOBALCONF=${placeholder "out"}/share/boxes/boxes-config"
''; '';
makeFlags = lib.optionals stdenv.isDarwin [ "CC=${stdenv.cc.targetPrefix}cc" ]; makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
installPhase = '' installPhase = ''
install -Dm755 -t $out/bin src/boxes install -Dm755 -t $out/bin src/boxes