GNU bug report logs - #66652
[PATCH] gnu: Add findimagedupes.

Previous Next

Package: guix-patches;

Reported by: Morgan Smith <Morgan.J.Smith <at> outlook.com>

Date: Fri, 20 Oct 2023 18:04:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 66652 in the body.
You can then email your comments to 66652 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#66652; Package guix-patches. (Fri, 20 Oct 2023 18:04:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Morgan Smith <Morgan.J.Smith <at> outlook.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Fri, 20 Oct 2023 18:04:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Morgan Smith <Morgan.J.Smith <at> outlook.com>
To: guix-patches <at> gnu.org
Subject: [PATCH] gnu: Add findimagedupes.
Date: Fri, 20 Oct 2023 13:55:53 -0400
* gnu/packages/disk.scm (findimagedupes): New variable.
---
 gnu/packages/disk.scm | 59 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 59 insertions(+)

diff --git a/gnu/packages/disk.scm b/gnu/packages/disk.scm
index 9d2e170cc0..113455eee5 100644
--- a/gnu/packages/disk.scm
+++ b/gnu/packages/disk.scm
@@ -26,6 +26,7 @@
 ;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
 ;;; Copyright © 2022 Disseminate Dissent <disseminatedissent <at> protonmail.com>
 ;;; Copyright © 2023 Timotej Lazar <timotej.lazar <at> araneo.si>
+;;; Copyright © 2023 Morgan Smith <Morgan.J.Smith <at> outlook.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -61,6 +62,7 @@ (define-module (gnu packages disk)
   #:use-module (gnu packages file-systems)
   #:use-module (gnu packages file)
   #:use-module (gnu packages fontutils)
+  #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages gettext)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages gnome)
@@ -71,6 +73,7 @@ (define-module (gnu packages disk)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages hurd)
   #:use-module (gnu packages image)
+  #:use-module (gnu packages imagemagick)
   #:use-module (gnu packages linux)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages nss)
@@ -102,6 +105,7 @@ (define-module (gnu packages disk)
   #:use-module (guix build-system glib-or-gtk)
   #:use-module (guix build-system go)
   #:use-module (guix build-system meson)
+  #:use-module (guix build-system perl)
   #:use-module (guix build-system python)
   #:use-module (guix build-system trivial)
   #:use-module (guix build-system scons)
@@ -343,6 +347,61 @@ (define-public fdisk
 tables, and it understands a variety of different formats.")
     (license license:gpl3+)))
 
+(define-public findimagedupes
+  (package
+    (name "findimagedupes")
+    (version "2.20.1")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/jhnc/findimagedupes")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "1zfxmc6c1z4hzsq3k85xxida1v291frq4wbmxv9cg4jmw0ddk5ic"))))
+    (build-system perl-build-system)
+    (arguments
+     (list
+      #:tests? #f
+      #:phases #~(modify-phases %standard-phases
+                   (delete 'configure)
+                   (delete 'build)
+                   (replace 'install
+                     ;; There's no ‘make install’ target.
+                     (lambda* (#:key outputs #:allow-other-keys)
+                       (install-file "findimagedupes"
+                                     (string-append #$output "/bin"))))
+                   (add-after 'unpack 'use-image-magick
+                     ;; TODO: package perl-graphics-magick and switch this out
+                     (lambda _
+                       (substitute* "findimagedupes"
+                         (("Graphics::Magick")
+                          "Image::Magick"))))
+                   (add-after 'unpack 'set-inline-dir
+                     (lambda _
+                       (substitute* "findimagedupes"
+                         (("/usr/local")
+                          #$output))))
+                   (add-after 'install 'inline-generation
+                     (lambda _
+                       (mkdir-p (string-append #$output "/lib/findimagedupes"))
+                       (invoke (string-append #$output "/bin/findimagedupes"))))
+                   (add-after 'install 'wrap-findimagedupes
+                     (lambda* (#:key outputs #:allow-other-keys)
+                       (wrap-program (string-append #$output
+                                                    "/bin/findimagedupes")
+                         `("PERL5LIB" ":" prefix
+                           (,(getenv "PERL5LIB") ,(string-append #$output
+                                                   "/lib/perl5/site_perl")))))))))
+    (inputs (list bash-minimal perl-db-file perl-file-mimeinfo
+                  perl-image-magick perl-inline-c))
+    (home-page "https://github.com/jhnc/findimagedupes")
+    (synopsis "Find visually similar or duplicate images")
+    (description "findimagedupes compares a list of files for visual
+similarity.")
+    (license license:gpl3+)))
+
 (define-public gpart
   ;; The latest (0.3) release is from 2015 and is missing a crash fix.
   (let ((commit "ec03350a01ad69708b5a3e2d47b8e002b0eba6c9")
--
2.41.0





Reply sent to Ludovic Courtès <ludo <at> gnu.org>:
You have taken responsibility. (Wed, 22 Nov 2023 14:51:01 GMT) Full text and rfc822 format available.

Notification sent to Morgan Smith <Morgan.J.Smith <at> outlook.com>:
bug acknowledged by developer. (Wed, 22 Nov 2023 14:51:01 GMT) Full text and rfc822 format available.

Message #10 received at 66652-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Morgan Smith <Morgan.J.Smith <at> outlook.com>
Cc: 66652-done <at> debbugs.gnu.org
Subject: Re: [bug#66652] [PATCH] gnu: Add findimagedupes.
Date: Wed, 22 Nov 2023 15:49:55 +0100
Morgan Smith <Morgan.J.Smith <at> outlook.com> skribis:

> * gnu/packages/disk.scm (findimagedupes): New variable.

Applied, thanks!

Ludo’.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 21 Dec 2023 12:24:10 GMT) Full text and rfc822 format available.

This bug report was last modified 1 year and 140 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.