uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
|
|
@ -0,0 +1,50 @@
|
|||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -54,21 +54,7 @@ endif()
|
||||
endif()
|
||||
|
||||
#Use c preprocessor with fortran
|
||||
-
|
||||
-if(UNIX AND NOT APPLE)
|
||||
- set(CMAKE_Fortran_FLAGS "-cpp -Wno-argument-mismatch")
|
||||
-endif()
|
||||
-
|
||||
-if(APPLE)
|
||||
- set(CMAKE_Fortran_FLAGS "-cpp -fallow-argument-mismatch")
|
||||
-endif()
|
||||
-
|
||||
-
|
||||
-if (CMAKE_MAJOR_VERSION VERSION_GREATER_EQUAL "3")
|
||||
-if(CMAKE_Fortran_COMPILER_VERSION VERSION_GREATER_EQUAL "10")
|
||||
- set(CMAKE_Fortran_FLAGS "-cpp -fallow-argument-mismatch")
|
||||
-endif()
|
||||
-endif()
|
||||
+set(CMAKE_Fortran_FLAGS "-cpp")
|
||||
|
||||
|
||||
#For Fortran
|
||||
diff --git a/src/GetChisquare.f b/src/GetChisquare.f
|
||||
index b21413fe..28391bcb 100644
|
||||
--- a/src/GetChisquare.f
|
||||
+++ b/src/GetChisquare.f
|
||||
@@ -2418,8 +2418,8 @@ C> @Brief Interface to lapack, to dynamically allocate work arrays
|
||||
integer NCovar, NDimCovar
|
||||
double precision Covar(NDimCovar,NDimCovar), EigenValues(NCovar)
|
||||
integer IFail
|
||||
- double precision Work
|
||||
- integer IWork
|
||||
+ double precision Work(1)
|
||||
+ integer IWork(1)
|
||||
Character*80 msg
|
||||
C---------------------------------------------------------------
|
||||
C Determine optimal size of the work array:
|
||||
@@ -2432,7 +2432,7 @@ C Determine optimal size of the work array:
|
||||
$ int(work)+1, iwork
|
||||
call HF_ERRLOG(14121701,msg)
|
||||
call MyDSYEVD2(NCovar,Covar,NDimCovar, EigenValues,
|
||||
- $ int(work)+1,iwork,ifail)
|
||||
+ $ int(work(1))+1,iwork(1),ifail)
|
||||
|
||||
end
|
||||
|
||||
62
pkgs/applications/science/physics/xfitter/default.nix
Normal file
62
pkgs/applications/science/physics/xfitter/default.nix
Normal file
|
|
@ -0,0 +1,62 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, apfel
|
||||
, apfelgrid
|
||||
, applgrid
|
||||
, blas
|
||||
, ceres-solver
|
||||
, cmake
|
||||
, gfortran
|
||||
, gsl
|
||||
, lapack
|
||||
, lhapdf
|
||||
, libtirpc
|
||||
, libyaml
|
||||
, libyamlcpp
|
||||
, pkg-config
|
||||
, qcdnum
|
||||
, root
|
||||
, zlib
|
||||
, memorymappingHook, memstreamHook
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "xfitter";
|
||||
version = "2.2.0";
|
||||
|
||||
src = fetchurl {
|
||||
name = "${pname}-${version}.tgz";
|
||||
url = "https://www.xfitter.org/xFitter/xFitter/DownloadPage?action=AttachFile&do=get&target=${pname}-${version}.tgz";
|
||||
sha256 = "sha256-ZHIQ5hOY+k0/wmpE0o4Po+RZ4MkVMk+bK1Rc6eqwwH0=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Avoid need for -fallow-argument-mismatch
|
||||
./0001-src-GetChisquare.f-use-correct-types-in-calls-to-DSY.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake gfortran pkg-config ];
|
||||
buildInputs =
|
||||
[ apfel blas ceres-solver lhapdf lapack libyaml root qcdnum gsl libyamlcpp zlib ]
|
||||
++ lib.optionals ("5" == lib.versions.major root.version) [ apfelgrid applgrid ]
|
||||
++ lib.optionals (stdenv.system == "x86_64-darwin") [ memorymappingHook memstreamHook ]
|
||||
++ lib.optional (stdenv.hostPlatform.libc == "glibc") libtirpc
|
||||
;
|
||||
|
||||
NIX_CFLAGS_COMPILE = lib.optional (stdenv.hostPlatform.libc == "glibc") "-I${libtirpc.dev}/include/tirpc";
|
||||
NIX_LDFLAGS = lib.optional (stdenv.hostPlatform.libc == "glibc") "-ltirpc";
|
||||
|
||||
# workaround wrong library IDs
|
||||
postInstall = lib.optionalString stdenv.isDarwin ''
|
||||
ln -sv "$out/lib/xfitter/"* "$out/lib/"
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "The xFitter project is an open source QCD fit framework ready to extract PDFs and assess the impact of new data";
|
||||
license = licenses.gpl3;
|
||||
homepage = "https://www.xfitter.org/xFitter";
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ veprbl ];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue