unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH 1/1] gnu: add feh
  2014-10-05  6:04 [PATCH 0/1] gnu: add feh Ian Denhardt
@ 2014-10-05  3:32 ` Ian Denhardt
  2014-10-05  8:18   ` Alex Kost
  0 siblings, 1 reply; 7+ messages in thread
From: Ian Denhardt @ 2014-10-05  3:32 UTC (permalink / raw)
  To: guix-devel

* gnu/packages/feh.scm: New File
---
 gnu-system.am        |  1 +
 gnu/packages/feh.scm | 40 ++++++++++++++++++++++++++++++++++++++++
 2 files changed, 41 insertions(+)
 create mode 100644 gnu/packages/feh.scm

diff --git a/gnu-system.am b/gnu-system.am
index 94d8624..302e88f 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -79,6 +79,7 @@ GNU_SYSTEM_MODULES =				\
   gnu/packages/elf.scm				\
   gnu/packages/emacs.scm			\
   gnu/packages/enchant.scm			\
+  gnu/packages/feh.scm                          \
   gnu/packages/file.scm				\
   gnu/packages/fish.scm				\
   gnu/packages/flashing-tools.scm		\
diff --git a/gnu/packages/feh.scm b/gnu/packages/feh.scm
new file mode 100644
index 0000000..a5d5911
--- /dev/null
+++ b/gnu/packages/feh.scm
@@ -0,0 +1,40 @@
+(define-module (gnu packages feh)
+  #:use-module (gnu packages)
+  #:use-module (gnu packages image)
+  #:use-module (gnu packages curl)
+  #:use-module (gnu packages xorg)
+  #:use-module (guix packages)
+  #:use-module (guix download)
+  #:use-module (guix build-system gnu)
+  #:use-module (guix licenses))
+
+(define-public feh
+  (package
+    (name "feh")
+    (version "2.12")
+    (home-page "https://feh.finalrewind.org/")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append home-page
+                                  name "-" version  ".tar.bz2"))
+              (sha256 (base32
+                "0ckhidmsms2l5jycp0qf71jzmb3bpbhjq3bcgfpvfvszah7pmq30"))))
+    (build-system gnu-build-system)
+    (arguments 
+      '(#:phases (alist-delete 'configure %standard-phases)
+        #:tests? #f
+        #:make-flags
+          (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))))
+    (inputs `(("imlib2" ,imlib2)
+              ("curl" ,curl)
+              ("libpng" ,libpng)
+              ("libxt" ,libxt)
+              ("libx11" ,libx11)
+              ("libxinerama" ,libxinerama)))
+    (synopsis "Fast and light imlib2-based image viewer")
+    (description (string-append
+                   "feh is an X11 image viewer aimed mostly at console users. "
+                   "Unlike most other viewers, it does not have a fancy GUI, "
+                   "but simply displays images. It is controlled via "
+                   "commandline arguments and configurable key/mouse actions."))
+    (license x11-style)))
-- 
2.1.2

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

* [PATCH 1/1] gnu: add feh
  2014-10-05 16:06       ` [PATCH 0/1] (updated) " Ian Denhardt
@ 2014-10-05  3:32         ` Ian Denhardt
  2014-10-06  7:59           ` Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: Ian Denhardt @ 2014-10-05  3:32 UTC (permalink / raw)
  To: guix-devel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 3166 bytes --]

* gnu/packages/feh.scm: New File
---
 gnu-system.am        |  1 +
 gnu/packages/feh.scm | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 61 insertions(+)
 create mode 100644 gnu/packages/feh.scm

diff --git a/gnu-system.am b/gnu-system.am
index 94d8624..302e88f 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -79,6 +79,7 @@ GNU_SYSTEM_MODULES =				\
   gnu/packages/elf.scm				\
   gnu/packages/emacs.scm			\
   gnu/packages/enchant.scm			\
+  gnu/packages/feh.scm                          \
   gnu/packages/file.scm				\
   gnu/packages/fish.scm				\
   gnu/packages/flashing-tools.scm		\
