unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#31494] [PATCH] gnu: gifsicle: New variable.
@ 2018-05-18 15:00 Pierre Neidhardt
  2018-05-19 20:46 ` Ludovic Courtès
  0 siblings, 1 reply; 4+ messages in thread
From: Pierre Neidhardt @ 2018-05-18 15:00 UTC (permalink / raw)
  To: 31494

* gnu/packages/image.scm (gifsicle): New variable.
---
 gnu/packages/image.scm | 51 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 51 insertions(+)

diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index bbfd621a9..ef97df7c7 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -1366,3 +1366,54 @@ Features:
 images stored in the JPEG format with R.  It can read and write both files and
 in-memory raw vectors.")
    (license license:gpl2+)))
+
+(define-public gifsicle
+  (package
+   (name "gifsicle")
+   (version "1.91")
+   (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "http://www.lcdf.org/gifsicle/gifsicle-"
+                           version ".tar.gz"))
+       (sha256
+        (base32
+         "00586z1yz86qcblgmf16yly39n4lkjrscl52hvfxqk14m81fckha"))))
+   (build-system gnu-build-system)
+   ;; TODO: Tests fail with "undefined error at undefined point in script".
+   ;; They pass when run manually with
+   ;;   guix environment gifsicle -- ./test/testie -p src/ test/
+   (arguments '(#:tests? #f))
+   ;; (arguments
+   ;;  '(#:phases
+   ;;    (modify-phases %standard-phases
+   ;;      (add-before 'check 'patch-tests
+   ;;        (lambda _
+   ;;          (substitute* "test/testie"
+   ;;            (("/usr/bin/perl")
+   ;;             (which "perl"))
+   ;;            (("/bin/rm")
+   ;;             (which "rm"))))))))
+   ;; (native-inputs `(("perl" ,perl))) ; Only for tests.
+   (inputs `(("libx11" ,libx11)))
+   (home-page "http://www.lcdf.org/gifsicle/")
+   (synopsis "Create, edit, manipulate and get information about GIF images and animations")
+   (description "Some Gifsicle features:
+- Batch mode for changing GIFs in place.
+- Prints detailed information about GIFs, including comments.
+- Control over interlacing, comments, looping, transparency...
+- Creates well-behaved GIFs: removes redundant colors, only uses local color
+tables if it absolutely has to (local color tables waste space and can cause
+viewing artifacts), etc.
+- It can shrink colormaps and change images to use the Web-safe palette (or
+any colormap you choose).
+- Optimize your animations! This stores only the changed portion of each
+frame, and can radically shrink your GIFs. You can also use transparency to
+make them even smaller. Gifsicle's optimizer is pretty powerful, and usually
+reduces animations to within a couple bytes of the best commercial optimizers.
+- Unoptimizing animations, which makes them easier to edit.
+
+Two other programs are included with Gifsicle: @code{gifview} is a lightweight
+animated-GIF viewer which can show animations as slideshows or in real time,
+and @code{gifdiff} compares two GIFs for identical visual appearance. ")
+   (license license:gpl2+)))
-- 
2.17.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#31494] [PATCH] gnu: gifsicle: New variable.
  2018-05-18 15:00 [bug#31494] [PATCH] gnu: gifsicle: New variable Pierre Neidhardt
@ 2018-05-19 20:46 ` Ludovic Courtès
  2018-05-20 12:09   ` Pierre Neidhardt
  0 siblings, 1 reply; 4+ messages in thread
From: Ludovic Courtès @ 2018-05-19 20:46 UTC (permalink / raw)
  To: Pierre Neidhardt; +Cc: 31494

Hi,

Pierre Neidhardt <ambrevar@gmail.com> skribis:

> * gnu/packages/image.scm (gifsicle): New variable.

Copyright line please.  :-)

> +   (build-system gnu-build-system)
> +   ;; TODO: Tests fail with "undefined error at undefined point in script".
> +   ;; They pass when run manually with
> +   ;;   guix environment gifsicle -- ./test/testie -p src/ test/
> +   (arguments '(#:tests? #f))
> +   ;; (arguments
> +   ;;  '(#:phases
> +   ;;    (modify-phases %standard-phases
> +   ;;      (add-before 'check 'patch-tests
> +   ;;        (lambda _
> +   ;;          (substitute* "test/testie"
> +   ;;            (("/usr/bin/perl")
> +   ;;             (which "perl"))
> +   ;;            (("/bin/rm")
> +   ;;             (which "rm"))))))))
> +   ;; (native-inputs `(("perl" ,perl))) ; Only for tests.

