Merge branch 'master' into core-updates
[jackhill/guix/guix.git] / gnu / packages / indent.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
4 ;;;
5 ;;; This file is part of GNU Guix.
6 ;;;
7 ;;; GNU Guix is free software; you can redistribute it and/or modify it
8 ;;; under the terms of the GNU General Public License as published by
9 ;;; the Free Software Foundation; either version 3 of the License, or (at
10 ;;; your option) any later version.
11 ;;;
12 ;;; GNU Guix is distributed in the hope that it will be useful, but
13 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
14 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 ;;; GNU General Public License for more details.
16 ;;;
17 ;;; You should have received a copy of the GNU General Public License
18 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19
20 (define-module (gnu packages indent)
21 #:use-module (gnu packages)
22 #:use-module ((guix licenses)
23 #:renamer (symbol-prefix-proc 'license:))
24 #:use-module (guix packages)
25 #:use-module (guix download)
26 #:use-module (guix build-system gnu))
27
28 (define-public indent
29 (package
30 (name "indent")
31 (version "2.2.10")
32 (source (origin
33 (method url-fetch)
34 (uri (string-append "mirror://gnu/indent/indent-" version
35 ".tar.gz"))
36 (sha256 (base32
37 "0f9655vqdvfwbxvs1gpa7py8k1z71aqh8hp73f65vazwbfz436wa"))))
38 (build-system gnu-build-system)
39 (arguments
40 `(#:phases (alist-cons-after
41 'unpack 'fix-docdir
42 (lambda _
43 ;; Although indent uses a modern autoconf in which docdir
44 ;; defaults to PREFIX/share/doc, the doc/Makefile.am
45 ;; overrides this to be in PREFIX/doc. Fix this.
46 (substitute* "doc/Makefile.in"
47 (("^docdir = .*$") "docdir = @docdir@\n")))
48 %standard-phases)))
49 (synopsis "Code reformatter")
50 (description
51 "Indent is a program that makes source code easier to read by
52 reformatting it in a consistent style. It can change the style to one of
53 several different styles such as GNU, BSD or K&R. It has some flexibility to
54 deal with incomplete or malformed syntax. GNU indent offers several
55 extensions over the standard utility.")
56 (license license:gpl3+)
57 (home-page "http://www.gnu.org/software/indent/")))