diff --git a/gnu/packages/feh.scm b/gnu/packages/feh.scm
new file mode 100644
index 0000000..ca1e5e2
--- /dev/null
+++ b/gnu/packages/feh.scm
@@ -0,0 +1,60 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages feh)
+  #:use-module (gnu packages)
+  #:use-module (gnu packages image)
+  #:use-module (gnu packages curl)
+  #:use-module (gnu packages xorg)
+  #:use-module (guix packages)
+  #:use-module (guix download)
+  #:use-module (guix build-system gnu)
+  #:use-module (guix licenses))
+
+(define-public feh
+  (package
+    (name "feh")
+    (version "2.12")
+    (home-page "https://feh.finalrewind.org/")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append home-page
+                                  name "-" version ".tar.bz2"))
+              (sha256
+               (base32
+                "0ckhidmsms2l5jycp0qf71jzmb3bpbhjq3bcgfpvfvszah7pmq30"))))
+    (build-system gnu-build-system)
+    (arguments
+      '(#:phases (alist-delete 'configure %standard-phases)
+        #:tests? #f
+        #:make-flags
+          (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))))
+    (inputs `(("imlib2" ,imlib2)
+              ("curl" ,curl)
+              ("libpng" ,libpng)
+              ("libxt" ,libxt)
+              ("libx11" ,libx11)
+              ("libxinerama" ,libxinerama)))
+    (synopsis "Fast and light imlib2-based image viewer")
+    (description
+      "feh is an X11 image viewer aimed mostly at console users.
+Unlike most other viewers, it does not have a fancy GUI, but simply
+displays images. It can also be used to set the desktop wallpaper.
+It is controlled via commandline arguments and configurable key/mouse
+actions.")
+    (license x11-style)))
-- 
2.1.2

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

* [PATCH 0/1] gnu: add feh
@ 2014-10-05  6:04 Ian Denhardt
  2014-10-05  3:32 ` [PATCH 1/1] " Ian Denhardt
  0 siblings, 1 reply; 7+ messages in thread
From: Ian Denhardt @ 2014-10-05  6:04 UTC (permalink / raw)
  To: guix-devel

I started this during the hackathon, then got swamped with other things
afterwards, just finished it up now. It was on the wishlist, and I use
it myself.

Ian Denhardt (1):
  gnu: add feh

 gnu-system.am        |  1 +
 gnu/packages/feh.scm | 40 ++++++++++++++++++++++++++++++++++++++++
 2 files changed, 41 insertions(+)
 create mode 100644 gnu/packages/feh.scm

-- 
2.1.2

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

* Re: [PATCH 1/1] gnu: add feh
  2014-10-05  3:32 ` [PATCH 1/1] " Ian Denhardt
@ 2014-10-05  8:18   ` Alex Kost
  2014-10-05 12:31     ` Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: Alex Kost @ 2014-10-05  8:18 UTC (permalink / raw)
  To: Ian Denhardt; +Cc: guix-devel

Hello,

I confirm that the package is built successfully (at least for me).

Several comments:

There should be a header (a comment with author, license, …) in the
beginning of “feh.scm” – see any file in the "gnu/packages" dir.

Ian Denhardt (2014-10-05 07:32 +0400) wrote:

[...]

> +(define-public feh
> +  (package
> +    (name "feh")
> +    (version "2.12")
> +    (home-page "https://feh.finalrewind.org/")
> +    (source (origin
> +              (method url-fetch)
> +              (uri (string-append home-page
> +                                  name "-" version  ".tar.bz2"))

Double space after ‘version’.

> +              (sha256 (base32
> +                "0ckhidmsms2l5jycp0qf71jzmb3bpbhjq3bcgfpvfvszah7pmq30"))))

This is rather unusual indentation.  As for me, I prefer:

(sha256
 (base32
  "0ckhidmsms2l5jycp0qf71jzmb3bpbhjq3bcgfpvfvszah7pmq30"))

People also use:

(sha256 (base32
         "0ckhidmsms2l5jycp0qf71jzmb3bpbhjq3bcgfpvfvszah7pmq30"))

> +    (build-system gnu-build-system)
> +    (arguments 

Remove trailing space here please.

> +      '(#:phases (alist-delete 'configure %standard-phases)
> +        #:tests? #f
> +        #:make-flags
> +          (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))))
> +    (inputs `(("imlib2" ,imlib2)
> +              ("curl" ,curl)
> +              ("libpng" ,libpng)
> +              ("libxt" ,libxt)
> +              ("libx11" ,libx11)
> +              ("libxinerama" ,libxinerama)))
> +    (synopsis "Fast and light imlib2-based image viewer")
> +    (description (string-append
> +                   "feh is an X11 image viewer aimed mostly at console users. "
> +                   "Unlike most other viewers, it does not have a fancy GUI, "
> +                   "but simply displays images. It is controlled via "
> +                   "commandline arguments and configurable key/mouse actions."))

