web-browsers.scm 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935
  1. ;;; GNU Guix --- Functional package management for GNU
  2. ;;; Copyright © 2014 John Darrington <jmd@gnu.org>
  3. ;;; Copyright © 2014, 2019 Mark H Weaver <mhw@netris.org>
  4. ;;; Copyright © 2015, 2016, 2019, 2021 Efraim Flashner <efraim@flashner.co.il>
  5. ;;; Copyright © 2016 Kei Kebreau <kkebreau@posteo.net>
  6. ;;; Copyright © 2017 Eric Bavier <bavier@member.fsf.org>
  7. ;;; Copyright © 2018–2021 Tobias Geerinckx-Rice <me@tobias.gr>
  8. ;;; Copyright © 2018 Rutger Helling <rhelling@mykolab.com>
  9. ;;; Copyright © 2018 Timo Eisenmann <eisenmann@fn.de>
  10. ;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
  11. ;;; Copyright © 2019 Clément Lassieur <clement@lassieur.org>
  12. ;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
  13. ;;; Copyright © 2020 Raghav Gururajan <raghavgururajan@disroot.org>
  14. ;;; Copyright © 2020 B. Wilson <elaexuotee@wilsonb.com>
  15. ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
  16. ;;; Copyright © 2020 Nicolò Balzarotti <nicolo@nixo.xyz>
  17. ;;; Copyright © 2020 Alexandru-Sergiu Marton <brown121407@posteo.ro>
  18. ;;; Copyright © 2021 Cage <cage-dev@twistfold.it>
  19. ;;; Copyright © 2021 Benoit Joly <benoit@benoitj.ca>
  20. ;;; Copyright © 2021 Alexander Krotov <krotov@iitp.ru>
  21. ;;; Copyright © 2020 Hartmut Goebel <h.goebel@crazy-compilers.com>
  22. ;;; Copyright © 2021 Christopher Howard <christopher@librehacker.com>
  23. ;;;
  24. ;;; This file is part of GNU Guix.
  25. ;;;
  26. ;;; GNU Guix is free software; you can redistribute it and/or modify it
  27. ;;; under the terms of the GNU General Public License as published by
  28. ;;; the Free Software Foundation; either version 3 of the License, or (at
  29. ;;; your option) any later version.
  30. ;;;
  31. ;;; GNU Guix is distributed in the hope that it will be useful, but
  32. ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
  33. ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  34. ;;; GNU General Public License for more details.
  35. ;;;
  36. ;;; You should have received a copy of the GNU General Public License
  37. ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
  38. (define-module (gnu packages web-browsers)
  39. #:use-module (guix build-system asdf)
  40. #:use-module (guix build-system cmake)
  41. #:use-module (guix build-system glib-or-gtk)
  42. #:use-module (guix build-system gnu)
  43. #:use-module (guix build-system go)
  44. #:use-module (guix build-system python)
  45. #:use-module (guix download)
  46. #:use-module (guix git-download)
  47. #:use-module ((guix licenses) #:prefix license:)
  48. #:use-module (guix packages)
  49. #:use-module (guix utils)
  50. #:use-module (gnu packages)
  51. #:use-module (gnu packages autotools)
  52. #:use-module (gnu packages backup)
  53. #:use-module (gnu packages bison)
  54. #:use-module (gnu packages compression)
  55. #:use-module (gnu packages curl)
  56. #:use-module (gnu packages documentation)
  57. #:use-module (gnu packages fltk)
  58. #:use-module (gnu packages fontutils)
  59. #:use-module (gnu packages fonts)
  60. #:use-module (gnu packages freedesktop)
  61. #:use-module (gnu packages gcc)
  62. #:use-module (gnu packages gettext)
  63. #:use-module (gnu packages glib)
  64. #:use-module (gnu packages gnome)
  65. #:use-module (gnu packages gnome-xyz)
  66. #:use-module (gnu packages gnupg)
  67. #:use-module (gnu packages gtk)
  68. #:use-module (gnu packages image)
  69. #:use-module (gnu packages libevent)
  70. #:use-module (gnu packages libidn)
  71. #:use-module (gnu packages libunistring)
  72. #:use-module (gnu packages linux)
  73. #:use-module (gnu packages lisp)
  74. #:use-module (gnu packages lisp-xyz)
  75. #:use-module (gnu packages lua)
  76. #:use-module (gnu packages man)
  77. #:use-module (gnu packages markup)
  78. #:use-module (gnu packages mp3)
  79. #:use-module (gnu packages nano)
  80. #:use-module (gnu packages ncurses)
  81. #:use-module (gnu packages pcre)
  82. #:use-module (gnu packages perl)
  83. #:use-module (gnu packages pkg-config)
  84. #:use-module (gnu packages python)
  85. #:use-module (gnu packages python-web)
  86. #:use-module (gnu packages python-xyz)
  87. #:use-module (gnu packages qt)
  88. #:use-module (gnu packages sdl)
  89. #:use-module (gnu packages sqlite)
  90. #:use-module (gnu packages tls)
  91. #:use-module (gnu packages webkit)
  92. #:use-module (gnu packages xorg))
  93. (define-public midori
  94. (package
  95. (name "midori")
  96. (version "9.0")
  97. (source
  98. (origin
  99. (method url-fetch)
  100. (uri
  101. (string-append "https://github.com/midori-browser/core/releases/"
  102. "download/v" version "/" name "-v" version ".tar.gz"))
  103. (sha256
  104. (base32
  105. "05i04qa83dnarmgkx4xsk6fga5lw1lmslh4rb3vhyyy4ala562jy"))))
  106. (build-system cmake-build-system)
  107. (arguments
  108. `(#:imported-modules
  109. (,@%cmake-build-system-modules
  110. (guix build glib-or-gtk-build-system))
  111. #:modules
  112. ((guix build cmake-build-system)
  113. ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
  114. (guix build utils))
  115. #:phases
  116. (modify-phases %standard-phases
  117. (add-after 'install 'glib-or-gtk-compile-schemas
  118. (assoc-ref glib-or-gtk:%standard-phases
  119. 'glib-or-gtk-compile-schemas))
  120. (add-after 'install 'glib-or-gtk-wrap
  121. (assoc-ref glib-or-gtk:%standard-phases
  122. 'glib-or-gtk-wrap)))))
  123. (native-inputs
  124. `(("glib:bin" ,glib "bin")
  125. ("gtk+:bin" ,gtk+ "bin")
  126. ("intltool" ,intltool)
  127. ("pkg-config" ,pkg-config)))
  128. (inputs
  129. `(("adwaita-icon-theme" ,adwaita-icon-theme)
  130. ("gcr" ,gcr)
  131. ("glib" ,glib)
  132. ("glib-networking" ,glib-networking)
  133. ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
  134. ("gtk+" ,gtk+)
  135. ("json-glib" ,json-glib)
  136. ("libarchive" ,libarchive)
  137. ("libpeas" ,libpeas)
  138. ("libsoup" ,libsoup)
  139. ("sqlite" ,sqlite)
  140. ("vala" ,vala)
  141. ("webkitgtk" ,webkitgtk)))
  142. (synopsis "Lightweight graphical web browser")
  143. (description "@code{Midori} is a lightweight, Webkit-based web browser.
  144. It features integration with GTK+3, configurable web search engine, bookmark
  145. management, extensions such as advertisement blocker and colorful tabs.")
  146. (home-page "https://www.midori-browser.org")
  147. (license license:lgpl2.1+)))
  148. (define-public links
  149. (package
  150. (name "links")
  151. (version "2.23")
  152. (source (origin
  153. (method url-fetch)
  154. (uri (string-append "http://links.twibright.com/download/"
  155. "links-" version ".tar.bz2"))
  156. (sha256
  157. (base32
  158. "0idcwryfbf6ds5x2fx1k21m459qz5mrz3hw4a6ziiz91yl1d4q36"))))
  159. (build-system gnu-build-system)
  160. (arguments
  161. `(#:phases
  162. (modify-phases %standard-phases
  163. (replace 'configure
  164. (lambda* (#:key outputs #:allow-other-keys)
  165. ;; The tarball uses a very old version of autconf. It doesn't
  166. ;; understand extra flags like `--enable-fast-install', so
  167. ;; we need to invoke it with just what it understands.
  168. (let ((out (assoc-ref outputs "out")))
  169. ;; 'configure' doesn't understand '--host'.
  170. ,@(if (%current-target-system)
  171. `((setenv "CHOST" ,(%current-target-system)))
  172. '())
  173. (setenv "CONFIG_SHELL" (which "bash"))
  174. (invoke "./configure"
  175. (string-append "--prefix=" out)
  176. "--enable-graphics")
  177. #t))))))
  178. (native-inputs `(("linux-libre-headers" ,linux-libre-headers)
  179. ("pkg-config" ,pkg-config)))
  180. (inputs `(("gpm" ,gpm)
  181. ("libevent" ,libevent)
  182. ("libjpeg" ,libjpeg-turbo)
  183. ("libpng" ,libpng)
  184. ("libtiff" ,libtiff)
  185. ("libxt" ,libxt)
  186. ("openssl" ,openssl)
  187. ("zlib" ,zlib)))
  188. (synopsis "Text and graphics mode web browser")
  189. (description "Links is a graphics and text mode web browser, with many
  190. features including, tables, builtin image display, bookmarks, SSL and more.")
  191. (home-page "http://links.twibright.com")
  192. ;; The distribution contains a copy of GPLv2
  193. ;; However, the copyright notices simply say:
  194. ;; "This file is a part of the Links program, released under GPL."
  195. ;; Therefore, under the provisions of Section 9, we can choose
  196. ;; any version ever published by the FSF.
  197. ;; One file (https.c) contains an exception permitting
  198. ;; linking of the program with openssl.
  199. (license license:gpl1+)))
  200. (define-public luakit
  201. (package
  202. (name "luakit")
  203. (version "2.3")
  204. (source (origin
  205. (method git-fetch)
  206. (uri (git-reference
  207. (url "https://github.com/luakit/luakit")
  208. (commit version)))
  209. (file-name (git-file-name name version))
  210. (sha256
  211. (base32
  212. "1khbn7dpizkznnwkw7rcfhf72dnd1nazk7dwb4rkh9i97b53mf1y"))))
  213. (inputs
  214. `(("lua-5.1" ,lua-5.1)
  215. ("gtk+" ,gtk+)
  216. ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
  217. ("glib-networking" ,glib-networking)
  218. ("lua5.1-filesystem" ,lua5.1-filesystem)
  219. ("luajit" ,luajit)
  220. ("webkitgtk" ,webkitgtk)
  221. ("sqlite" ,sqlite)))
  222. (native-inputs
  223. `(("pkg-config" ,pkg-config)))
  224. (build-system glib-or-gtk-build-system)
  225. (arguments
  226. `(#:make-flags
  227. (let ((out (assoc-ref %outputs "out")))
  228. (list
  229. "CC=gcc"
  230. "LUA_BIN_NAME=lua"
  231. "DEVELOPMENT_PATHS=0"
  232. (string-append "PREFIX=" out)
  233. (string-append "XDGPREFIX=" out "/etc/xdg")))
  234. #:phases
  235. (modify-phases %standard-phases
  236. (add-before 'build 'lfs-workaround
  237. (lambda _
  238. (setenv "LUA_CPATH"
  239. (string-append
  240. (assoc-ref %build-inputs "lua5.1-filesystem")
  241. "/lib/lua/5.1/?.so;;"))
  242. #t))
  243. (add-before 'build 'set-version
  244. (lambda _
  245. (setenv "VERSION_FROM_GIT" ,(package-version this-package))
  246. #t))
  247. (delete 'configure)
  248. (delete 'check)
  249. (add-after 'install 'wrap
  250. (lambda* (#:key inputs outputs #:allow-other-keys)
  251. (let* ((luakit (assoc-ref outputs "out"))
  252. (lua5.1-filesystem (assoc-ref inputs "lua5.1-filesystem") )
  253. (gtk (assoc-ref inputs "gtk+"))
  254. (gtk-share (string-append gtk "/share")))
  255. (wrap-program (string-append luakit "/bin/luakit")
  256. `("LUA_CPATH" prefix
  257. (,(string-append lua5.1-filesystem
  258. "/lib/lua/5.1/?.so;;")))
  259. `("XDG_CONFIG_DIRS" prefix
  260. (,(string-append luakit "/etc/xdg/"))))
  261. #t))))))
  262. (synopsis "Fast, lightweight, and simple browser based on WebKit")
  263. (description "Luakit is a fast, lightweight, and simple to use
  264. micro-browser framework extensible by Lua using the WebKit web content engine
  265. and the GTK+ toolkit.")
  266. (home-page "https://luakit.github.io/")
  267. (license license:gpl3+)))
  268. (define-public lynx
  269. (package
  270. (name "lynx")
  271. (version "2.9.0dev.9")
  272. (source (origin
  273. (method url-fetch)
  274. (uri (string-append
  275. "http://invisible-mirror.net/archives/lynx/tarballs"
  276. "/lynx" version ".tar.bz2"))
  277. (sha256
  278. (base32
  279. "06jhv8ibfw1xkf8d8zrnkc2aw4d462s77hlp6f6xa6k8awzxvmkg"))))
  280. (build-system gnu-build-system)
  281. (native-inputs `(("pkg-config" ,pkg-config)
  282. ("perl" ,perl)))
  283. (inputs `(("ncurses" ,ncurses)
  284. ("libidn" ,libidn)
  285. ("openssl" ,openssl)
  286. ("libgcrypt" ,libgcrypt)
  287. ("unzip" ,unzip)
  288. ("zlib" ,zlib)
  289. ("gzip" ,gzip)
  290. ("bzip2" ,bzip2)))
  291. (arguments
  292. `(#:configure-flags
  293. (let ((openssl (assoc-ref %build-inputs "openssl")))
  294. `("--with-pkg-config"
  295. "--with-screen=ncurses"
  296. "--with-zlib"
  297. "--with-bzlib"
  298. ,(string-append "--with-ssl=" openssl)
  299. ;; "--with-socks5" ; XXX TODO
  300. "--enable-widec"
  301. "--enable-ascii-ctypes"
  302. "--enable-local-docs"
  303. "--enable-htmlized-cfg"
  304. "--enable-gzip-help"
  305. "--enable-nls"
  306. "--enable-ipv6"))
  307. #:tests? #f ; no check target
  308. #:phases
  309. (modify-phases %standard-phases
  310. (add-before 'configure 'set-makefile-shell
  311. (lambda _ (substitute* "po/makefile.inn"
  312. (("/bin/sh") (which "sh")))
  313. #t))
  314. (replace 'install
  315. (lambda* (#:key (make-flags '()) #:allow-other-keys)
  316. (apply invoke "make" "install-full" make-flags)
  317. #t)))))
  318. (synopsis "Text Web Browser")
  319. (description
  320. "Lynx is a fully-featured World Wide Web (WWW) client for users running
  321. cursor-addressable, character-cell display devices. It will display Hypertext
  322. Markup Language (HTML) documents containing links to files on the local
  323. system, as well as files on remote systems running http, gopher, ftp, wais,
  324. nntp, finger, or cso/ph/qi servers. Lynx can be used to access information on
  325. the WWW, or to build information systems intended primarily for local
  326. access.")
  327. (home-page "https://lynx.invisible-island.net/")
  328. ;; This was fixed in 2.8.9dev.10.
  329. (properties `((lint-hidden-cve . ("CVE-2016-9179"))))
  330. (license license:gpl2)))
  331. (define-public kristall
  332. ;; Fixes to the build system applied after the latest tag
  333. ;; Use tagged release when updating
  334. (let ((commit "204b08a9303e75cd8d4c252b0554935062766f86")
  335. (revision "1"))
  336. (package
  337. (name "kristall")
  338. (version (string-append "0.3-" revision "." (string-take commit 7)))
  339. (source
  340. (origin
  341. (method git-fetch)
  342. (uri (git-reference
  343. (url "https://github.com/MasterQ32/kristall")
  344. (commit commit)))
  345. (file-name (git-file-name name version))
  346. (sha256
  347. (base32
  348. "1mymq0dh6r0829x74j0jkw8hw46amqwbznlf1b4ra6w77h9yz3lj"))
  349. (modules '((srfi srfi-1)
  350. (ice-9 ftw)
  351. (guix build utils)))
  352. (snippet
  353. '(let ((preserved-lib-files '("luis-l-gist")))
  354. (with-directory-excursion "lib"
  355. (for-each
  356. (lambda (directory)
  357. (simple-format #t "deleting: ~A\n" directory)
  358. (delete-file-recursively directory))
  359. (lset-difference string=?
  360. (scandir ".")
  361. (cons* "." ".." preserved-lib-files))))
  362. ;; Contains executable of 7z and pscp
  363. (delete-file-recursively "ci/tools")
  364. ;; Remove bundled fonts
  365. (delete-file-recursively "src/fonts")
  366. #t))))
  367. (build-system gnu-build-system)
  368. (arguments
  369. `(#:modules ((guix build gnu-build-system)
  370. (guix build qt-utils)
  371. (guix build utils))
  372. #:imported-modules (,@%gnu-build-system-modules
  373. (guix build qt-utils))
  374. #:make-flags
  375. (list (string-append "PREFIX=" %output))
  376. #:phases
  377. (modify-phases %standard-phases
  378. (delete 'configure) ; no ./configure script
  379. (delete 'check) ; no check target
  380. (add-before 'build 'set-program-version
  381. (lambda _
  382. ;; configure.ac relies on ‘git --describe’ to get the version.
  383. ;; Patch it to just return the real version number directly.
  384. (substitute* "src/kristall.pro"
  385. (("(KRISTALL_VERSION=).*" _ match)
  386. (string-append match ,version "\n")))
  387. #t))
  388. (add-before 'build 'dont-use-bundled-cmark
  389. (lambda _
  390. (substitute* "src/kristall.pro"
  391. (("(^include\\(.*cmark.*)" _ match)
  392. (string-append
  393. "LIBS += -I" (assoc-ref %build-inputs "cmark") " -lcmark")))
  394. #t))
  395. (add-before 'build 'dont-use-bundled-breeze-stylesheet
  396. (lambda _
  397. (substitute* "src/kristall.pro"
  398. (("../lib/BreezeStyleSheets/breeze.qrc")
  399. (string-append
  400. (assoc-ref %build-inputs "breeze-stylesheet") "/breeze.qrc")))
  401. #t))
  402. (add-before 'build 'dont-use-bundled-fonts
  403. (lambda _
  404. (substitute* "src/kristall.pro"
  405. ((".*fonts.qrc.*") ""))
  406. (substitute* "src/main.cpp"
  407. (("/fonts/OpenMoji-Color")
  408. (string-append
  409. (assoc-ref %build-inputs "font-openmoji")
  410. "/share/fonts/truetype/OpenMoji-Color"))
  411. (("/fonts/NotoColorEmoji")
  412. (string-append
  413. (assoc-ref %build-inputs "font-google-noto")
  414. "/share/fonts/truetype/NotoColorEmoji")))
  415. #t))
  416. (add-after 'install 'wrap-program
  417. (lambda* (#:key outputs inputs #:allow-other-keys)
  418. (let ((out (assoc-ref outputs "out")))
  419. (wrap-qt-program "kristall" #:output out #:inputs inputs))
  420. #t)))))
  421. (native-inputs
  422. `(("breeze-stylesheet"
  423. ,(let ((commit "2d595a956f8a5f493aa51139a470b768a6d82cce")
  424. (revision "0"))
  425. (origin
  426. (method git-fetch)
  427. (uri
  428. (git-reference
  429. (url "https://github.com/Alexhuszagh/BreezeStyleSheets")
  430. (commit "2d595a956f8a5f493aa51139a470b768a6d82cce")))
  431. (file-name (git-file-name "breeze-stylesheet"
  432. (git-version "0" revision commit)))
  433. (sha256
  434. (base32
  435. "1kvkxkisi3czldnb43ig60l55pi4a3m2a4ixp7krhpf9fc5wp294")))))))
  436. (inputs
  437. `(("cmark" ,cmark)
  438. ("font-google-noto" ,font-google-noto)
  439. ("font-openmoji" ,font-openmoji)
  440. ("openssl" ,openssl)
  441. ("qtbase" ,qtbase-5)
  442. ("qtmultimedia" ,qtmultimedia)
  443. ("qtsvg" ,qtsvg)))
  444. (home-page "https://kristall.random-projects.net")
  445. (synopsis "Small-internet graphical client")
  446. (description "Graphical small-internet client with with many features
  447. including multi-protocol support (gemini, HTTP, HTTPS, gopher, finger),
  448. bookmarks, TSL certificates management, outline generation and a tabbed
  449. interface.")
  450. (license (list license:gpl3+
  451. ;; for breeze-stylesheet
  452. license:expat)))))
  453. (define-public qutebrowser
  454. (package
  455. (name "qutebrowser")
  456. (version "2.3.1")
  457. (source
  458. (origin
  459. (method url-fetch)
  460. (uri (string-append "https://github.com/qutebrowser/"
  461. "qutebrowser/releases/download/v" version "/"
  462. "qutebrowser-" version ".tar.gz"))
  463. (sha256
  464. (base32 "05n64mw9lzzxpxr7lhakbkm9ir3x8p0rwk6vbbg01aqg5iaanyj0"))))
  465. (build-system python-build-system)
  466. (native-inputs
  467. `(("python-attrs" ,python-attrs))) ; for tests
  468. (inputs
  469. `(("python-colorama" ,python-colorama)
  470. ("python-cssutils" ,python-cssutils)
  471. ("python-importlib-resources" ,python-importlib-resources)
  472. ("python-jinja2" ,python-jinja2)
  473. ("python-markupsafe" ,python-markupsafe)
  474. ("python-pygments" ,python-pygments)
  475. ("python-pypeg2" ,python-pypeg2)
  476. ("python-pyyaml" ,python-pyyaml)
  477. ;; FIXME: python-pyqtwebengine needs to come before python-pyqt so
  478. ;; that it's __init__.py is used first.
  479. ("python-pyqtwebengine" ,python-pyqtwebengine)
  480. ("python-pyqt" ,python-pyqt)
  481. ;; While qtwebengine is provided by python-pyqtwebengine, it's
  482. ;; included here so we can wrap QTWEBENGINEPROCESS_PATH.
  483. ("qtwebengine" ,qtwebengine)))
  484. (arguments
  485. `(;; FIXME: With the existance of qtwebengine, tests can now run. But
  486. ;; they are still disabled because test phase hangs. It's not readily
  487. ;; apparent as to why.
  488. #:tests? #f
  489. #:phases
  490. (modify-phases %standard-phases
  491. (add-before 'check 'set-env-offscreen
  492. (lambda _
  493. (setenv "QT_QPA_PLATFORM" "offscreen")
  494. #t))
  495. (add-after 'install 'install-more
  496. (lambda* (#:key outputs #:allow-other-keys)
  497. (let* ((out (assoc-ref outputs "out"))
  498. (app (string-append out "/share/applications"))
  499. (hicolor (string-append out "/share/icons/hicolor")))
  500. (install-file "doc/qutebrowser.1"
  501. (string-append out "/share/man/man1"))
  502. (for-each
  503. (lambda (i)
  504. (let ((src (format #f "icons/qutebrowser-~dx~d.png" i i))
  505. (dest (format #f "~a/~dx~d/apps/qutebrowser.png"
  506. hicolor i i)))
  507. (mkdir-p (dirname dest))
  508. (copy-file src dest)))
  509. '(16 24 32 48 64 128 256 512))
  510. (install-file "icons/qutebrowser.svg"
  511. (string-append hicolor "/scalable/apps"))
  512. (substitute* "misc/org.qutebrowser.qutebrowser.desktop"
  513. (("Exec=qutebrowser")
  514. (string-append "Exec=" out "/bin/qutebrowser")))
  515. (install-file "misc/org.qutebrowser.qutebrowser.desktop" app)
  516. #t)))
  517. (add-after 'wrap 'wrap-qt-process-path
  518. (lambda* (#:key inputs outputs #:allow-other-keys)
  519. (let* ((out (assoc-ref outputs "out"))
  520. (bin (string-append out "/bin/qutebrowser"))
  521. (qt-process-path (string-append
  522. (assoc-ref inputs "qtwebengine")
  523. "/lib/qt5/libexec/QtWebEngineProcess")))
  524. (wrap-program bin
  525. `("QTWEBENGINEPROCESS_PATH" = (,qt-process-path)))
  526. #t))))))
  527. (home-page "https://qutebrowser.org/")
  528. (synopsis "Minimal, keyboard-focused, vim-like web browser")
  529. (description "qutebrowser is a keyboard-focused browser with a minimal
  530. GUI. It is based on PyQt5 and QtWebEngine.")
  531. (license license:gpl3+)))
  532. (define-public vimb
  533. (package
  534. (name "vimb")
  535. (version "3.6.0")
  536. (source
  537. (origin
  538. (method git-fetch)
  539. (uri (git-reference
  540. (url "https://github.com/fanglingsu/vimb/")
  541. (commit version)))
  542. (sha256
  543. (base32 "0228khh3lqbal046k6akqah7s5igq9s0wjfjbdjam75kjj42pbhj"))
  544. (file-name (git-file-name name version))))
  545. (build-system glib-or-gtk-build-system)
  546. (arguments
  547. '(#:tests? #f ; no tests
  548. #:make-flags (list "CC=gcc"
  549. "DESTDIR="
  550. (string-append "PREFIX=" %output))
  551. #:phases
  552. (modify-phases %standard-phases
  553. (delete 'configure))))
  554. (inputs
  555. `(("glib-networking" ,glib-networking)
  556. ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
  557. ("webkitgtk" ,webkitgtk)))
  558. (native-inputs
  559. `(("pkg-config" ,pkg-config)))
  560. (home-page "https://fanglingsu.github.io/vimb/")
  561. (synopsis "Fast and lightweight Vim-like web browser")
  562. (description "Vimb is a fast and lightweight vim like web browser based on
  563. the webkit web browser engine and the GTK toolkit. Vimb is modal like the great
  564. vim editor and also easily configurable during runtime. Vimb is mostly keyboard
  565. driven and does not detract you from your daily work.")
  566. (license license:gpl3+)))
  567. (define-public nyxt
  568. (package
  569. (name "nyxt")
  570. (version "2.1.1")
  571. (source
  572. (origin
  573. (method git-fetch)
  574. (uri (git-reference
  575. ;; TODO: Mirror seems to hang, let's fallback to GitHub for now.
  576. ;; (url "https://source.atlas.engineer/public/nyxt")
  577. (url "https://github.com/atlas-engineer/nyxt")
  578. (commit version)))
  579. (sha256
  580. (base32
  581. "0kzm05swhyb197cjfd3iglf60b997sx7v95yxzyq483jxqbcxm0r"))
  582. (file-name (git-file-name "nyxt" version))))
  583. (build-system gnu-build-system)
  584. (arguments
  585. `(#:make-flags (list "nyxt" "NYXT_INTERNAL_QUICKLISP=false"
  586. (string-append "DESTDIR=" (assoc-ref %outputs "out"))
  587. "PREFIX=")
  588. #:strip-binaries? #f ; Stripping breaks SBCL binaries.
  589. #:phases
  590. (modify-phases %standard-phases
  591. (delete 'configure)
  592. (add-before 'build 'fix-common-lisp-cache-folder
  593. (lambda _
  594. (setenv "HOME" "/tmp")
  595. #t))
  596. (add-before 'check 'configure-tests
  597. (lambda _
  598. (setenv "NYXT_TESTS_NO_NETWORK" "1")
  599. (setenv "NYXT_TESTS_ERROR_ON_FAIL" "1")
  600. #t))
  601. (add-after 'install 'wrap-program
  602. (lambda* (#:key inputs outputs #:allow-other-keys)
  603. (let* ((bin (string-append (assoc-ref outputs "out") "/bin/nyxt"))
  604. (glib-networking (assoc-ref inputs "glib-networking"))
  605. (libs '("gsettings-desktop-schemas"))
  606. (path (string-join
  607. (map (lambda (lib)
  608. (string-append (assoc-ref inputs lib) "/lib"))
  609. libs)
  610. ":"))
  611. (gi-path (getenv "GI_TYPELIB_PATH"))
  612. (xdg-path (string-join
  613. (map (lambda (lib)
  614. (string-append (assoc-ref inputs lib) "/share"))
  615. libs)
  616. ":")))
  617. (wrap-program bin
  618. `("GIO_EXTRA_MODULES" prefix
  619. (,(string-append glib-networking "/lib/gio/modules")))
  620. `("GI_TYPELIB_PATH" prefix (,gi-path))
  621. `("LD_LIBRARY_PATH" ":" prefix (,path))
  622. `("XDG_DATA_DIRS" ":" prefix (,xdg-path)))
  623. #t))))))
  624. (native-inputs
  625. `(("prove" ,sbcl-prove)
  626. ("sbcl" ,sbcl)))
  627. (inputs
  628. `(("alexandria" ,sbcl-alexandria)
  629. ("bordeaux-threads" ,sbcl-bordeaux-threads)
  630. ("cl-calispel" ,sbcl-calispel)
  631. ("cl-containers" ,sbcl-cl-containers)
  632. ("cl-css" ,sbcl-cl-css)
  633. ("cl-custom-hash-table" ,sbcl-custom-hash-table)
  634. ("cl-html-diff" ,sbcl-cl-html-diff)
  635. ("cl-json" ,sbcl-cl-json)
  636. ("cl-markup" ,sbcl-cl-markup)
  637. ("cl-ppcre" ,sbcl-cl-ppcre)
  638. ("cl-prevalence" ,sbcl-cl-prevalence)
  639. ("closer-mop" ,sbcl-closer-mop)
  640. ("cluffer" ,sbcl-cluffer)
  641. ("dexador" ,sbcl-dexador)
  642. ("enchant" ,sbcl-enchant)
  643. ("fset" ,sbcl-fset)
  644. ("hu.dwim.defclass-star" ,sbcl-hu.dwim.defclass-star)
  645. ("iolib" ,sbcl-iolib)
  646. ("local-time" ,sbcl-local-time)
  647. ("log4cl" ,sbcl-log4cl)
  648. ("mk-string-metrics" ,sbcl-mk-string-metrics)
  649. ("moptilities" ,sbcl-moptilities)
  650. ("named-readtables" ,sbcl-named-readtables)
  651. ("parenscript" ,sbcl-parenscript)
  652. ("plump" ,sbcl-plump)
  653. ("quri" ,sbcl-quri)
  654. ("serapeum" ,sbcl-serapeum)
  655. ("str" ,sbcl-cl-str)
  656. ("swank" ,sbcl-slime-swank)
  657. ("trivia" ,sbcl-trivia)
  658. ("trivial-clipboard" ,sbcl-trivial-clipboard)
  659. ("trivial-features" ,sbcl-trivial-features)
  660. ("trivial-package-local-nicknames" ,sbcl-trivial-package-local-nicknames)
  661. ("trivial-types" ,sbcl-trivial-types)
  662. ("unix-opts" ,sbcl-unix-opts)
  663. ;; WebKitGTK deps
  664. ("cl-cffi-gtk" ,sbcl-cl-cffi-gtk)
  665. ("cl-webkit" ,sbcl-cl-webkit)
  666. ("glib-networking" ,glib-networking)
  667. ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
  668. ;; GObjectIntrospection
  669. ("cl-gobject-introspection" ,sbcl-cl-gobject-introspection)
  670. ("gtk" ,gtk+) ; For the main loop.
  671. ("webkitgtk" ,webkitgtk) ; Required when we use its typelib.
  672. ("gobject-introspection" ,gobject-introspection)))
  673. (synopsis "Extensible web-browser in Common Lisp")
  674. (home-page "https://nyxt.atlas.engineer")
  675. (description "Nyxt is a keyboard-oriented, extensible web browser designed
  676. for power users. Conceptually inspired by Emacs and Vim, it has familiar
  677. key-bindings (Emacs, vi, CUA), and is fully configurable in Common Lisp.")
  678. (license license:bsd-3)))
  679. (define-public next
  680. (deprecated-package "next" nyxt))
  681. (define-public sbcl-next
  682. (deprecated-package "sbcl-next" nyxt))
  683. (define-public lagrange
  684. (package
  685. (name "lagrange")
  686. (version "1.5.2")
  687. (source
  688. (origin
  689. (method url-fetch)
  690. (uri
  691. (string-append "https://git.skyjake.fi/skyjake/lagrange/releases/"
  692. "download/v" version "/lagrange-" version ".tar.gz"))
  693. (sha256
  694. (base32 "0gqaipgs16kw711ijhshmbhhvlyjvh37wxdz059p4vvjhfrxbr1v"))))
  695. (build-system cmake-build-system)
  696. (arguments
  697. `(#:tests? #false ;no tests
  698. #:configure-flags (list "-DTFDN_ENABLE_SSE41=OFF")))
  699. (native-inputs
  700. `(("pkg-config" ,pkg-config)))
  701. (inputs
  702. `(("libunistring" ,libunistring)
  703. ("mpg123" ,mpg123)
  704. ("openssl" ,openssl)
  705. ("pcre" ,pcre)
  706. ("sdl2" ,sdl2)
  707. ("zlib" ,zlib)))
  708. (home-page "https://gmi.skyjake.fi/lagrange/")
  709. (synopsis "Graphical Gemini client")
  710. (description
  711. "Lagrange is a desktop GUI client for browsing Geminispace. It offers
  712. modern conveniences familiar from web browsers, such as smooth scrolling,
  713. inline image viewing, multiple tabs, visual themes, Unicode fonts, bookmarks,
  714. history, and page outlines.")
  715. (license license:bsd-2)))
  716. (define-public gmni
  717. (let ((commit "d8f0870446c471a42612d6a8e853ad9b723a6d39")
  718. (revision "0"))
  719. (package
  720. (name "gmni")
  721. (version (git-version "0" revision commit))
  722. (source (origin
  723. (method git-fetch)
  724. (uri (git-reference
  725. (url "https://git.sr.ht/~sircmpwn/gmni")
  726. (commit commit)))
  727. (sha256
  728. (base32
  729. "1h0iqm7l0i06glf5b2872w656s1mjdiqva14zh6sl4f5yp7zmvwr"))
  730. (file-name (git-file-name name version))))
  731. (build-system gnu-build-system)
  732. (arguments
  733. `(#:tests? #f ; no check target
  734. #:make-flags (list (string-append "CC=" ,(cc-for-target)))))
  735. (inputs
  736. `(("openssl" ,openssl)))
  737. (native-inputs
  738. `(("pkg-config" ,pkg-config)
  739. ("scdoc" ,scdoc)))
  740. (home-page "https://sr.ht/~sircmpwn/gmni")
  741. (synopsis "Minimalist command line Gemini client")
  742. (description "The gmni package includes:
  743. @itemize
  744. @item A CLI utility (like curl): gmni
  745. @item A line-mode browser: gmnlm
  746. @end itemize")
  747. (license (list license:gpl3+
  748. (license:non-copyleft
  749. "https://curl.se/docs/copyright.html"
  750. "Used only for files taken from curl."))))))
  751. (define-public bombadillo
  752. (package
  753. (name "bombadillo")
  754. (version "2.3.3")
  755. (source (origin
  756. (method git-fetch)
  757. (uri (git-reference
  758. (url "https://tildegit.org/sloum/bombadillo")
  759. (commit version)))
  760. (sha256
  761. (base32
  762. "02w6h44sxzmk3bkdidl8xla0i9rwwpdqljnvcbydx5kyixycmg0q"))
  763. (file-name (git-file-name name version))))
  764. (build-system go-build-system)
  765. (arguments
  766. `(#:import-path "tildegit.org/sloum/bombadillo"
  767. #:install-source? #f
  768. #:phases (modify-phases %standard-phases
  769. (add-after 'install 'install-data
  770. (lambda* (#:key outputs #:allow-other-keys)
  771. (let* ((builddir "src/tildegit.org/sloum/bombadillo")
  772. (out (assoc-ref outputs "out"))
  773. (pkg (strip-store-file-name out))
  774. (sharedir (string-append out "/share"))
  775. (appdir (string-append sharedir "/applications"))
  776. (docdir (string-append sharedir "/doc/" pkg))
  777. (mandir (string-append sharedir "/man/man1"))
  778. (pixdir (string-append sharedir "/pixmaps")))
  779. (with-directory-excursion builddir
  780. (install-file "bombadillo.desktop" appdir)
  781. (install-file "bombadillo.1" mandir)
  782. (install-file "bombadillo-icon.png" pixdir)
  783. #t)))))))
  784. (home-page "https://bombadillo.colorfield.space")
  785. (synopsis "Terminal browser for the gopher, gemini, and finger protocols")
  786. (description "Bombadillo is a non-web browser for the terminal with
  787. vim-like key bindings, a document pager, configurable settings, and robust
  788. command selection. The following protocols are supported as first-class
  789. citizens: gopher, gemini, finger, and local. There is also support for telnet,
  790. http, and https via third-party applications.")
  791. (license license:gpl3+)))
  792. (define-public tinmop
  793. (package
  794. (name "tinmop")
  795. (version "0.8.3")
  796. (source
  797. (origin
  798. (method git-fetch)
  799. (uri (git-reference
  800. (url "https://notabug.org/cage/tinmop")
  801. (commit (string-append "v" version))))
  802. (file-name (git-file-name name version))
  803. (sha256
  804. (base32 "117p1wxi5swmqw429qrswxz2zvp1dcaw2145gk6zxlgwln48qxl8"))))
  805. (build-system gnu-build-system)
  806. (native-inputs
  807. `(("curl" ,curl)
  808. ("gettext" ,gnu-gettext)
  809. ("gnupg" ,gnupg)
  810. ("sbcl" ,sbcl)))
  811. (inputs
  812. `(("access" ,sbcl-access)
  813. ("alexandria" ,sbcl-alexandria)
  814. ("babel" ,sbcl-babel)
  815. ("bordeaux-threads" ,sbcl-bordeaux-threads)
  816. ("cl-base64" ,sbcl-cl-base64)
  817. ("cl-colors2" ,sbcl-cl-colors2)
  818. ("cl-html5-parser" ,sbcl-cl-html5-parser)
  819. ("cl-i18n" ,sbcl-cl-i18n)
  820. ("cl-ppcre" ,sbcl-cl-ppcre)
  821. ("cl-spark" ,sbcl-cl-spark)
  822. ("cl-sqlite" ,sbcl-cl-sqlite)
  823. ("cl+ssl" ,sbcl-cl+ssl)
  824. ("clunit2" ,sbcl-clunit2)
  825. ("croatoan" ,sbcl-croatoan)
  826. ("crypto-shortcuts" ,sbcl-crypto-shortcuts)
  827. ("drakma" ,sbcl-drakma)
  828. ("esrap" ,sbcl-esrap)
  829. ("ieee-floats" ,sbcl-ieee-floats)
  830. ("local-time" ,sbcl-local-time)
  831. ("log4cl" ,sbcl-log4cl)
  832. ("marshal" ,sbcl-marshal)
  833. ("nano" ,nano)
  834. ("openssl" ,openssl)
  835. ("osicat" ,sbcl-osicat)
  836. ("parse-number" ,sbcl-parse-number)
  837. ("percent-encoding" ,sbcl-percent-encoding)
  838. ("sxql" ,sbcl-sxql)
  839. ("sxql-composer" ,sbcl-sxql-composer)
  840. ("tooter" ,sbcl-tooter)
  841. ("unix-opts" ,sbcl-unix-opts)
  842. ("usocket" ,sbcl-usocket)
  843. ("xdg-utils" ,xdg-utils)))
  844. (arguments
  845. `(#:tests? #f
  846. #:strip-binaries? #f
  847. #:phases
  848. (modify-phases %standard-phases
  849. (add-after 'unpack 'set-home
  850. (lambda _
  851. (setenv "HOME" "/tmp")
  852. #t))
  853. (add-after 'configure 'fix-asdf
  854. (lambda* (#:key inputs #:allow-other-keys)
  855. (substitute* "Makefile.in"
  856. (("LISP_COMPILER) ")
  857. "LISP_COMPILER) --eval \"(require 'asdf)\" --eval \"(push \\\"$$(pwd)/\\\" asdf:*central-registry*)\" "))
  858. #t)))))
  859. (synopsis "Gemini and pleroma client with a terminal interface")
  860. (description
  861. "This package provides a Gemini and pleroma client with a terminal
  862. interface.")
  863. (home-page "https://www.autistici.org/interzona/tinmop.html")
  864. (license license:gpl3+)))
  865. (define-public telescope
  866. (package
  867. (name "telescope")
  868. (version "0.5.1")
  869. (source
  870. (origin
  871. (method url-fetch)
  872. (uri (string-append "https://github.com/omar-polo/telescope/releases/download/"
  873. version "/telescope-" version ".tar.gz"))
  874. (sha256
  875. (base32 "1fgv7gg2lwrjcihq6mkraqm10a6a7h430ikrjpcwfcpv1gvj8ckz"))))
  876. (build-system gnu-build-system)
  877. (arguments
  878. `(#:tests? #f)) ;no tests
  879. (native-inputs
  880. `(("gettext" ,gettext-minimal)
  881. ("pkg-config" ,pkg-config)))
  882. (inputs
  883. `(("libevent" ,libevent)
  884. ("libressl" ,libressl)
  885. ("ncurses" ,ncurses)))
  886. (home-page "https://git.omarpolo.com/telescope/about/")
  887. (synopsis "Gemini client with a terminal interface")
  888. (description "Telescope is a w3m-like browser for Gemini.")
  889. (license license:x11)))
  890. (define-public av-98
  891. (package
  892. (name "av-98")
  893. (version "1.0.1")
  894. (source
  895. (origin
  896. (method url-fetch)
  897. (uri (pypi-uri "AV-98" version))
  898. (sha256
  899. (base32
  900. "02fjnc2rvm010gb3i07p8r4xlhrmnv1wca1qymfjcymr7vm68h0i"))))
  901. (build-system python-build-system)
  902. (home-page "https://tildegit.org/solderpunk/AV-98/")
  903. (synopsis "Command line Gemini client")
  904. (description "AV-98 is an experimental client for the Gemini protocol.
  905. Features include
  906. @itemize
  907. @item TOFU or CA server certificate validation;
  908. @item Extensive client certificate support if an openssl binary is available;
  909. @item Ability to specify external handler programs for different MIME types;
  910. @item Gopher proxy support;
  911. @item Advanced navigation tools like tour and mark (as per VF-1);
  912. @item Bookmarks;
  913. @item IPv6 support;
  914. @item Support for any character encoding recognised by Python.
  915. @end itemize")
  916. (license license:bsd-2)))