forked from mirrors/nixpkgs
treewide: drop conditional makeFlag for darwin when specifiying cross-compiler
This commit is contained in:
parent
223f25cf4a
commit
4b2c44c0a7
|
@ -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";
|
||||||
|
|
|
@ -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"}"
|
||||||
|
|
|
@ -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
|
||||||
|
|
|
@ -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;
|
||||||
|
|
||||||
|
|
|
@ -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
|
||||||
|
|
|
@ -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
|
||||||
|
|
Loading…
Reference in a new issue