Merge pull request #136571 from markuskowa/fix-gfortran

treewide: move gfortran to nativeBuildInputs
This commit is contained in:
markuskowa 2021-09-08 14:48:28 +02:00 committed by GitHub
commit 13bd2afb65
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
34 changed files with 78 additions and 56 deletions

View File

@ -61,6 +61,7 @@ mkDerivation rec {
ninja ninja
pkg-config pkg-config
pyside2-tools pyside2-tools
gfortran
wrapQtAppsHook wrapQtAppsHook
]; ];
@ -69,7 +70,6 @@ mkDerivation rec {
boost boost
coin3d coin3d
eigen eigen
gfortran
gts gts
hdf5 hdf5
libGLU libGLU

View File

@ -27,9 +27,15 @@ in stdenv.mkDerivation {
./openblasPath.patch ./openblasPath.patch
]; ];
nativeBuildInputs = [ perl cmake texlive.combined.scheme-minimal makeWrapper ]; nativeBuildInputs = [
buildInputs = [ perl
gfortran gfortran
cmake
texlive.combined.scheme-minimal
makeWrapper
];
buildInputs = [
openblas openblas
hdf5-cpp hdf5-cpp
python python

View File

@ -21,10 +21,12 @@ stdenv.mkDerivation rec {
patchShebangs configure patchShebangs configure
''; '';
buildInputs = [ fftw blas lapack gfortran ] nativeBuildInputs = [ gfortran ];
buildInputs = [ fftw blas lapack ]
++ (lib.optionals useMpi [ mpi ]); ++ (lib.optionals useMpi [ mpi ]);
configureFlags = if useMpi then [ "LD=${mpi}/bin/mpif90" ] else [ "LD=${gfortran}/bin/gfortran" ]; configureFlags = if useMpi then [ "LD=${mpi}/bin/mpif90" ] else [ "LD=${gfortran}/bin/gfortran" ];
makeFlags = [ "all" ]; makeFlags = [ "all" ];

View File

@ -17,7 +17,9 @@ stdenv.mkDerivation {
inherit mpi; inherit mpi;
}; };
buildInputs = [ blas lapack gfortran ] nativeBuildInputs = [ gfortran ];
buildInputs = [ blas lapack ]
++ lib.optionals useMpi [ mpi scalapack ]; ++ lib.optionals useMpi [ mpi scalapack ];
enableParallelBuilding = true; enableParallelBuilding = true;

View File

@ -8,7 +8,9 @@ stdenv.mkDerivation {
sha256 = "1f9ql6cjy2gwiyc51ylfan24v1ca9sjajxkbhszlds1lqmma8n05"; sha256 = "1f9ql6cjy2gwiyc51ylfan24v1ca9sjajxkbhszlds1lqmma8n05";
}; };
buildInputs = [ blas gfortran.cc.lib lapack ]; nativeBuildInputs = [ gfortran ];
buildInputs = [ blas lapack ];
postPatch = '' postPatch = ''
substituteInPlace Makefile --replace /usr/local/bin $out/bin substituteInPlace Makefile --replace /usr/local/bin $out/bin

View File

@ -6,7 +6,11 @@ stdenv.mkDerivation rec {
url = "mirror://sourceforge/mcmc-jags/${name}.tar.gz"; url = "mirror://sourceforge/mcmc-jags/${name}.tar.gz";
sha256 = "1z3icccg2ic56vmhyrpinlsvpq7kcaflk1731rgpvz9bk1bxvica"; sha256 = "1z3icccg2ic56vmhyrpinlsvpq7kcaflk1731rgpvz9bk1bxvica";
}; };
buildInputs = [gfortran blas lapack];
nativeBuildInputs = [ gfortran ];
buildInputs = [ blas lapack ];
configureFlags = [ "--with-blas=-lblas" "--with-lapack=-llapack" ]; configureFlags = [ "--with-blas=-lblas" "--with-lapack=-llapack" ];
meta = with lib; { meta = with lib; {

View File

@ -19,11 +19,12 @@ stdenv.mkDerivation rec {
sha256 = "1adk6jqlj7i3gjklvlf1j3il1nb22axnp4rvwl314an62siih0sc"; sha256 = "1adk6jqlj7i3gjklvlf1j3il1nb22axnp4rvwl314an62siih0sc";
}; };
buildInputs = [gfortran ncurses] nativeBuildInputs = [ gfortran ];
++ lib.optionals withGtk [gtk2]
++ lib.optionals withOCaml [ocaml] buildInputs = [ ncurses ]
++ lib.optional withX xlibsWrapper ++ lib.optionals withGtk [ gtk2 ]
; ++ lib.optionals withOCaml [ ocaml ]
++ lib.optional withX xlibsWrapper;
/* /*

View File

@ -11,7 +11,9 @@ stdenv.mkDerivation {
sha256 = "1r76zvln3bwycxlmqday0sqzv5j260y7mdh66as2aqny6jzd5ld7"; sha256 = "1r76zvln3bwycxlmqday0sqzv5j260y7mdh66as2aqny6jzd5ld7";
}; };
buildInputs = [ mpi gfortran ]; nativeBuildInputs = [ gfortran ];
buildInputs = [ mpi ];
configurePhase = '' configurePhase = ''
cd source cd source

View File

@ -13,8 +13,8 @@ stdenv.mkDerivation rec {
hardeningDisable = [ "format" ]; hardeningDisable = [ "format" ];
nativeBuildInputs = [ cmake pkg-config git ]; nativeBuildInputs = [ cmake gfortran pkg-config git ];
buildInputs = [ gfortran mpi blas liblapack qt4 qwt6_qt4 ]; buildInputs = [ mpi blas liblapack qt4 qwt6_qt4 ];
preConfigure = '' preConfigure = ''
patchShebangs ./ patchShebangs ./

View File

@ -13,7 +13,10 @@ stdenv.mkDerivation rec {
sed -ie '/sys\/sysctl.h/d' ATOOLS/Org/Run_Parameter.C sed -ie '/sys\/sysctl.h/d' ATOOLS/Org/Run_Parameter.C
''; '';
buildInputs = [ gfortran sqlite lhapdf rivet ];
nativeBuildInputs = [ gfortran ];
buildInputs = [ sqlite lhapdf rivet ];
enableParallelBuilding = true; enableParallelBuilding = true;

View File

@ -370,9 +370,11 @@ in rec {
./009_remove_signedness_verifier.patch ./010_mx_substratevm.py ./009_remove_signedness_verifier.patch ./010_mx_substratevm.py
]; ];
nativeBuildInputs = [ gfortran ];
buildInputs = [ mx zlib.dev mercurial jvmci8 git llvm clang buildInputs = [ mx zlib.dev mercurial jvmci8 git llvm clang
python27withPackages icu ruby bzip2 which python27withPackages icu ruby bzip2 which
readline bzip2 xz pcre curl ed gfortran readline bzip2 xz pcre curl ed
] ++ lib.optional stdenv.isDarwin [ ] ++ lib.optional stdenv.isDarwin [
CoreFoundation gcc.cc.lib libiconv perl openssl CoreFoundation gcc.cc.lib libiconv perl openssl
]; ];

View File

@ -17,13 +17,13 @@ stdenv.mkDerivation rec {
substituteInPlace cmake/FindOpenJPEG.cmake --replace openjpeg-2.1 ${openjpeg.incDir} substituteInPlace cmake/FindOpenJPEG.cmake --replace openjpeg-2.1 ${openjpeg.incDir}
''; '';
nativeBuildInputs = [ cmake ]; nativeBuildInputs = [ cmake gfortran ];
buildInputs = [ netcdf buildInputs = [ netcdf
openjpeg openjpeg
libpng libpng
gfortran
]; ];
propagatedBuildInputs = optionals enablePython [ propagatedBuildInputs = optionals enablePython [
pythonPackages.python pythonPackages.python
pythonPackages.numpy pythonPackages.numpy

View File

@ -13,8 +13,8 @@ stdenv.mkDerivation rec {
sha256 = "0bky91ncz6vy0011ps9prsnq9f4a5s5xwr23kkmi39xzg0417mnd"; sha256 = "0bky91ncz6vy0011ps9prsnq9f4a5s5xwr23kkmi39xzg0417mnd";
}; };
nativeBuildInputs = [ autoreconfHook ]; nativeBuildInputs = [ autoreconfHook gfortran ];
buildInputs = [ mpi blas gfortran openssh ]; buildInputs = [ mpi blas openssh ];
preConfigure = '' preConfigure = ''
configureFlagsArray+=( "--enable-i8" \ configureFlagsArray+=( "--enable-i8" \

View File

@ -11,8 +11,7 @@ stdenv.mkDerivation rec {
sha256 = "0cy3x2zn1bldc5i0rzislfbc8h4nqgds445jkfqjv0d1shvdy0zn"; sha256 = "0cy3x2zn1bldc5i0rzislfbc8h4nqgds445jkfqjv0d1shvdy0zn";
}; };
buildInputs = [ gfortran ]; nativeBuildInputs = [ perl cmake gfortran ];
nativeBuildInputs = [ perl cmake ];
preConfigure = '' preConfigure = ''
patchShebangs ./ patchShebangs ./

View File

@ -26,7 +26,8 @@ stdenv.mkDerivation rec {
enableParallelBuilding = true; enableParallelBuilding = true;
buildInputs = [ perl gfortran openssh hwloc ] nativeBuildInputs = [ gfortran ];
buildInputs = [ perl openssh hwloc ]
++ lib.optional (!stdenv.isDarwin) ch4backend; ++ lib.optional (!stdenv.isDarwin) ch4backend;
doCheck = true; doCheck = true;

View File

@ -21,13 +21,12 @@ stdenv.mkDerivation rec {
sha256 = "0jd28vy9ivl3rcpkxmhw73b6krzm0pd9jps8asw92wa00lm2z9mk"; sha256 = "0jd28vy9ivl3rcpkxmhw73b6krzm0pd9jps8asw92wa00lm2z9mk";
}; };
nativeBuildInputs = [ pkg-config bison makeWrapper ]; nativeBuildInputs = [ pkg-config bison makeWrapper gfortran ];
propagatedBuildInputs = [ numactl rdma-core zlib opensm ]; propagatedBuildInputs = [ numactl rdma-core zlib opensm ];
buildInputs = with lib; [ buildInputs = with lib; [
numactl numactl
libxml2 libxml2
perl perl
gfortran
openssh openssh
hwloc hwloc
] ++ optionals (network == "infiniband") [ rdma-core opensm ] ] ++ optionals (network == "infiniband") [ rdma-core opensm ]

View File

@ -8,7 +8,8 @@ stdenv.mkDerivation rec {
sha256 = "00qwg4v250yg8kxp68srrnvfbfim241fnlm071p9ila2mihk8r01"; sha256 = "00qwg4v250yg8kxp68srrnvfbfim241fnlm071p9ila2mihk8r01";
}; };
buildInputs = [ netcdf hdf5 curl gfortran ]; nativeBuildInputs = [ gfortran ];
buildInputs = [ netcdf hdf5 curl ];
doCheck = true; doCheck = true;
meta = with lib; { meta = with lib; {

View File

@ -46,14 +46,14 @@ in stdenv.mkDerivation rec {
''; '';
buildInputs = [ zlib ] buildInputs = [ zlib ]
++ lib.optionals fortranSupport [ gfortran ]
++ lib.optionals stdenv.isLinux [ libnl numactl pmix ucx ] ++ lib.optionals stdenv.isLinux [ libnl numactl pmix ucx ]
++ lib.optionals cudaSupport [ cudatoolkit ] ++ lib.optionals cudaSupport [ cudatoolkit ]
++ [ libevent hwloc ] ++ [ libevent hwloc ]
++ lib.optional (stdenv.isLinux || stdenv.isFreeBSD) rdma-core ++ lib.optional (stdenv.isLinux || stdenv.isFreeBSD) rdma-core
++ lib.optional fabricSupport [ libpsm2 libfabric ]; ++ lib.optional fabricSupport [ libpsm2 libfabric ];
nativeBuildInputs = [ perl ]; nativeBuildInputs = [ perl ]
++ lib.optionals fortranSupport [ gfortran ];
configureFlags = lib.optional (!cudaSupport) "--disable-mca-dso" configureFlags = lib.optional (!cudaSupport) "--disable-mca-dso"
++ lib.optional (!fortranSupport) "--disable-mpi-fortran" ++ lib.optional (!fortranSupport) "--disable-mpi-fortran"

View File

@ -9,8 +9,10 @@ stdenv.mkDerivation rec {
sha256 = "1yw9wrk3vjv84kd3j4s1scfhinirknwk6xq0hvj7x2srx3h93q9p"; sha256 = "1yw9wrk3vjv84kd3j4s1scfhinirknwk6xq0hvj7x2srx3h93q9p";
}; };
nativeBuildInputs = [ gfortran ];
# For some reason zlib was only needed after bump to gfortran8 # For some reason zlib was only needed after bump to gfortran8
buildInputs = [ gfortran hoppet lhapdf root5 zlib ]; buildInputs = [ hoppet lhapdf root5 zlib ];
patches = [ patches = [
./bad_code.patch ./bad_code.patch

View File

@ -9,9 +9,9 @@ stdenv.mkDerivation rec {
sha256 = "10y3fb33zsinr0z3hzap9rsbcqhy1yjqnv4b4vz21g7mdlw6pq2k"; sha256 = "10y3fb33zsinr0z3hzap9rsbcqhy1yjqnv4b4vz21g7mdlw6pq2k";
}; };
nativeBuildInputs = [ autoconf automake libtool ]; nativeBuildInputs = [ autoconf automake libtool gfortran ];
buildInputs = [ boost fastjet gfortran gsl thepeg zlib ] buildInputs = [ boost fastjet gsl thepeg zlib ]
# There is a bug that requires for default PDF's to be present during the build # There is a bug that requires for default PDF's to be present during the build
++ (with lhapdf.pdf_sets; [ CT14lo CT14nlo ]); ++ (with lhapdf.pdf_sets; [ CT14lo CT14nlo ]);

View File

@ -9,8 +9,7 @@ stdenv.mkDerivation rec {
sha256 = "0j7437rh4xxbfzmkjr22ry34xm266gijzj6mvrq193fcsfzipzdz"; sha256 = "0j7437rh4xxbfzmkjr22ry34xm266gijzj6mvrq193fcsfzipzdz";
}; };
buildInputs = [ gfortran ]; nativeBuildInputs = [ perl gfortran ];
nativeBuildInputs = [ perl ];
enableParallelBuilding = true; enableParallelBuilding = true;

View File

@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
sha256 = "01sgd4mwx4n58x95brphp4dskqkkx8434bvsr38r5drg9na5nc9y"; sha256 = "01sgd4mwx4n58x95brphp4dskqkkx8434bvsr38r5drg9na5nc9y";
}; };
buildInputs = [ gfortran ]; nativeBuildInputs = [ gfortran ];
enableParallelBuilding = true; enableParallelBuilding = true;

View File

@ -42,9 +42,7 @@ stdenv.mkDerivation rec {
installTargets = lib.optionals stdenv.isDarwin [ "install-staticlib" "install-shlib" ]; installTargets = lib.optionals stdenv.isDarwin [ "install-staticlib" "install-shlib" ];
buildInputs = [ gfortran ]; nativeBuildInputs = [ which gfortran ];
nativeBuildInputs = [ which ];
meta = with lib; { meta = with lib; {
description = "Library for fast updating of qr and cholesky decompositions"; description = "Library for fast updating of qr and cholesky decompositions";

View File

@ -22,9 +22,8 @@ stdenv.mkDerivation rec {
}) })
]; ];
nativeBuildInputs = [ cmake ]; nativeBuildInputs = [ cmake gfortran ];
buildInputs = assert (blas.isILP64 == lapack.isILP64); [ buildInputs = assert (blas.isILP64 == lapack.isILP64); [
gfortran
blas blas
lapack lapack
eigen eigen

View File

@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
sha256 = "sha256-LjYNmcm9yEB6YYiMQKqFP7QhlCDruCZNtIbLiGBGirM="; sha256 = "sha256-LjYNmcm9yEB6YYiMQKqFP7QhlCDruCZNtIbLiGBGirM=";
}; };
buildInputs = [ gfortran ]; nativeBuildInputs = [ gfortran ];
configurePhase = '' configurePhase = ''
echo >make.inc "SHELL = ${stdenv.shell}" echo >make.inc "SHELL = ${stdenv.shell}"

View File

@ -10,7 +10,8 @@ stdenv.mkDerivation rec {
sha256 = "0hz1lfp0zaarvl0dv0zgp337hyd8np41kmdpz5rr3fc6yzw7vmkg"; sha256 = "0hz1lfp0zaarvl0dv0zgp337hyd8np41kmdpz5rr3fc6yzw7vmkg";
}; };
buildInputs = [ suitesparse gfortran blas lapack ]; nativeBuildInputs = [ gfortran ];
buildInputs = [ suitesparse blas lapack ];
makeFlags = [ makeFlags = [
"BLAS=-lcblas" "BLAS=-lcblas"

View File

@ -35,9 +35,8 @@ stdenv.mkDerivation rec {
"-DBUILD_TEST=OFF" "-DBUILD_TEST=OFF"
]; ];
nativeBuildInputs = [ cmake ]; nativeBuildInputs = [ cmake gfortran ];
buildInputs = [ buildInputs = [
gfortran
blas blas
python3 python3
boost boost

View File

@ -18,9 +18,9 @@ stdenv.mkDerivation rec {
"--with-lapack-lib=-llapack" "--with-lapack-lib=-llapack"
]; ];
nativeBuildInputs = [ unzip ]; nativeBuildInputs = [ unzip gfortran ];
buildInputs = [ gfortran blas lapack ]; buildInputs = [ blas lapack ];
enableParallelBuilding = true; enableParallelBuilding = true;

View File

@ -15,8 +15,8 @@ stdenv.mkDerivation rec {
sha256 = "1c10d18gj3kvpmyv5q246x35hjxaqn4ygy1cygaydhyxnm4klzdj"; sha256 = "1c10d18gj3kvpmyv5q246x35hjxaqn4ygy1cygaydhyxnm4klzdj";
}; };
nativeBuildInputs = [ cmake openssh ]; nativeBuildInputs = [ cmake openssh gfortran ];
buildInputs = [ mpi gfortran blas lapack ]; buildInputs = [ mpi blas lapack ];
doCheck = true; doCheck = true;

View File

@ -1,4 +1,4 @@
{ lib, stdenv, fetchurl, gfortran, perl }: { lib, stdenv, fetchurl, perl }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "spooles"; pname = "spooles";

View File

@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
hash = "sha256-SNp7qoFS3bIq7RsC2C0du0+/6iKs9nY0ARqgMDoQCkM="; hash = "sha256-SNp7qoFS3bIq7RsC2C0du0+/6iKs9nY0ARqgMDoQCkM=";
}; };
nativeBuildInputs = [ cmake ]; nativeBuildInputs = [ cmake gfortran ];
buildInputs = [ buildInputs = [
python python
@ -29,7 +29,6 @@ stdenv.mkDerivation rec {
++ lib.optionals (lapackSupport) ++ lib.optionals (lapackSupport)
# Check that the same index size is used for both libraries # Check that the same index size is used for both libraries
(assert (blas.isILP64 == lapack.isILP64); [ (assert (blas.isILP64 == lapack.isILP64); [
gfortran
blas blas
lapack lapack
]) ])

View File

@ -16,7 +16,8 @@ buildPythonPackage rec {
sha256 = "1z3w2c50dwwa297j88pr16pyrjysagsvdj7vrlq40q8777rs7a6z"; sha256 = "1z3w2c50dwwa297j88pr16pyrjysagsvdj7vrlq40q8777rs7a6z";
}; };
buildInputs = [ pillow gfortran glibcLocales ]; nativeBuildInputs = [ gfortran ];
buildInputs = [ pillow glibcLocales ];
propagatedBuildInputs = [ numpy scipy numpy.blas ]; propagatedBuildInputs = [ numpy scipy numpy.blas ];
checkInputs = [ pytest ]; checkInputs = [ pytest ];

View File

@ -38,7 +38,6 @@ buildPythonPackage rec {
buildInputs = [ buildInputs = [
pillow pillow
gfortran
glibcLocales glibcLocales
] ++ lib.optionals stdenv.cc.isClang [ ] ++ lib.optionals stdenv.cc.isClang [
llvmPackages.openmp llvmPackages.openmp
@ -46,6 +45,7 @@ buildPythonPackage rec {
nativeBuildInputs = [ nativeBuildInputs = [
cython cython
gfortran
]; ];
propagatedBuildInputs = [ propagatedBuildInputs = [

View File

@ -34,10 +34,10 @@ stdenv.mkDerivation rec {
outputs = [ "out" "dev" ]; outputs = [ "out" "dev" ];
nativeBuildInputs = [ removeReferencesTo ]; nativeBuildInputs = [ removeReferencesTo ]
++ optional (gfortran != null) gfortran;
buildInputs = [] buildInputs = []
++ optional (gfortran != null) gfortran
++ optional (szip != null) szip ++ optional (szip != null) szip
++ optional javaSupport jdk; ++ optional javaSupport jdk;