Could the test failures be caused by other hardcoded file names (like
“/bin/sh”)?  If they pass in ’guix environment’ that may well be the
reason.

> +   (inputs `(("libx11" ,libx11)))
> +   (home-page "http://www.lcdf.org/gifsicle/")
> +   (synopsis "Create, edit, manipulate and get information about GIF images and animations")

To shorten a bit, what about: “Edit GIF images and animations”?

> +   (description "Some Gifsicle features:
> +- Batch mode for changing GIFs in place.
> +- Prints detailed information about GIFs, including comments.
> +- Control over interlacing, comments, looping, transparency...
> +- Creates well-behaved GIFs: removes redundant colors, only uses local color
> +tables if it absolutely has to (local color tables waste space and can cause
> +viewing artifacts), etc.
> +- It can shrink colormaps and change images to use the Web-safe palette (or
> +any colormap you choose).
> +- Optimize your animations! This stores only the changed portion of each
> +frame, and can radically shrink your GIFs. You can also use transparency to
> +make them even smaller. Gifsicle's optimizer is pretty powerful, and usually
> +reduces animations to within a couple bytes of the best commercial optimizers.
> +- Unoptimizing animations, which makes them easier to edit.
> +
> +Two other programs are included with Gifsicle: @code{gifview} is a lightweight
> +animated-GIF viewer which can show animations as slideshows or in real time,
> +and @code{gifdiff} compares two GIFs for identical visual appearance. ")

Please @itemize and full sentences.

Could you send an updated patch?

Thank you!

Ludo’.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#31494] [PATCH] gnu: gifsicle: New variable.
  2018-05-19 20:46 ` Ludovic Courtès
@ 2018-05-20 12:09   ` Pierre Neidhardt
  2018-05-26 20:22     ` bug#31494: " Ludovic Courtès
  0 siblings, 1 reply; 4+ messages in thread
From: Pierre Neidhardt @ 2018-05-20 12:09 UTC (permalink / raw)
  To: 31494

[-- Attachment #1: Type: text/plain, Size: 3060 bytes --]


* gnu/packages/image.scm (gifsicle): New variable.
---
 gnu/packages/image.scm | 52 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 52 insertions(+)

diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index bbfd621a9..174e47bca 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -17,6 +17,7 @@
 ;;; Copyright © 2017 Hartmut Goebel <h.goebel@crazy-compilers.com>
 ;;; Copyright © 2017 Julien Lepiller <julien@lepiller.eu>
 ;;; Copyright © 2018 Joshua Sierles, Nextjournal <joshua@nextjournal.com>
+;;; Copyright © 2018 Pierre Neidhardt <ambrevar@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1366,3 +1367,54 @@ Features:
 images stored in the JPEG format with R.  It can read and write both files and
 in-memory raw vectors.")
    (license license:gpl2+)))
