From 9e0b98c30994d350c4705deb66abce632e2e44ee Mon Sep 17 00:00:00 2001 From: Anthony Roussel Date: Thu, 14 Mar 2024 23:56:23 +0100 Subject: [PATCH 1/4] exiftool: move to pkgs/development/perl-modules --- .../perl-modules/ImageExifTool/default.nix | 41 +++++++++++++++++++ pkgs/top-level/perl-packages.nix | 35 +--------------- 2 files changed, 42 insertions(+), 34 deletions(-) create mode 100644 pkgs/development/perl-modules/ImageExifTool/default.nix diff --git a/pkgs/development/perl-modules/ImageExifTool/default.nix b/pkgs/development/perl-modules/ImageExifTool/default.nix new file mode 100644 index 000000000000..67fc8318a7be --- /dev/null +++ b/pkgs/development/perl-modules/ImageExifTool/default.nix @@ -0,0 +1,41 @@ +{ lib +, stdenv +, buildPerlPackage +, fetchurl +, shortenPerlShebang +}: + +buildPerlPackage rec { + pname = "Image-ExifTool"; + version = "12.70"; + + src = fetchurl { + url = "https://exiftool.org/Image-ExifTool-${version}.tar.gz"; + hash = "sha256-TLJSJEXMPj870TkExq6uraX8Wl4kmNerrSlX3LQsr/4="; + }; + + nativeBuildInputs = lib.optional stdenv.isDarwin shortenPerlShebang; + postInstall = lib.optionalString stdenv.isDarwin '' + shortenPerlShebang $out/bin/exiftool + ''; + + meta = { + description = "A tool to read, write and edit EXIF meta information"; + longDescription = '' + ExifTool is a platform-independent Perl library plus a command-line + application for reading, writing and editing meta information in a wide + variety of files. ExifTool supports many different metadata formats + including EXIF, GPS, IPTC, XMP, JFIF, GeoTIFF, ICC Profile, Photoshop + IRB, FlashPix, AFCP and ID3, as well as the maker notes of many digital + cameras by Canon, Casio, DJI, FLIR, FujiFilm, GE, GoPro, HP, + JVC/Victor, Kodak, Leaf, Minolta/Konica-Minolta, Motorola, Nikon, + Nintendo, Olympus/Epson, Panasonic/Leica, Pentax/Asahi, Phase One, + Reconyx, Ricoh, Samsung, Sanyo, Sigma/Foveon and Sony. + ''; + homepage = "https://exiftool.org/"; + changelog = "https://exiftool.org/history.html"; + license = with lib.licenses; [ gpl1Plus /* or */ artistic2 ]; + maintainers = with lib.maintainers; [ kiloreux anthonyroussel ]; + mainProgram = "exiftool"; + }; +} diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix index 718153801014..b3e5f90696e1 100644 --- a/pkgs/top-level/perl-packages.nix +++ b/pkgs/top-level/perl-packages.nix @@ -13205,40 +13205,7 @@ with self; { }; }; - ImageExifTool = buildPerlPackage rec { - pname = "Image-ExifTool"; - version = "12.70"; - - src = fetchurl { - url = "https://exiftool.org/Image-ExifTool-${version}.tar.gz"; - hash = "sha256-TLJSJEXMPj870TkExq6uraX8Wl4kmNerrSlX3LQsr/4="; - }; - - nativeBuildInputs = lib.optional stdenv.isDarwin shortenPerlShebang; - postInstall = lib.optionalString stdenv.isDarwin '' - shortenPerlShebang $out/bin/exiftool - ''; - - meta = { - description = "A tool to read, write and edit EXIF meta information"; - longDescription = '' - ExifTool is a platform-independent Perl library plus a command-line - application for reading, writing and editing meta information in a wide - variety of files. ExifTool supports many different metadata formats - including EXIF, GPS, IPTC, XMP, JFIF, GeoTIFF, ICC Profile, Photoshop - IRB, FlashPix, AFCP and ID3, as well as the maker notes of many digital - cameras by Canon, Casio, DJI, FLIR, FujiFilm, GE, GoPro, HP, - JVC/Victor, Kodak, Leaf, Minolta/Konica-Minolta, Motorola, Nikon, - Nintendo, Olympus/Epson, Panasonic/Leica, Pentax/Asahi, Phase One, - Reconyx, Ricoh, Samsung, Sanyo, Sigma/Foveon and Sony. - ''; - homepage = "https://exiftool.org/"; - changelog = "https://exiftool.org/history.html"; - license = with lib.licenses; [ gpl1Plus /* or */ artistic2 ]; - maintainers = with maintainers; [ kiloreux anthonyroussel ]; - mainProgram = "exiftool"; - }; - }; + ImageExifTool = callPackage ../development/perl-modules/ImageExifTool { }; Inline = buildPerlPackage { pname = "Inline"; From 74194ca56376df5ace0e55effcdb47a1a43afd4e Mon Sep 17 00:00:00 2001 From: Anthony Roussel Date: Fri, 15 Mar 2024 00:00:40 +0100 Subject: [PATCH 2/4] exiftool: add passthru.updateScript --- pkgs/development/perl-modules/ImageExifTool/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/development/perl-modules/ImageExifTool/default.nix b/pkgs/development/perl-modules/ImageExifTool/default.nix index 67fc8318a7be..c61c5915e55f 100644 --- a/pkgs/development/perl-modules/ImageExifTool/default.nix +++ b/pkgs/development/perl-modules/ImageExifTool/default.nix @@ -2,6 +2,7 @@ , stdenv , buildPerlPackage , fetchurl +, gitUpdater , shortenPerlShebang }: @@ -19,6 +20,12 @@ buildPerlPackage rec { shortenPerlShebang $out/bin/exiftool ''; + passthru = { + updateScript = gitUpdater { + url = "https://github.com/exiftool/exiftool.git"; + }; + }; + meta = { description = "A tool to read, write and edit EXIF meta information"; longDescription = '' From 0dfa68647420b93080a04508dda41476cccc0cd0 Mon Sep 17 00:00:00 2001 From: Anthony Roussel Date: Fri, 15 Mar 2024 00:03:29 +0100 Subject: [PATCH 3/4] exiftool: add passthru.tests.version --- pkgs/development/perl-modules/ImageExifTool/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/development/perl-modules/ImageExifTool/default.nix b/pkgs/development/perl-modules/ImageExifTool/default.nix index c61c5915e55f..54ff6c9b2a04 100644 --- a/pkgs/development/perl-modules/ImageExifTool/default.nix +++ b/pkgs/development/perl-modules/ImageExifTool/default.nix @@ -1,9 +1,11 @@ { lib , stdenv , buildPerlPackage +, exiftool , fetchurl , gitUpdater , shortenPerlShebang +, testers }: buildPerlPackage rec { @@ -21,6 +23,11 @@ buildPerlPackage rec { ''; passthru = { + tests.version = testers.testVersion { + inherit version; + command = "${lib.getExe exiftool} -ver"; + package = exiftool; + }; updateScript = gitUpdater { url = "https://github.com/exiftool/exiftool.git"; }; From e5dc7872aac7ca2614543344389a1e933f687b1d Mon Sep 17 00:00:00 2001 From: Anthony Roussel Date: Wed, 20 Mar 2024 10:33:28 +0100 Subject: [PATCH 4/4] exiftool: 12.70 -> 12.80 https://github.com/exiftool/exiftool/compare/12.70...12.80 --- pkgs/development/perl-modules/ImageExifTool/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/perl-modules/ImageExifTool/default.nix b/pkgs/development/perl-modules/ImageExifTool/default.nix index 54ff6c9b2a04..b9426f57fe11 100644 --- a/pkgs/development/perl-modules/ImageExifTool/default.nix +++ b/pkgs/development/perl-modules/ImageExifTool/default.nix @@ -10,11 +10,11 @@ buildPerlPackage rec { pname = "Image-ExifTool"; - version = "12.70"; + version = "12.80"; src = fetchurl { url = "https://exiftool.org/Image-ExifTool-${version}.tar.gz"; - hash = "sha256-TLJSJEXMPj870TkExq6uraX8Wl4kmNerrSlX3LQsr/4="; + hash = "sha256-k9UinWyy++gGSTK9H1Pht81FH4hDzG7uZSBSjLLVeQY="; }; nativeBuildInputs = lib.optional stdenv.isDarwin shortenPerlShebang;