about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/exiv2
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2021-01-10 07:13:44 +0000
committerAlyssa Ross <hi@alyssa.is>2021-01-12 14:07:16 +0000
commite2698550456abba83c6dcd5d5e5a9990a0b96f8a (patch)
tree79a56f0df3fa55e470d84b4dff6059fbf487ec18 /nixpkgs/pkgs/development/libraries/exiv2
parent1cdc42df888dc98c347e03bd942ed9825a55bcb3 (diff)
parent84d74ae9c9cbed73274b8e4e00be14688ffc93fe (diff)
downloadnixlib-e2698550456abba83c6dcd5d5e5a9990a0b96f8a.tar
nixlib-e2698550456abba83c6dcd5d5e5a9990a0b96f8a.tar.gz
nixlib-e2698550456abba83c6dcd5d5e5a9990a0b96f8a.tar.bz2
nixlib-e2698550456abba83c6dcd5d5e5a9990a0b96f8a.tar.lz
nixlib-e2698550456abba83c6dcd5d5e5a9990a0b96f8a.tar.xz
nixlib-e2698550456abba83c6dcd5d5e5a9990a0b96f8a.tar.zst
nixlib-e2698550456abba83c6dcd5d5e5a9990a0b96f8a.zip
Merge commit '84d74ae9c9cbed73274b8e4e00be14688ffc93fe'
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/exiv2')
-rw-r--r--nixpkgs/pkgs/development/libraries/exiv2/default.nix56
1 files changed, 29 insertions, 27 deletions
diff --git a/nixpkgs/pkgs/development/libraries/exiv2/default.nix b/nixpkgs/pkgs/development/libraries/exiv2/default.nix
index 8a6dfd1983ef..a845e8998e78 100644
--- a/nixpkgs/pkgs/development/libraries/exiv2/default.nix
+++ b/nixpkgs/pkgs/development/libraries/exiv2/default.nix
@@ -15,37 +15,38 @@
 
 stdenv.mkDerivation rec {
   pname = "exiv2";
-  version = "0.27.2";
+  version = "0.27.3";
+
+  outputs = [ "out" "dev" "doc" "man" ];
 
   src = fetchFromGitHub {
     owner = "exiv2";
     repo  = "exiv2";
     rev = "v${version}";
-    sha256 = "0n8il52yzbmvbkryrl8waz7hd9a2fdkw8zsrmhyh63jlvmmc31gf";
+    sha256 = "0d294yhcdw8ziybyd4rp5hzwknzik2sm0cz60ff7fljacv75bjpy";
   };
 
   patches = [
-    # included in next release
+    # Fix aarch64 build https://github.com/Exiv2/exiv2/pull/1271
     (fetchpatch {
-      name = "cve-2019-20421.patch";
-      url = "https://github.com/Exiv2/exiv2/commit/a82098f4f90cd86297131b5663c3dec6a34470e8.patch";
-      sha256 = "16r19qb9l5j43ixm5jqid9sdv5brlkk1wq0w79rm5agxq4kblfyc";
-      excludes = [ "tests/bugfixes/github/test_issue_1011.py" "test/data/Jp2Image_readMetadata_loop.poc" ];
+      name = "cmake-fix-aarch64.patch";
+      url = "https://github.com/Exiv2/exiv2/commit/bbe0b70840cf28b7dd8c0b7e9bb1b741aeda2efd.patch";
+      sha256 = "13zw1mn0ag0jrz73hqjhdsh1img7jvj5yddip2k2sb5phy04rzfx";
     })
-  ];
 
-  cmakeFlags = [
-    "-DEXIV2_BUILD_PO=ON"
-    "-DEXIV2_BUILD_DOC=ON"
-    # the cmake package does not handle absolute CMAKE_INSTALL_INCLUDEDIR correctly
-    # (setting it to an absolute path causes include files to go to $out/$out/include,
-    #  because the absolute path is interpreted with root at $out).
-    "-DCMAKE_INSTALL_INCLUDEDIR=include"
-    "-DCMAKE_INSTALL_LIBDIR=lib"
+    # Use correct paths with multiple outputs
+    # https://github.com/Exiv2/exiv2/pull/1275
+    (fetchpatch {
+      url = "https://github.com/Exiv2/exiv2/commit/48f2c9dbbacc0ef84c8ebf4cb1a603327f0b8750.patch";
+      sha256 = "vjB3+Ld4c/2LT7nq6uatYwfHTh+HeU5QFPFXuNLpIPA=";
+    })
+    # https://github.com/Exiv2/exiv2/pull/1294
+    (fetchpatch {
+      url = "https://github.com/Exiv2/exiv2/commit/306c8a6fd4ddd70e76043ab255734720829a57e8.patch";
+      sha256 = "0D/omxYxBPGUu3uSErlf48dc6Ukwc2cEN9/J3e7a9eU=";
+    })
   ];
 
-  outputs = [ "out" "dev" "doc" "man" ];
-
   nativeBuildInputs = [
     cmake
     doxygen
@@ -65,7 +66,13 @@ stdenv.mkDerivation rec {
     which
   ];
 
+  cmakeFlags = [
+    "-DEXIV2_ENABLE_NLS=ON"
+    "-DEXIV2_BUILD_DOC=ON"
+  ];
+
   buildFlags = [
+    "all"
     "doc"
   ];
 
@@ -77,7 +84,6 @@ stdenv.mkDerivation rec {
   preCheck = ''
     patchShebangs ../test/
     mkdir ../test/tmp
-    export LD_LIBRARY_PATH="$(realpath ../build/lib)"
 
     ${stdenv.lib.optionalString (stdenv.isAarch64 || stdenv.isAarch32) ''
       # Fix tests on arm
@@ -86,19 +92,16 @@ stdenv.mkDerivation rec {
     ''}
 
     ${stdenv.lib.optionalString stdenv.isDarwin ''
-      export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH''${DYLD_LIBRARY_PATH:+:}`pwd`/lib
+      export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH''${DYLD_LIBRARY_PATH:+:}$PWD/lib
       # Removing tests depending on charset conversion
       substituteInPlace ../test/Makefile --replace "conversions.sh" ""
       rm -f ../tests/bugfixes/redmine/test_issue_460.py
       rm -f ../tests/bugfixes/redmine/test_issue_662.py
+      rm -f ../tests/bugfixes/github/test_issue_1046.py
      ''}
   '';
 
-  postCheck = ''
-    (cd ../tests/ && python3 runner.py)
-  '';
-
-  # With cmake we have to enable samples or there won't be
+  # With CMake we have to enable samples or there won't be
   # a tests target. This removes them.
   postInstall = ''
     ( cd "$out/bin"
@@ -108,12 +111,11 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  enableParallelBuilding = true;
-
   meta = with stdenv.lib; {
     homepage = "https://www.exiv2.org/";
     description = "A library and command-line utility to manage image metadata";
     platforms = platforms.all;
     license = licenses.gpl2Plus;
+    maintainers = [ ];
   };
 }