aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/lirc.scm
blob: 4c45c0ecb09f35711a25a2117f40845704e657c7 (about) (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2015, 2016 Alex Kost <alezost@gmail.com>
;;;
;;; 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 lirc)
  #:use-module (guix packages)
  #:use-module (guix download)
  #:use-module (guix git-download)
  #:use-module (guix build-system gnu)
  #:use-module (guix build-system python)
  #:use-module ((guix licenses) #:prefix license:)
  #:use-module (gnu packages)
  #:use-module (gnu packages pkg-config)
  #:use-module (gnu packages libusb)
  #:use-module (gnu packages linux)
  #:use-module (gnu packages xml)
  #:use-module (gnu packages xorg)
  #:use-module (gnu packages python))

(define-public lirc
  (package
    (name "lirc")
    (version "0.9.4")
    (source (origin
              (method url-fetch)
              (uri (string-append "mirror://sourceforge/lirc/LIRC/" version
                                  "/lirc-" version ".tar.bz2"))
              (sha256
               (base32
                "1l2xzhnm4hrla51ik09hcafki0y8wnww7svfm7j63zbl2rssc66x"))
              (patches (search-patches "lirc-localstatedir.patch"))))
    (build-system gnu-build-system)
    (arguments
     '(#:configure-flags '("--localstatedir=/var")
       #:phases
       (modify-phases %standard-phases
         (add-after 'unpack 'patch-lirc-make-devinput
           (lambda* (#:key inputs #:allow-other-keys)
             ;; 'lirc-make-devinput' script assumes that linux headers
             ;; are placed in "/usr/...".
             (let ((headers (assoc-ref inputs "linux-headers")))
               (substitute* "tools/lirc-make-devinput"
                 (("/usr/include") (string-append headers "/include"))))
             #t))
         (add-after 'unpack 'patch-doc/Makefile.in
           (lambda _
             ;; Lirc wants to install several images and a useless html page
             ;; to "$(localstatedir)/lib/lirc/".  This makes 'install' phase
             ;; fail as localstatedir is "/var", so do not install these
             ;; files there (the same images are installed in
             ;; "share/doc/lirc/images/" anyway).
             (substitute* "doc/Makefile.in"
               (("^vardocs_DATA =.*") "vardocs_DATA =\n")
               (("^varimage_DATA =.*") "varimage_DATA =\n"))
             #t)))))
    (native-inputs
     `(("pkg-config" ,pkg-config)
       ("libxslt" ,libxslt)))
    (inputs
     `(("libx11" ,libx11)
       ("libusb-compat" ,libusb-compat)
       ("linux-headers" ,linux-libre-headers)
       ("alsa-lib" ,alsa-lib)
       ("python" ,python)))
    (home-page "http://www.lirc.org/")
    (synopsis "Linux Infrared Remote Control")
    (description
     "LIRC allows computers to send and receive IR signals of many commonly
used remote controls.  The most important part of LIRC is the 'lircd' daemon
that decodes IR signals received by the device drivers.  The second daemon
program 'lircmd' allows to translate IR signals to mouse movements.  The
user space applications allow you to control your computer with a remote
control: you can send X events to applications, start programs and much more
on just one button press.")
    (license license:gpl2+)))

(define-public python-lirc
 (let ((commit "4091fe918f3eed2513dad008828565cace408d2f")
       (revision "1"))
  (package
    (name "python-lirc")
    (version (string-append "1.2.1-" revision "." (string-take commit 7)))
    (source
      (origin
        (method git-fetch)
        (uri (git-reference
               (url "https://github.com/tompreston/python-lirc.git")
               (commit commit)))
        (sha256
          (base32
            "0cm47s5pvijfs3v2k7hmpxv3mvp4n5la0ihnsczk5ym3iq166jil"))
        (file-name (string-append name "-" version ".tar.gz"))))
    (build-system python-build-system)
    (inputs
     `(("lirc" ,lirc)))
    (native-inputs
     `(("python-cython" ,python-cython)))
    (arguments
     `(#:tests? #f ; the only tests that exist are human-interactive
       #:phases
        (modify-phases %standard-phases
          (add-before 'build 'build-from-cython-files
            (lambda _
              (zero? (system* "make" "py3")))))))
    (home-page "https://github.com/tompreston/python-lirc")
    (synopsis "Python bindings for LIRC")
    (description "@code{lirc} is a Python module which provides LIRC bindings.")
    (license license:gpl3)
    (properties `((python2-variant . ,(delay python2-lirc)))))))

(define-public python2-lirc
  (let ((base (package-with-python2 (strip-python2-variant python-lirc))))
    (package
      (inherit base)
      (arguments
       `(#:tests? #f ; the only tests there are are human-interactive
         #:phases
          (modify-phases %standard-phases
            (add-before 'build 'build-from-cython-files
              (lambda _
                (zero? (system* "make" "py2")))))))
      (native-inputs
       `(("python2-setuptools" ,python2-setuptools)
         ("python2-cython" ,python2-cython))))))
86855e446e653d958c38b6bbcfc2a24ca'>logplainabout -rw-r--r--autotools.scm15517logplainabout d---------aux-files70logplain -rw-r--r--avahi.scm4583logplainabout -rw-r--r--avr.scm7007logplainabout -rw-r--r--backup.scm24434logplainabout -rw-r--r--base.scm45747logplainabout -rw-r--r--bash.scm16003logplainabout -rw-r--r--bdw-gc.scm4370logplainabout -rw-r--r--benchmark.scm3941logplainabout -rw-r--r--bioinformatics.scm346064logplainabout -rw-r--r--bison.scm2397logplainabout -rw-r--r--bittorrent.scm17137logplainabout -rw-r--r--boost.scm5394logplainabout -rw-r--r--bootloaders.scm13319logplainabout -rw-r--r--bootstrap.scm21215logplainabout d---------bootstrap155logplain -rw-r--r--busybox.scm4082logplainabout -rw-r--r--c.scm6727logplainabout -rw-r--r--calcurse.scm2150logplainabout -rw-r--r--calendar.scm7479logplainabout -rw-r--r--ccache.scm2409logplainabout -rw-r--r--cdrom.scm20795logplainabout -rw-r--r--certs.scm5840logplainabout -rw-r--r--check.scm9079logplainabout -rw-r--r--chez.scm24961logplainabout -rw-r--r--ci.scm11358logplainabout -rw-r--r--cmake.scm5395logplainabout -rw-r--r--code.scm13797logplainabout -rw-r--r--commencement.scm42326logplainabout -rw-r--r--compression.scm46100logplainabout -rw-r--r--compton.scm4189logplainabout -rw-r--r--conkeror.scm3730logplainabout -rw-r--r--conky.scm3189logplainabout -rw-r--r--connman.scm6574logplainabout -rw-r--r--cook.scm3472logplainabout -rw-r--r--cpio.scm2038logplainabout -rw-r--r--cppi.scm1774logplainabout -rw-r--r--cross-base.scm20758logplainabout -rw-r--r--crypto.scm17360logplainabout -rw-r--r--cryptsetup.scm5247logplainabout -rw-r--r--cups.scm19471logplainabout -rw-r--r--curl.scm5692logplainabout -rw-r--r--cyrus-sasl.scm3198logplainabout -rw-r--r--databases.scm59837logplainabout -rw-r--r--datamash.scm1911logplainabout -rw-r--r--datastructures.scm4189logplainabout -rw-r--r--dav.scm4492logplainabout -rw-r--r--dc.scm2176logplainabout -rw-r--r--debug.scm15399logplainabout -rw-r--r--dejagnu.scm3426logplainabout -rw-r--r--dico.scm3281logplainabout -rw-r--r--dictionaries.scm8552logplainabout -rw-r--r--dillo.scm2492logplainabout -rw-r--r--disk.scm12993logplainabout -rw-r--r--display-managers.scm10125logplainabout -rw-r--r--django.scm7587logplainabout -rw-r--r--djvu.scm1710logplainabout -rw-r--r--dns.scm12800logplainabout -rw-r--r--docbook.scm9715logplainabout -rw-r--r--docker.scm3871logplainabout -rw-r--r--documentation.scm7219logplainabout -rw-r--r--dunst.scm2717logplainabout -rw-r--r--dvtm.scm2311logplainabout -rw-r--r--ebook.scm6085logplainabout -rw-r--r--ed.scm2345logplainabout -rw-r--r--education.scm6423logplainabout -rw-r--r--elf.scm5867logplainabout -rw-r--r--elixir.scm4460logplainabout -rw-r--r--emacs.scm153343logplainabout -rw-r--r--embedded.scm30727logplainabout -rw-r--r--enchant.scm2381logplainabout -rw-r--r--engineering.scm33534logplainabout -rw-r--r--enlightenment.scm12591logplainabout -rw-r--r--entr.scm2854logplainabout -rw-r--r--erlang.scm8322logplainabout -rw-r--r--fcitx.scm4722logplainabout -rw-r--r--figlet.scm1797logplainabout -rw-r--r--file.scm2004logplainabout -rw-r--r--finance.scm12151logplainabout -rw-r--r--firmware.scm12533logplainabout -rw-r--r--flashing-tools.scm9691logplainabout -rw-r--r--flex.scm4382logplainabout -rw-r--r--fltk.scm5694logplainabout -rw-r--r--fonts.scm51872logplainabout -rw-r--r--fontutils.scm23836logplainabout -rw-r--r--fpga.scm13373logplainabout -rw-r--r--freedesktop.scm34875logplainabout -rw-r--r--freeipmi.scm2076logplainabout -rw-r--r--fribidi.scm1756logplainabout -rw-r--r--ftp.scm6580logplainabout -rw-r--r--fvwm.scm2509logplainabout -rw-r--r--game-development.scm24911logplainabout -rw-r--r--games.scm130371logplainabout -rw-r--r--gawk.scm3771logplainabout -rw-r--r--gcal.scm1979logplainabout -rw-r--r--gcc.scm37713logplainabout -rw-r--r--gd.scm7382logplainabout -rw-r--r--gdb.scm4579logplainabout -rw-r--r--geo.scm7480logplainabout -rw-r--r--gettext.scm7647logplainabout -rw-r--r--gforth.scm2440logplainabout -rw-r--r--ghostscript.scm13182logplainabout -rw-r--r--gimp.scm9953logplainabout -rw-r--r--gkrellm.scm2394logplainabout -rw-r--r--gl.scm24875logplainabout -rw-r--r--glib.scm30283logplainabout -rw-r--r--gnome.scm230145logplainabout -rw-r--r--gnu-doc.scm4075logplainabout -rw-r--r--gnu-pw-mgr.scm2095logplainabout -rw-r--r--gnucash.scm8149logplainabout -rw-r--r--gnunet.scm15869logplainabout -rw-r--r--gnupg.scm27548logplainabout -rw-r--r--gnustep.scm10477logplainabout -rw-r--r--gnuzilla.scm32968logplainabout -rw-r--r--gobby.scm4896logplainabout -rw-r--r--golang.scm17502logplainabout -rw-r--r--gperf.scm1784logplainabout -rw-r--r--gprolog.scm2560logplainabout -rw-r--r--gps.scm5200logplainabout -rw-r--r--graphics.scm22022logplainabout -rw-r--r--graphviz.scm8169logplainabout -rw-r--r--groff.scm4021logplainabout -rw-r--r--gsasl.scm3960logplainabout -rw-r--r--gstreamer.scm17342logplainabout -rw-r--r--gtk.scm55440logplainabout -rw-r--r--guile-wm.scm6385logplainabout -rw-r--r--guile.scm71854logplainabout -rw-r--r--gv.scm3246logplainabout -rw-r--r--gxmessage.scm2351logplainabout -rw-r--r--haskell.scm298929logplainabout -rw-r--r--hexedit.scm1892logplainabout -rw-r--r--hugs.scm3671logplainabout -rw-r--r--hurd.scm7916logplainabout -rw-r--r--ibus.scm11408logplainabout -rw-r--r--icu4c.scm2911logplainabout -rw-r--r--idris.scm11212logplainabout -rw-r--r--idutils.scm2088logplainabout -rw-r--r--image-viewers.scm10493logplainabout -rw-r--r--image.scm45117logplainabout -rw-r--r--imagemagick.scm9429logplainabout -rw-r--r--indent.scm2384logplainabout -rw-r--r--inklingreader.scm2239logplainabout -rw-r--r--inkscape.scm3050logplainabout -rw-r--r--irc.scm16814logplainabout -rw-r--r--iso-codes.scm2663logplainabout -rw-r--r--java.scm54739logplainabout -rw-r--r--jemalloc.scm1806logplainabout -rw-r--r--jrnl.scm2238logplainabout -rw-r--r--julia.scm15070logplainabout -rw-r--r--kde-frameworks.scm107697logplainabout -rw-r--r--kde.scm13730logplainabout -rw-r--r--kerberos.scm7530logplainabout -rw-r--r--key-mon.scm2079logplainabout -rw-r--r--kodi.scm11238logplainabout -rw-r--r--language.scm16380logplainabout -rw-r--r--ld-wrapper.in9597logplainabout -rw-r--r--ldc.scm13134logplainabout -rw-r--r--lego.scm2804logplainabout -rw-r--r--less.scm1883