gnu: nnn: Don't use NAME in source URI.
[jackhill/guix/guix.git] / gnu / packages / conky.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Siniša Biđin <sinisa@bidin.eu>
3 ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
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 conky)
21 #:use-module (guix packages)
22 #:use-module (guix utils)
23 #:use-module (guix download)
24 #:use-module (guix git-download)
25 #:use-module (guix build-system cmake)
26 #:use-module ((guix licenses) #:prefix license:)
27 #:use-module (gnu packages fontutils)
28 #:use-module (gnu packages image)
29 #:use-module (gnu packages lua)
30 #:use-module (gnu packages ncurses)
31 #:use-module (gnu packages pkg-config)
32 #:use-module (gnu packages xorg))
33
34 (define-public conky
35 (package
36 (name "conky")
37 (version "1.10.8")
38 (source
39 (origin
40 (method url-fetch)
41 (uri (string-append "https://github.com/brndnmtthws/conky/archive/v"
42 version ".tar.gz"))
43 (file-name (string-append name "-" version ".tar.gz"))
44 (sha256
45 (base32 "0mw8xbnxr0a7yq2smzi2nln2b5n0q571vdrq6mhvs5n84xd6bg9f"))))
46 (build-system cmake-build-system)
47 (arguments
48 `(#:tests? #f ; there are no tests
49 #:configure-flags
50 (list "-DRELEASE=true")
51 #:phases
52 (modify-phases %standard-phases
53 (add-after 'unpack 'add-freetype-to-search-path
54 (lambda* (#:key inputs #:allow-other-keys)
55 (substitute* "cmake/ConkyPlatformChecks.cmake"
56 (("set\\(INCLUDE_SEARCH_PATH")
57 (string-append
58 "set(INCLUDE_SEARCH_PATH "
59 (assoc-ref inputs "freetype") "/include/freetype2 ")))
60 #t))
61 (replace 'install
62 (lambda* (#:key outputs #:allow-other-keys)
63 (let* ((out (assoc-ref outputs "out"))
64 (bin (string-append out "/bin")))
65 (install-file "src/conky" bin))
66 #t)))))
67 (inputs
68 `(("freetype" ,freetype)
69 ("imlib2" ,imlib2)
70 ("libx11" ,libx11)
71 ("libxdamage" ,libxdamage)
72 ("libxext" ,libxext)
73 ("libxft" ,libxft)
74 ("libxinerama" ,libxinerama)
75 ("lua" ,lua)
76 ("ncurses" ,ncurses)))
77 (native-inputs
78 `(("pkg-config" ,pkg-config)))
79 (home-page "https://github.com/brndnmtthws/conky")
80 (synopsis "Lightweight system monitor for X")
81 (description
82 "Conky is a lightweight system monitor for X that displays operating
83 system statistics (CPU, disk, and memory usage, etc.) and more on the
84 desktop.")
85 (license license:gpl3+)))