1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Tomáš Čech <sleep_walker@suse.cz>
3 ;;; Copyright © 2015 Daniel Pimentel <d4n1@member.fsf.org>
4 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
5 ;;; Copyright © 2017 ng0 <ng0@n0.is>
6 ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
7 ;;; Copyright © 2018 Timo Eisenmann <eisenmann@fn.de>
9 ;;; This file is part of GNU Guix.
11 ;;; GNU Guix is free software; you can redistribute it and/or modify it
12 ;;; under the terms of the GNU General Public License as published by
13 ;;; the Free Software Foundation; either version 3 of the License, or (at
14 ;;; your option) any later version.
16 ;;; GNU Guix is distributed in the hope that it will be useful, but
17 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
18 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 ;;; GNU General Public License for more details.
21 ;;; You should have received a copy of the GNU General Public License
22 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
24 (define-module (gnu packages enlightenment)
25 #:use-module ((guix licenses) #:prefix license:)
26 #:use-module (guix packages)
27 #:use-module (guix download)
28 #:use-module (guix build-system gnu)
29 #:use-module (guix build-system meson)
30 #:use-module (guix build-system python)
31 #:use-module (gnu packages)
32 #:use-module (gnu packages avahi)
33 #:use-module (gnu packages bash)
34 #:use-module (gnu packages check)
35 #:use-module (gnu packages code)
36 #:use-module (gnu packages compression)
37 #:use-module (gnu packages curl)
38 #:use-module (gnu packages fontutils)
39 #:use-module (gnu packages freedesktop)
40 #:use-module (gnu packages fribidi)
41 #:use-module (gnu packages game-development)
42 #:use-module (gnu packages gettext)
43 #:use-module (gnu packages ghostscript)
44 #:use-module (gnu packages gl)
45 #:use-module (gnu packages glib)
46 #:use-module (gnu packages gnome)
47 #:use-module (gnu packages gstreamer)
48 #:use-module (gnu packages gtk)
49 #:use-module (gnu packages ibus)
50 #:use-module (gnu packages image)
51 #:use-module (gnu packages linux)
52 #:use-module (gnu packages llvm)
53 #:use-module (gnu packages lua)
54 #:use-module (gnu packages pdf)
55 #:use-module (gnu packages perl)
56 #:use-module (gnu packages photo)
57 #:use-module (gnu packages pkg-config)
58 #:use-module (gnu packages pulseaudio)
59 #:use-module (gnu packages python)
60 #:use-module (gnu packages python-xyz)
61 #:use-module (gnu packages tls)
62 #:use-module (gnu packages video)
63 #:use-module (gnu packages xdisorg)
64 #:use-module (gnu packages xorg)
65 #:use-module (ice-9 match))
74 "https://download.enlightenment.org/rel/libs/efl/efl-"
78 "0q9g4j7k10s1a8rv2ca9v9lydh7ml3zsrqvgncc4qhvdl76208nn"))))
79 (build-system meson-build-system)
82 ("gettext" ,gettext-minimal)
83 ("pkg-config" ,pkg-config)))
87 ("gstreamer" ,gstreamer)
88 ("gst-plugins-base" ,gst-plugins-base)
93 ("libspectre" ,libspectre)
95 ("libxcomposite" ,libxcomposite)
96 ("libxcursor" ,libxcursor)
97 ("libxdamage" ,libxdamage)
98 ("libxdmcp" ,libxdmcp)
101 ("libxfixes" ,libxfixes)
102 ("libxinerama" ,libxinerama)
104 ("libxrandr" ,libxrandr)
105 ("libxrender" ,libxrender)
106 ("libxss" ,libxscrnsaver)
109 ("wayland-protocols" ,wayland-protocols)))
111 ;; All these inputs are in package config files in section
118 ("fontconfig" ,fontconfig)
119 ("freetype" ,freetype)
122 ("harfbuzz" ,harfbuzz)
124 ("libinput" ,libinput-minimal)
127 ("libsndfile" ,libsndfile)
131 ("libxkbcommon" ,libxkbcommon)
134 ("pulseaudio" ,pulseaudio)
135 ("util-linux" ,util-linux)
139 `(#:configure-flags '("-Dsystemd=false"
140 "-Dembedded-lz4=false"
141 "-Devas-loaders-disabler=json"
142 "-Dbuild-examples=false"
143 ;(string-append "-Ddictionaries-hyphen-dir="
144 ; (assoc-ref %build-inputs "hyphen")
147 "-Dnetwork-backend=connman"
148 ,@(match (%current-system)
154 "-Dwl-deprecated=true" ; ecore_wayland
155 "-Ddrm-deprecated=true" ; ecore_drm
158 #:tests? #f ; Many tests fail due to timeouts and network requests.
160 (modify-phases %standard-phases
161 ;; If we don't hardcode the location of libcurl.so then we
162 ;; have to wrap the outputs of efl's dependencies in curl.
163 (add-after 'unpack 'hardcode-libcurl-location
164 (lambda* (#:key inputs #:allow-other-keys)
165 (let* ((curl (assoc-ref inputs "curl"))
166 (lib (string-append curl "/lib/")))
167 (substitute* "src/lib/ecore_con/ecore_con_url_curl.c"
168 (("libcurl.so.?" libcurl) ; libcurl.so.[45]
169 (string-append lib libcurl)))
171 (add-after 'unpack 'fix-install-paths
173 (substitute* "dbus-services/meson.build"
175 "install_dir: join_paths(dir_data, 'dbus-1', 'services'))\n"))
176 (substitute* "src/tests/elementary/meson.build"
177 (("dir_data") "meson.source_root(), 'test-output'"))
179 (add-after 'unpack 'set-home-directory
180 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
181 (lambda _ (setenv "HOME" "/tmp") #t)))))
182 (home-page "https://www.enlightenment.org/about-efl")
183 (synopsis "Enlightenment Foundation Libraries")
185 "Enlightenment Foundation Libraries is a set of libraries developed
186 for Enlightenment. Libraries covers data serialization, wide support for
187 graphics rendering, UI layout and themes, interaction with OS, access to
188 removable devices or support for multimedia.")
189 ;; Different parts are under different licenses.
190 (license (list license:bsd-2 license:lgpl2.1 license:zlib))))
192 (define-public terminology
199 (string-append "https://download.enlightenment.org/rel/apps/"
200 "terminology/terminology-" version ".tar.xz"))
203 "0v4amfg8ji0mb6j7kcxh3wz1xw5zyxg4rw6ylx17rfw2nc1yamfy"))
204 (modules '((guix build utils)))
205 ;; Remove the bundled fonts.
208 (delete-file-recursively "data/fonts")
209 (substitute* "data/meson.build"
210 (("subdir\\('fonts'\\)") ""))
212 (build-system meson-build-system)
214 `(#:configure-flags (list "-Dtests=true"
215 (string-append "-Dedje-cc="
216 (assoc-ref %build-inputs "efl")
219 (modify-phases %standard-phases
220 (add-after 'unpack 'set-home-directory
221 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
222 (lambda _ (setenv "HOME" "/tmp") #t))
225 (with-directory-excursion
226 (string-append "../" ,name "-" ,version "/tests")
227 (invoke "sh" "run_tests.sh" "--verbose"
228 "-t" "../../build/src/bin/tytest"))))
229 (add-after 'install 'remove-test-binary
230 (lambda* (#:key outputs #:allow-other-keys)
231 ;; This file is not meant to be installed.
232 (delete-file (string-append (assoc-ref outputs "out")
236 `(("gettext" ,gettext-minimal)
238 ("pkg-config" ,pkg-config)))
241 (home-page "https://www.enlightenment.org/about-terminology")
242 (synopsis "Powerful terminal emulator based on EFL")
244 "Terminology is fast and feature rich terminal emulator. It is solely
245 based on Enlightenment Foundation Libraries. It supports multiple tabs, UTF-8,
246 URL and local path detection, themes, popup based content viewer for non-text
248 (license license:bsd-2)))
258 "https://download.enlightenment.org/rel/apps/rage/rage-"
262 "04fdk23bbgvni212zrfy4ndg7vmshbsjgicrhckdvhay87pk9i75"))))
263 (build-system meson-build-system)
266 (modify-phases %standard-phases
267 (add-after 'unpack 'set-home-directory
268 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
269 (lambda _ (setenv "HOME" "/tmp") #t)))))
271 `(("pkg-config" ,pkg-config)))
274 (home-page "https://www.enlightenment.org/about-rage")
275 (synopsis "Video and audio player based on EFL")
277 "Rage is a video and audio player written with Enlightenment Foundation
278 Libraries with some extra bells and whistles.")
279 (license license:bsd-2)))
281 (define-public enlightenment
283 (name "enlightenment")
288 (string-append "https://download.enlightenment.org/rel/apps/"
289 "enlightenment/enlightenment-" version ".tar.xz"))
292 "0d1cyl07w9pvi2pf029kablazks2q9aislzl46b6fq5m1465jc75"))
293 (patches (search-patches "enlightenment-fix-setuid-path.patch"))))
294 (build-system meson-build-system)
296 `(#:configure-flags '("-Dsystemd=false")
298 (modify-phases %standard-phases
299 (delete 'bootstrap) ; We don't want to run the autogen script.
300 (add-before 'configure 'set-system-actions
301 (lambda* (#:key inputs #:allow-other-keys)
302 (setenv "HOME" "/tmp")
303 (let ((xkeyboard (assoc-ref inputs "xkeyboard-config"))
304 (setxkbmap (assoc-ref inputs "setxkbmap"))
305 (utils (assoc-ref inputs "util-linux"))
306 (libc (assoc-ref inputs "libc"))
307 (bluez (assoc-ref inputs "bluez"))
308 (efl (assoc-ref inputs "efl")))
309 ;; We need to patch the path to 'base.lst' to be able
310 ;; to switch the keyboard layout in E.
311 (substitute* (list "src/modules/xkbswitch/e_mod_parse.c"
312 "src/modules/wizard/page_011.c")
313 (("/usr/share/X11/xkb/rules/xorg.lst")
314 (string-append xkeyboard
315 "/share/X11/xkb/rules/base.lst")))
316 (substitute* "src/bin/e_xkb.c"
318 (string-append "\"" setxkbmap "/bin/setxkbmap \"")))
319 (substitute* (list "src/bin/e_intl.c"
320 "src/modules/conf_intl/e_int_config_intl.c"
321 "src/modules/wizard/page_010.c")
322 (("locale -a") (string-append libc "/bin/locale -a")))
323 (substitute* "src/bin/e_import_config_dialog.c"
324 (("%s/edje_cc -v %s %s %s\", e_prefix_bin_get\\(\\)")
325 (string-append efl "/bin/edje_cc -v %s %s %s\"")))
326 (substitute* "src/modules/everything/evry_plug_apps.c"
328 (substitute* "data/etc/meson.build"
329 (("/bin/mount") (string-append utils "/bin/mount"))
330 (("/bin/umount") (string-append utils "/bin/umount"))
331 (("/usr/bin/eject") (string-append utils "/bin/eject"))
332 (("/usr/bin/l2ping") (string-append bluez "/bin/l2ling"))
333 (("/bin/rfkill") (string-append utils "/sbin/rfkill"))
334 (("SUSPEND = ''") "SUSPEND = '/run/current-system/profile/bin/loginctl suspend'")
335 (("HIBERNATE = ''") "HIBERNATE = '/run/current-system/profile/bin/loginctl hibernate'")
336 (("/sbin/shutdown -h now") "/run/current-system/profile/bin/loginctl poweroff now")
337 (("/sbin/shutdown -r now") "/run/current-system/profile/bin/loginctl reboot now"))
340 `(("gettext" ,gettext-minimal)
341 ("pkg-config" ,pkg-config)
342 ("util-linux" ,util-linux)))
344 `(("alsa-lib" ,alsa-lib)
348 ("freetype" ,freetype)
351 ("linux-pam" ,linux-pam)
352 ("puleseaudio" ,pulseaudio)
353 ("setxkbmap" ,setxkbmap)
354 ("xcb-util-keysyms" ,xcb-util-keysyms)
355 ("xkeyboard-config" ,xkeyboard-config)))
356 (home-page "https://www.enlightenment.org/about-enlightenment")
357 (synopsis "Lightweight desktop environment")
359 "Enlightenment is resource friendly desktop environment with integrated
360 file manager, wide range of configuration options, plugin system allowing to
361 unload unused functionality, with support for touchscreen and suitable for
363 (license license:bsd-2)))
365 (define-public python-efl
372 (uri (string-append "https://download.enlightenment.org/rel/bindings/"
373 "python/python-efl-" version ".tar.xz"))
376 "16yn6a1b9167nfmryyi44ma40m20ansfpwgrvqzfvwix7qaz9pib"))
377 (modules '((guix build utils)))
378 ;; Remove files generated by Cython
381 (copy-file "efl/dbus_mainloop/e_dbus.c" "efl/dbus_mainloop/e_dbus.q")
382 (for-each delete-file (find-files "efl" ".*\\.c$"))
383 (delete-file "efl/eo/efl.eo_api.h")
384 (copy-file "efl/dbus_mainloop/e_dbus.q" "efl/dbus_mainloop/e_dbus.c")
385 (delete-file "efl/dbus_mainloop/e_dbus.q")
387 (build-system python-build-system)
390 (modify-phases %standard-phases
393 (setenv "ENABLE_CYTHON" "1")
394 (invoke "python" "setup.py" "build")))
395 (add-before 'build 'set-flags
398 (string-append "-I" (assoc-ref %build-inputs "python-dbus")
399 "/include/dbus-1.0"))
401 (add-before 'check 'set-environment
403 ;; Some tests require write access to HOME.
404 (setenv "HOME" "/tmp")
405 ;; These tests try to connect to the internet.
406 (delete-file "tests/ecore/test_09_file_download.py")
407 (delete-file "tests/ecore/test_11_con.py")
410 `(("pkg-config" ,pkg-config)
411 ("python-cython" ,python-cython)))
414 ("python-dbus" ,python-dbus)))
415 (home-page "https://www.enlightenment.org/")
416 (synopsis "Python bindings for EFL")
418 "PYTHON-EFL are the python bindings for the whole Enlightenment Foundation
419 Libraries stack (eo, evas, ecore, edje, emotion, ethumb and elementary).")
420 (license license:lgpl3)))
422 (define-public python2-efl
423 (package-with-python2 python-efl))
432 (uri (string-append "https://download.enlightenment.org/rel/apps/edi/"
433 name "-" version ".tar.xz"))
436 "0iqkah327ms5m7k054hcik2l9v68i4mg9yy52brprfqpd5jk7pw8"))))
437 (build-system gnu-build-system)
440 (modify-phases %standard-phases
441 (add-after 'unpack 'set-home-directory
442 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
443 (lambda _ (setenv "HOME" "/tmp") #t)))
444 #:tests? #f)) ; tests require running dbus service
446 `(("pkg-config" ,pkg-config)))
450 (home-page "https://www.enlightenment.org/about-edi")
451 (synopsis "Development environment for Enlightenment")
452 (description "EDI is a development environment designed for and built using
453 the EFL. It's aim is to create a new, native development environment for Linux
454 that tries to lower the barrier to getting involved in Enlightenment development
455 and in creating applications based on the Enlightenment Foundation Library suite.")
456 (license (list license:public-domain ; data/extra/skeleton
457 license:gpl2)))) ; edi
465 (uri (pypi-uri "Lekha" version))
468 "0zr6i74ik58pbzrd7r9l7sawqbdv0r2c1a9927qkqzwga27x8j15"))))
469 (build-system python-build-system)
471 `(#:tests? #f ; no test target
474 (modify-phases %standard-phases
475 (add-after 'unpack 'fix-data-location
476 (lambda _ (substitute* "setup.py"
480 `(("python2-efl" ,python2-efl)
481 ("python2-pypdf2" ,python2-pypdf2)
482 ("python2-pyxdg" ,python2-pyxdg)))
483 (synopsis "Simple PDF viewer")
485 "Simple PDF viewer based on the Enlightenment Foundation Libraries.")
486 (home-page "https://github.com/kaihu/lekha")
487 (license license:gpl3+)))
489 (define-public ephoto
496 (uri (list (string-append "http://www.smhouston.us/stuff/ephoto-"
498 (string-append "https://download.enlightenment.org/rel/"
499 "apps/ephoto/ephoto-" version ".tar.xz")))
502 "1q7v9abjp9jrs08xc7pqaac64yzax24dk1snjb9rciarzzh3mlzy"))))
503 (build-system gnu-build-system)
506 (modify-phases %standard-phases
507 (add-after 'unpack 'set-home-directory
508 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
509 (lambda _ (setenv "HOME" "/tmp") #t)))))
512 ("pkg-config" ,pkg-config)))
515 (home-page "http://smhouston.us/ephoto/")
516 (synopsis "EFL image viewer/editor/manipulator/slideshow creator")
517 (description "Ephoto is an image viewer and editor written using the
518 @dfn{Enlightenment Foundation Libraries} (EFL). It focuses on simplicity and
519 ease of use, while taking advantage of the speed and small footprint the EFL
522 Ephoto’s features include:
524 @item Browsing the file system and displaying images in an easy-to-use grid view.
525 @item Browsing images in a single image view format.
526 @item Viewing images in a slideshow.
527 @item Editing your image with features such as cropping, auto enhance,
528 blurring, sharpening, brightness/contrast/gamma adjustments, hue/saturation/value
529 adjustments, and color level adjustment.
530 @item Applying artistic filters to your image such as black and white and old
532 @item Drag And Drop along with file operations to easily maintain your photo
536 license:bsd-2 ; Ephoto's thumbnailing code
539 (define-public evisum
546 (uri (string-append "https://download.enlightenment.org/rel/apps/"
547 "evisum/evisum-" version ".tar.xz"))
550 "1rg3kri6j8nmab0kdljnmcc096c8ibgwzvbhqr0b25xpmrq8bcac"))))
551 (build-system gnu-build-system)
553 '(#:tests? #f ; no tests
554 #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
556 (modify-phases %standard-phases
557 (delete 'configure) ; no configure phase
558 (add-after 'unpack 'set-environmental-variables
559 (lambda _ (setenv "CC" (which "gcc")) #t)))))
561 `(("pkg-config" ,pkg-config)))
563 `(("alsa-lib" ,alsa-lib)
566 (home-page "https://www.enlightenment.org")
567 (synopsis "EFL process viewer")
569 "This is a process monitor and system monitor using the
570 @dfn{Enlightenment Foundation Libraries} (EFL).")
571 (license license:bsd-2)))