This will make a long one-line description, which is not preferable.
Descriptions should be multi-lined and they usually look like this:

--8<---------------cut here---------------start------------->8---
    (description
     "feh is an X11 image viewer aimed mostly at console users.
Unlike most other viewers, it does not have a fancy GUI, but simply
displays images.  It is controlled via commandline arguments and
configurable key/mouse actions.")
--8<---------------cut here---------------end--------------->8---

Also I think it is worth mentioning (in the description) that feh can
also be used as a wallpaper setter.

-- 
Thanks,
Alex

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

* Re: [PATCH 1/1] gnu: add feh
  2014-10-05  8:18   ` Alex Kost
@ 2014-10-05 12:31     ` Ludovic Courtès
  2014-10-05 16:06       ` [PATCH 0/1] (updated) " Ian Denhardt
  0 siblings, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2014-10-05 12:31 UTC (permalink / raw)
  To: Alex Kost; +Cc: guix-devel

I agree with Alex’s comments.  Ian, could you post an updated patch?

Alex Kost <alezost@gmail.com> skribis:

> Ian Denhardt (2014-10-05 07:32 +0400) wrote:

>> +    (description (string-append
>> +                   "feh is an X11 image viewer aimed mostly at console users. "
>> +                   "Unlike most other viewers, it does not have a fancy GUI, "
>> +                   "but simply displays images. It is controlled via "
>> +                   "commandline arguments and configurable key/mouse actions."))
>
> This will make a long one-line description, which is not preferable.

Indeed.  In addition, it’s important for the description and synopsis to
be a string literal so that it can be picked up by xgettext and subject
to translation.

Ludo’.

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

* [PATCH 0/1] (updated) gnu: add feh
  2014-10-05 12:31     ` Ludovic Courtès
@ 2014-10-05 16:06       ` Ian Denhardt
  2014-10-05  3:32         ` [PATCH 1/1] " Ian Denhardt
  0 siblings, 1 reply; 7+ messages in thread
From: Ian Denhardt @ 2014-10-05 16:06 UTC (permalink / raw)
  To: guix-devel

I've incorporated Alex's comments.

Ian Denhardt (1):
  gnu: add feh

 gnu-system.am        |  1 +
 gnu/packages/feh.scm | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 61 insertions(+)
 create mode 100644 gnu/packages/feh.scm

-- 
2.1.2

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

* Re: [PATCH 1/1] gnu: add feh
  2014-10-05  3:32         ` [PATCH 1/1] " Ian Denhardt
@ 2014-10-06  7:59           ` Ludovic Courtès
  0 siblings, 0 replies; 7+ messages in thread
From: Ludovic Courtès @ 2014-10-06  7:59 UTC (permalink / raw)
  To: Ian Denhardt; +Cc: guix-devel

Ian Denhardt <ian@zenhack.net> skribis:

> * gnu/packages/feh.scm: New File

I pushed the patch with a slightly tweaked commit message (gnu-system.am
was not mentioned) and with:

> +    (license x11-style)))

... this changed to:

+    ;; The license is really the Expat license, with additional wording in the
+    ;; 2nd paragraph: "acknowledgment shall be given in the documentation and
+    ;; software packages that this Software was used."
+    (license (x11-style "file://COPYING"
+                        "See 'COPYING' in the distribution."))))

Because ‘x11-style’ is actually a procedure that returns a license.

Thanks!

Ludo’.

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

end of thread, other threads:[~2014-10-06  7:59 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-05  6:04 [PATCH 0/1] gnu: add feh Ian Denhardt
2014-10-05  3:32 ` [PATCH 1/1] " Ian Denhardt
2014-10-05  8:18   ` Alex Kost
2014-10-05 12:31     ` Ludovic Courtès
2014-10-05 16:06       ` [PATCH 0/1] (updated) " Ian Denhardt
2014-10-05  3:32         ` [PATCH 1/1] " Ian Denhardt
2014-10-06  7:59           ` 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).