gnu: libdvdcss: Update to 1.4.3.
[jackhill/guix/guix.git] / gnu / packages / screen.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
3 ;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
4 ;;; Copyright © 2015, 2017 Eric Bavier <bavier@member.fsf.org>
5 ;;; Copyright © 2016, 2017, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
6 ;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
7 ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
8 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
9 ;;;
10 ;;; This file is part of GNU Guix.
11 ;;;
12 ;;; GNU Guix is free software; you can redistribute it and/or modify it
13 ;;; under the terms of the GNU General Public License as published by
14 ;;; the Free Software Foundation; either version 3 of the License, or (at
15 ;;; your option) any later version.
16 ;;;
17 ;;; GNU Guix is distributed in the hope that it will be useful, but
18 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
19 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ;;; GNU General Public License for more details.
21 ;;;
22 ;;; You should have received a copy of the GNU General Public License
23 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
24
25 (define-module (gnu packages screen)
26 #:use-module (guix licenses)
27 #:use-module (guix packages)
28 #:use-module (guix download)
29 #:use-module (guix git-download)
30 #:use-module (guix build-system gnu)
31 #:use-module (gnu packages)
32 #:use-module (gnu packages hurd)
33 #:use-module (gnu packages ncurses)
34 #:use-module (gnu packages perl)
35 #:use-module (gnu packages python)
36 #:use-module (gnu packages slang)
37 #:use-module (gnu packages texinfo))
38
39 (define-public screen
40 (package
41 (name "screen")
42 (version "4.8.0")
43 (source (origin
44 (method url-fetch)
45 (uri (string-append "mirror://gnu/screen/screen-"
46 version ".tar.gz"))
47 (patches (search-patches "screen-hurd-path-max.patch"
48 "screen-CVE-2021-26937.patch"))
49 (sha256
50 (base32 "18ascpjzsy70h6hk7wpg8zmzjwgdyrdr7c6z4pg5z4l9hhyv24bf"))))
51 (build-system gnu-build-system)
52 (native-inputs
53 `(("makeinfo" ,texinfo)))
54 (inputs
55 `(("ncurses" ,ncurses)
56 ("perl" ,perl)))
57 (arguments
58 `(#:configure-flags
59 ;; By default, screen supports 16 colors, but we want 256 when
60 ;; ~/.screenrc contains 'term xterm-256color'.
61 '("--enable-colors256")))
62 (home-page "https://www.gnu.org/software/screen/")
63 (synopsis "Full-screen window manager providing multiple terminals")
64 (description
65 "GNU Screen is a terminal window manager that multiplexes a single
66 terminal between several processes. The virtual terminals each provide
67 features such as a scroll-back buffer and a copy-and-paste mechanism. Screen
68 then manages the different virtual terminals, allowing you to easily switch
69 between them, to detach them from the current session, or even splitting the
70 view to show two terminals at once.")
71 (license gpl2+)))
72
73 (define-public dtach
74 (package
75 (name "dtach")
76 (version "0.9")
77 (source (origin
78 (method url-fetch)
79 (uri (string-append "mirror://sourceforge/" name "/" name "/"
80 version "/" name "-" version ".tar.gz"))
81 (sha256
82 (base32
83 "1wwj2hlngi8qn2pisvhyfxxs8gyqjlgrrv5lz91w8ly54dlzvs9j"))))
84 (build-system gnu-build-system)
85 (arguments
86 ;; No install target.
87 '(#:phases
88 (modify-phases %standard-phases
89 (replace 'install
90 (lambda* (#:key outputs #:allow-other-keys)
91 (let ((out (assoc-ref outputs "out")))
92 (install-file "dtach" (string-append out "/bin"))
93 (install-file "dtach.1" (string-append out "/share/man/man1"))
94 #t))))
95 ;; No check target.
96 #:tests? #f))
97 (home-page "http://dtach.sourceforge.net/")
98 (synopsis "Emulates the detach feature of screen")
99 (description
100 "dtach is a tiny program that emulates the detach feature of screen,
101 allowing you to run a program in an environment that is protected from the
102 controlling terminal and attach to it later.")
103 (license gpl2+)))
104
105 (define-public byobu
106 (package
107 (name "byobu")
108 (version "5.133")
109 (source
110 (origin
111 (method url-fetch)
112 (uri (string-append "https://launchpad.net/byobu/trunk/"
113 version "/+download/byobu_"
114 version ".orig.tar.gz"))
115 (sha256
116 (base32 "0qvmmdnvwqbgbhn5c8asmrmjhclcl029py2d2zvmd7h5ij7s93jd"))
117 (patches (search-patches "byobu-writable-status.patch"))))
118 (build-system gnu-build-system)
119 (inputs
120 `(("python" ,python-wrapper) ; for config and session GUIs
121 ("python-newt" ,newt "python")))
122 (arguments
123 `(#:phases
124 (modify-phases %standard-phases
125 (add-before
126 'configure 'provide-locale
127 (lambda* (#:key inputs #:allow-other-keys)
128 (let ((libc (assoc-ref inputs "libc"))) ; implicit input
129 (substitute* "usr/bin/byobu.in"
130 (("locale") (string-append libc "/bin/locale")))
131 #t)))
132 (add-after
133 'install 'wrap-python-scripts
134 (lambda* (#:key inputs outputs #:allow-other-keys)
135 (let* ((python (string-append (assoc-ref inputs "python")
136 "/bin/python"))
137 (out (assoc-ref outputs "out"))
138 (config (string-append out "/bin/byobu-config"))
139 (select (string-append out "/bin/byobu-select-session")))
140 (wrap-program config
141 `("BYOBU_PYTHON" = (,python))
142 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
143 (wrap-program select
144 `("BYOBU_PYTHON" = (,python)))
145 #t))))))
146 (home-page "https://byobu.org/")
147 (synopsis "Text-based window manager and terminal multiplexer")
148 (description
149 "Byobu is a Japanese term for decorative, multi-panel screens that serve
150 as folding room dividers. The Byobu software includes an enhanced profile,
151 configuration utilities, and system status notifications for the GNU Screen
152 window manager as well as the Tmux terminal multiplexer.")
153 (license gpl3+)))
154
155 (define-public reptyr
156 (package
157 (name "reptyr")
158 (version "0.7.0")
159 (source
160 (origin
161 (method git-fetch)
162 (uri (git-reference
163 (url "https://github.com/nelhage/reptyr")
164 (commit (string-append "reptyr-" version))))
165 (file-name (git-file-name name version))
166 (sha256
167 (base32 "1hnijfz1ab34j2h2cxc3f43rmbclyihgn9x9wxa7jqqgb2xm71hj"))))
168 (build-system gnu-build-system)
169 (arguments
170 '(#:tests? #f ; no tests
171 #:make-flags
172 (list "CC=gcc"
173 (string-append "PREFIX=" (assoc-ref %outputs "out"))
174 (string-append "BASHCOMPDIR=" (assoc-ref %outputs "out")
175 "/etc/bash_completion.d"))
176 #:phases
177 (modify-phases %standard-phases
178 (delete 'configure)))) ; no configure script
179 (home-page "https://github.com/nelhage/reptyr")
180 (synopsis "Tool for reparenting a running program to a new terminal")
181 (description
182 "reptyr is a utility for taking an existing running program and attaching
183 it to a new terminal. Started a long-running process over @code{ssh}, but have
184 to leave and don't want to interrupt it? Just start a @code{screen}, use
185 reptyr to grab it, and then kill the @code{ssh} session and head on home.")
186 ;; Reptyr currently does not support mips.
187 (supported-systems (delete "mips64el-linux" %supported-systems))
188 (license expat)))