about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/filesystems/irods/common.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/tools/filesystems/irods/common.nix')
-rw-r--r--nixpkgs/pkgs/tools/filesystems/irods/common.nix24
1 files changed, 16 insertions, 8 deletions
diff --git a/nixpkgs/pkgs/tools/filesystems/irods/common.nix b/nixpkgs/pkgs/tools/filesystems/irods/common.nix
index fa80e024e3db..a7fdf9e2fb25 100644
--- a/nixpkgs/pkgs/tools/filesystems/irods/common.nix
+++ b/nixpkgs/pkgs/tools/filesystems/irods/common.nix
@@ -1,10 +1,13 @@
-{ lib, stdenv, bzip2, zlib, autoconf, automake, cmake, gnumake, help2man , texinfo, libtool , cppzmq , libarchive, avro-cpp, boost, jansson, zeromq, openssl, pam, libiodbc, libkrb5, gcc, libcxx, which, catch2 }:
+{ lib, stdenv, bzip2, zlib, autoconf, automake, cmake, gnumake, help2man, texinfo, libtool, cppzmq, libarchive
+, avro-cpp, boost, jansson, zeromq, openssl, pam, libiodbc, libkrb5, gcc, libcxx, which, catch2, nanodbc, fmt
+, nlohmann_json, spdlog }:
 
 # Common attributes of irods packages
 
 {
   nativeBuildInputs = [ autoconf automake cmake gnumake help2man texinfo which gcc ];
-  buildInputs = [ bzip2 zlib libtool cppzmq libarchive avro-cpp jansson zeromq openssl pam libiodbc libkrb5 boost libcxx catch2 ];
+  buildInputs = [ bzip2 zlib libtool cppzmq libarchive avro-cpp jansson zeromq openssl pam libiodbc libkrb5 boost
+                  libcxx catch2 nanodbc fmt nlohmann_json spdlog ];
 
   cmakeFlags = [
     "-DIRODS_EXTERNALS_FULLPATH_CLANG=${stdenv.cc}"
@@ -16,18 +19,23 @@
     "-DIRODS_EXTERNALS_FULLPATH_ZMQ=${zeromq}"
     "-DIRODS_EXTERNALS_FULLPATH_CPPZMQ=${cppzmq}"
     "-DIRODS_EXTERNALS_FULLPATH_CATCH2=${catch2}"
+    "-DIRODS_EXTERNALS_FULLPATH_NANODBC=${nanodbc}"
+    "-DIRODS_EXTERNALS_FULLPATH_FMT=${fmt}"
+    "-DIRODS_EXTERNALS_FULLPATH_JSON=${nlohmann_json}"
+    "-DIRODS_EXTERNALS_FULLPATH_SPDLOG=${spdlog}"
     "-DIRODS_LINUX_DISTRIBUTION_NAME=nix"
     "-DIRODS_LINUX_DISTRIBUTION_VERSION_MAJOR=1.0"
     "-DCPACK_GENERATOR=TGZ"
     "-DCMAKE_CXX_FLAGS=-I${lib.getDev libcxx}/include/c++/v1"
   ];
 
-  preConfigure = ''
-    patchShebangs ./packaging
-    patchShebangs ./scripts
-    substituteInPlace CMakeLists.txt --replace "DESTINATION usr/bin" "DESTINATION bin"
-    substituteInPlace CMakeLists.txt --replace "INCLUDE_DIRS usr/include/" "INCLUDE_DIRS include/"
-    substituteInPlace CMakeLists.txt --replace "DESTINATION usr/lib/" "DESTINATION lib/"
+  postPatch = ''
+    patchShebangs ./packaging ./scripts
+    substituteInPlace CMakeLists.txt \
+      --replace "DESTINATION usr/bin" "DESTINATION bin" \
+      --replace "INCLUDE_DIRS usr/include/" "INCLUDE_DIRS include/" \
+      --replace "DESTINATION usr/lib/" "DESTINATION lib/" \
+      --replace "{IRODS_EXTERNALS_FULLPATH_JSON}/include" "{IRODS_EXTERNALS_FULLPATH_JSON}/include/nlohmann"
     export cmakeFlags="$cmakeFlags
       -DCMAKE_INSTALL_PREFIX=$out
     "