about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/nanodbc/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/nanodbc/default.nix')
-rw-r--r--nixpkgs/pkgs/development/libraries/nanodbc/default.nix19
1 files changed, 7 insertions, 12 deletions
diff --git a/nixpkgs/pkgs/development/libraries/nanodbc/default.nix b/nixpkgs/pkgs/development/libraries/nanodbc/default.nix
index 64f362e35202..7fca00c1d459 100644
--- a/nixpkgs/pkgs/development/libraries/nanodbc/default.nix
+++ b/nixpkgs/pkgs/development/libraries/nanodbc/default.nix
@@ -1,16 +1,20 @@
-{ lib, stdenv, fetchFromGitHub, cmake, unixODBC }:
+{ lib, stdenv, fetchFromGitHub, catch2, cmake, unixODBC }:
 
 stdenv.mkDerivation rec {
   pname = "nanodbc";
-  version = "2.13.0";
+  version = "2.14.0";
 
   src = fetchFromGitHub {
     owner = "nanodbc";
     repo = "nanodbc";
     rev = "v${version}";
-    sha256 = "1q80p7yv9mcl4hyvnvcjdr70y8nc940ypf368lp97vpqn5yckkgm";
+    hash = "sha256-dVUOwA7LfLqcQq2nc6OAha0krmgTy5RUHupBVrNdo4g=";
   };
 
+  postPatch = ''
+    cp ${catch2}/include/catch2/catch.hpp test/catch/catch.hpp
+  '';
+
   nativeBuildInputs = [ cmake ];
 
   buildInputs = [ unixODBC ];
@@ -20,15 +24,6 @@ stdenv.mkDerivation rec {
   else
     [ "-DBUILD_SHARED_LIBS=ON" ];
 
-  # fix compilation on macOS
-  # https://github.com/nanodbc/nanodbc/issues/274
-  # remove after the next version update
-  postUnpack = if stdenv.isDarwin then ''
-    mv $sourceRoot/VERSION $sourceRoot/VERSION.txt
-    substituteInPlace $sourceRoot/CMakeLists.txt \
-       --replace 'file(STRINGS VERSION' 'file(STRINGS VERSION.txt'
-  '' else "";
-
   meta = with lib; {
     homepage = "https://github.com/nanodbc/nanodbc";
     changelog = "https://github.com/nanodbc/nanodbc/raw/v${version}/CHANGELOG.md";