guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCHES] gnu: netpbm: Move man pages to share/man


From: Mark H Weaver
Subject: [PATCHES] gnu: netpbm: Move man pages to share/man
Date: Thu, 20 Mar 2014 04:46:39 -0400

These patches are ultimately aimed at simply installing the man pages
for netpbm in PREFIX/share/man instead of PREFIX/man.  I also noticed
that the recipe is indented in such a way that is quite misleading, and
that its install phase could be simplified.

* The first patch is purely whitespace changes.

* The second patch simplifies the install phase without changing its
  behavior.

* The third patch moves 'man' to 'share/man'.

I also noticed that the man pages 'netpbm' installs are merely pointers
to the web site.  The documentation is not distributed in the tarball at
all, and there is apparently no way to get an immutable copy of the
documentation corresponding to the tarball without fetching a particular
revision from a subversion repository.

They install a program called 'manweb' that launches a web browser.
It finds the URL in a rather gross way: by looking for a file called
'doc.url' in $PATH, which it helpfully installs in PREFIX/bin.  Ugh.

Anyway, here are the patches that at least improve things somewhat.

     Mark

Attachment: 0001-gnu-netpbm-Reindent-recipe.patch
Description: [PATCH 1/3] gnu: netpbm: Reindent recipe

>From c2e645e739ab8a75ef41c07c1303b97938d82f60 Mon Sep 17 00:00:00 2001
From: Mark H Weaver <address@hidden>
Date: Thu, 20 Mar 2014 04:15:53 -0400
Subject: [PATCH 2/3] gnu: netpbm: Use 'with-directory-excursion' to simplify
 install phase.

* gnu/packages/netpbm.scm (netpbm): In install phase, move the 'copy-file' and
  'system*' calls within the 'make-directory-excursion' to simplify the code.
---
 gnu/packages/netpbm.scm | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/gnu/packages/netpbm.scm b/gnu/packages/netpbm.scm
index 5875a93..20b4bd7 100644
--- a/gnu/packages/netpbm.scm
+++ b/gnu/packages/netpbm.scm
@@ -1,5 +1,6 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2013 Andreas Enge <address@hidden>
+;;; Copyright © 2014 Mark H Weaver <address@hidden>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -107,13 +108,12 @@
               (apply system* "make" "package"
                      (string-append "pkgdir=" out)
                      make-flags)
-              ;; copy static library
-              (copy-file (string-append out "/link/libnetpbm.a")
-                         (string-append out "/lib/libnetpbm.a"))
-              ;; remove superfluous folders and files
-              (system* "rm" "-r" (string-append out "/link"))
-              (system* "rm" "-r" (string-append out "/misc"))
               (with-directory-excursion out
+                ;; copy static library
+                (copy-file "link/libnetpbm.a" "lib/libnetpbm.a")
+                ;; remove superfluous folders and files
+                (system* "rm" "-r" "link")
+                (system* "rm" "-r" "misc")
                 (for-each delete-file
                           '("config_template" "pkginfo" "README" "VERSION")))))
           %standard-phases)))))
-- 
1.8.4

>From 5aeb0ad06c7fb69d7a87c29cbb71e65b6a6bac29 Mon Sep 17 00:00:00 2001
From: Mark H Weaver <address@hidden>
Date: Thu, 20 Mar 2014 04:18:50 -0400
Subject: [PATCH 3/3] gnu: netpbm: Move man pages to share/man.

* gnu/packages/netpbm.scm (netpbm): In install phase, move the
  man pages to share/man.
---
 gnu/packages/netpbm.scm | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/gnu/packages/netpbm.scm b/gnu/packages/netpbm.scm
index 20b4bd7..6eb1a47 100644
--- a/gnu/packages/netpbm.scm
+++ b/gnu/packages/netpbm.scm
@@ -114,6 +114,8 @@
                 ;; remove superfluous folders and files
                 (system* "rm" "-r" "link")
                 (system* "rm" "-r" "misc")
+                (mkdir "share")
+                (rename-file "man" "share/man")
                 (for-each delete-file
                           '("config_template" "pkginfo" "README" "VERSION")))))
           %standard-phases)))))
-- 
1.8.4


reply via email to

[Prev in Thread] Current Thread [Next in Thread]