hdf4: consistently use *Support arguments
This commit is contained in:
parent
9e88aadbb4
commit
499eb1b56a
2 changed files with 17 additions and 7 deletions
|
@ -7,7 +7,8 @@
|
|||
, uselibtirpc ? stdenv.isLinux
|
||||
, libtirpc
|
||||
, zlib
|
||||
, szip ? null
|
||||
, szipSupport ? false
|
||||
, szip
|
||||
, javaSupport ? false
|
||||
, jdk
|
||||
}:
|
||||
|
@ -55,10 +56,10 @@ stdenv.mkDerivation rec {
|
|||
|
||||
buildInputs = [
|
||||
libjpeg
|
||||
szip
|
||||
zlib
|
||||
]
|
||||
++ lib.optional javaSupport jdk
|
||||
++ lib.optional szipSupport szip
|
||||
++ lib.optional uselibtirpc libtirpc;
|
||||
|
||||
preConfigure = lib.optionalString uselibtirpc ''
|
||||
|
@ -66,7 +67,7 @@ stdenv.mkDerivation rec {
|
|||
substituteInPlace config/cmake/FindXDR.cmake \
|
||||
--replace 'find_path(XDR_INCLUDE_DIR NAMES rpc/types.h PATHS "/usr/include" "/usr/include/tirpc")' \
|
||||
'find_path(XDR_INCLUDE_DIR NAMES rpc/types.h PATH_SUFFIXES include/tirpc)'
|
||||
'' + lib.optionalString (szip != null) ''
|
||||
'' + lib.optionalString szipSupport ''
|
||||
export SZIP_INSTALL=${szip}
|
||||
'';
|
||||
|
||||
|
@ -85,7 +86,7 @@ stdenv.mkDerivation rec {
|
|||
"-DJAVA_HOME=${jdk}"
|
||||
"-DJAVA_AWT_LIBRARY=${javabase}/libawt.so"
|
||||
"-DJAVA_JVM_LIBRARY=${javabase}/server/libjvm.so"
|
||||
] ++ lib.optionals (szip != null) [
|
||||
] ++ lib.optionals szipSupport [
|
||||
"-DHDF4_ENABLE_SZIP_ENCODING=ON"
|
||||
"-DHDF4_ENABLE_SZIP_SUPPORT=ON"
|
||||
];
|
||||
|
@ -119,6 +120,17 @@ stdenv.mkDerivation rec {
|
|||
moveToOutput bin "$bin"
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
inherit
|
||||
uselibtirpc
|
||||
libtirpc
|
||||
szipSupport
|
||||
szip
|
||||
javaSupport
|
||||
jdk
|
||||
;
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "Data model, library, and file format for storing and managing data";
|
||||
homepage = "https://support.hdfgroup.org/products/hdf4/";
|
||||
|
|
|
@ -5969,9 +5969,7 @@ with pkgs;
|
|||
|
||||
hddtemp = callPackage ../tools/misc/hddtemp { };
|
||||
|
||||
hdf4 = callPackage ../tools/misc/hdf4 {
|
||||
szip = null;
|
||||
};
|
||||
hdf4 = callPackage ../tools/misc/hdf4 { };
|
||||
|
||||
hdf5 = callPackage ../tools/misc/hdf5 {
|
||||
gfortran = null;
|
||||
|
|
Loading…
Reference in a new issue