+
+(define-public gifsicle
+  (package
+   (name "gifsicle")
+   (version "1.91")
+   (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "http://www.lcdf.org/gifsicle/gifsicle-"
+                           version ".tar.gz"))
+       (sha256
+        (base32
+         "00586z1yz86qcblgmf16yly39n4lkjrscl52hvfxqk14m81fckha"))))
+   (build-system gnu-build-system)
+   (arguments
+    '(#:phases
+      (modify-phases %standard-phases
+        (add-before 'check 'patch-tests
+          (lambda _
+            (substitute* "test/testie"
+              (("/usr/bin/perl")
+               (which "perl"))
+              (("/bin/sh")
+               (which "sh"))
+              (("/bin/rm")
+               (which "rm"))))))))
+   (native-inputs `(("perl" ,perl))) ; Only for tests.
+   (inputs `(("libx11" ,libx11)))
+   (home-page "http://www.lcdf.org/gifsicle/")
+   (synopsis "Edit GIF images and animations")
+   (description "Gifsicle is a commandline GIF swiss-army knife.  Features:
+@itemize
+@item Batch mode for changing GIFs in place.
+@item Prints detailed information about GIFs, including comments.
+@item Control over interlacing, comments, looping, transparency...
+@item Creates well-behaved GIFs: removes redundant colors, only uses local color
+tables if it absolutely has to (local color tables waste space and can cause
+viewing artifacts), etc.
+@item It can shrink colormaps and change images to use the Web-safe palette (or
+any colormap you choose).
+@item Optimize your animations!  This stores only the changed portion of each
+frame, and can radically shrink your GIFs.  You can also use transparency to
+make them even smaller.  Gifsicle's optimizer is pretty powerful, and usually
+reduces animations to within a couple bytes of the best commercial optimizers.
+@item Unoptimizing animations, which makes them easier to edit.
+@end itemize
+
+Two other programs are included with Gifsicle: @code{gifview} is a lightweight
+animated-GIF viewer which can show animations as slideshows or in real time,
+and @code{gifdiff} compares two GIFs for identical visual appearance.")
+   (license license:gpl2+)))
-- 
2.17.0


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* bug#31494: [PATCH] gnu: gifsicle: New variable.
  2018-05-20 12:09   ` Pierre Neidhardt
@ 2018-05-26 20:22     ` Ludovic Courtès
  0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2018-05-26 20:22 UTC (permalink / raw)
  To: Pierre Neidhardt; +Cc: 31494-done

[-- Attachment #1: Type: text/plain, Size: 272 bytes --]

Pierre Neidhardt <ambrevar@gmail.com> skribis:

> * gnu/packages/image.scm (gifsicle): New variable.

Applied with the minor changes below, in line with
<https://www.gnu.org/software/guix/manual/html_node/Synopses-and-Descriptions.html>.

Thank you!

Ludo’.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 2332 bytes --]

diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index 752815c58..d6c39e5c7 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -1426,29 +1426,25 @@ in-memory raw vectors.")
               (("/bin/sh")
                (which "sh"))
               (("/bin/rm")
-               (which "rm"))))))))
+               (which "rm")))
+            #t)))))
    (native-inputs `(("perl" ,perl))) ; Only for tests.
    (inputs `(("libx11" ,libx11)))
    (home-page "http://www.lcdf.org/gifsicle/")
    (synopsis "Edit GIF images and animations")
-   (description "Gifsicle is a commandline GIF swiss-army knife.  Features:
+   (description "Gifsicle is a command-line GIF image manipulation tool that:
+
 @itemize
-@item Batch mode for changing GIFs in place.
+@item Provides a batch mode for changing GIFs in place.
 @item Prints detailed information about GIFs, including comments.
-@item Control over interlacing, comments, looping, transparency...
+@item Control over interlacing, comments, looping, transparency, etc.
 @item Creates well-behaved GIFs: removes redundant colors, only uses local color
-tables if it absolutely has to (local color tables waste space and can cause
-viewing artifacts), etc.
-@item It can shrink colormaps and change images to use the Web-safe palette (or
-any colormap you choose).
-@item Optimize your animations!  This stores only the changed portion of each
-frame, and can radically shrink your GIFs.  You can also use transparency to
-make them even smaller.  Gifsicle's optimizer is pretty powerful, and usually
-reduces animations to within a couple bytes of the best commercial optimizers.
-@item Unoptimizing animations, which makes them easier to edit.
+tables, etc.
+@item Shrinks colormaps and change images to use the Web-safe palette.
+@item Optimizes GIF animations, or unoptimizes them for easier editing.
 @end itemize
 
-Two other programs are included with Gifsicle: @code{gifview} is a lightweight
-animated-GIF viewer which can show animations as slideshows or in real time,
-and @code{gifdiff} compares two GIFs for identical visual appearance.")
+Two other programs are included with Gifsicle: @command{gifview} is a
+lightweight animated-GIF viewer, and @command{gifdiff} compares two GIFs for
+identical visual appearance.")
    (license license:gpl2+)))

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-05-26 20:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-05-18 15:00 [bug#31494] [PATCH] gnu: gifsicle: New variable Pierre Neidhardt
2018-05-19 20:46 ` Ludovic Courtès
2018-05-20 12:09   ` Pierre Neidhardt
2018-05-26 20:22     ` bug#31494: " Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).