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 Efraim Flashner <efraim@flashner.co.il>
5 ;;; Copyright © 2017 ng0 <ng0@n0.is>
6 ;;; Copyright © 2018 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 bash)
33 #:use-module (gnu packages check)
34 #:use-module (gnu packages code)
35 #:use-module (gnu packages compression)
36 #:use-module (gnu packages curl)
37 #:use-module (gnu packages fontutils)
38 #:use-module (gnu packages freedesktop)
39 #:use-module (gnu packages fribidi)
40 #:use-module (gnu packages game-development)
41 #:use-module (gnu packages gettext)
42 #:use-module (gnu packages ghostscript)
43 #:use-module (gnu packages gl)
44 #:use-module (gnu packages glib)
45 #:use-module (gnu packages gnome)
46 #:use-module (gnu packages gstreamer)
47 #:use-module (gnu packages gtk)
48 #:use-module (gnu packages image)
49 #:use-module (gnu packages linux)
50 #:use-module (gnu packages llvm)
51 #:use-module (gnu packages lua)
52 #:use-module (gnu packages pdf)
53 #:use-module (gnu packages perl)
54 #:use-module (gnu packages photo)
55 #:use-module (gnu packages pkg-config)
56 #:use-module (gnu packages pulseaudio)
57 #:use-module (gnu packages python)
58 #:use-module (gnu packages python-xyz)
59 #:use-module (gnu packages tls)
60 #:use-module (gnu packages video)
61 #:use-module (gnu packages xdisorg)
62 #:use-module (gnu packages xorg)
63 #:use-module (ice-9 match))
72 "https://download.enlightenment.org/rel/libs/efl/efl-"
74 (patches (search-patches "efl-mesa-compat.patch"))
77 "0a5907h896pvpix7a6idc2fspzy6d78xrzf84k8y9fyvnd14nxs4"))))
78 (outputs '("out" ; 49 MB
80 (build-system gnu-build-system)
82 `(("pkg-config" ,pkg-config)))
84 `(("alsa-lib" ,alsa-lib)
86 ("ghostscript" ,ghostscript)
88 ("gstreamer" ,gstreamer)
89 ("gst-plugins-base" ,gst-plugins-base)
94 ("libspectre" ,libspectre)
99 ("libxcomposite" ,libxcomposite)
100 ("libxcursor" ,libxcursor)
101 ("libxdamage" ,libxdamage)
102 ("libxdmcp" ,libxdmcp)
105 ("libxfixes" ,libxfixes)
106 ("libxinerama" ,libxinerama)
108 ("libxrandr" ,libxrandr)
109 ("libxrender" ,libxrender)
110 ("libxscrnsaver" ,libxscrnsaver)
113 ("openjpeg" ,openjpeg-1)
115 ("printproto" ,printproto)
116 ("wayland-protocols" ,wayland-protocols)
119 ("xorgproto" ,xorgproto)))
121 ;; All these inputs are in package config files in section
123 `(("bullet" ,bullet) ; ephysics.pc
124 ("dbus" ,dbus) ; eldbus.pc, elementary.pc, elocation.pc, ethumb_client.pc
125 ("eudev" ,eudev) ; eeze.pc
126 ("fontconfig" ,fontconfig) ; evas.pc, evas-cxx.pc
127 ("freetype" ,freetype) ; evas.pc, evas-cxx.pc
128 ("fribidi" ,fribidi) ; evas.pc, evas-cxx.pc
129 ("glib" ,glib) ; ecore.pc, ecore-cxx.pc
130 ("harfbuzz" ,harfbuzz) ; evas.pc, evas-cxx.pc
131 ("luajit" ,luajit) ; elua.pc, evas.pc, evas-cxx.pc
132 ("libinput" ,libinput-minimal) ; elput.pc
133 ("libpng" ,libpng) ; evas.pc, evas-cxx.pc
134 ("libsndfile" ,libsndfile) ; ecore-audio.pc, ecore-audio-cxx.pc
135 ("libxkbcommon" ,libxkbcommon) ; ecore-wl2.pc, elementary.pc, elput.pc
136 ("mesa" ,mesa) ; ecore-drm2.pc
137 ("openssl" ,openssl) ; ecore-con.pc, eet.pc, eet-cxx.pc, emile.pc
138 ("pulseaudio" ,pulseaudio) ; ecore-audio.pc, ecore-audio-cxx.pc
139 ("util-linux" ,util-linux) ; mount: eeze.pc
140 ("wayland" ,wayland) ; ecore-wl2.pc, elementary.pc
141 ("zlib" ,zlib))) ; eet.pc, eet-cxx.pc, emile.pc
143 `(#:configure-flags '("--disable-silent-rules"
145 "--with-profile=release"
148 "--enable-image-loader-webp"
149 "--enable-multisense"
150 ,@(match (%current-system)
152 '("--with-opengl=es" "--with-egl"))
154 '("--with-opengl=full")))
161 (modify-phases %standard-phases
162 ;; If we don't hardcode the location of libcurl.so then we
163 ;; have to wrap the outputs of efl's dependencies in curl.
164 (add-after 'unpack 'hardcode-libcurl-location
165 (lambda* (#:key inputs #:allow-other-keys)
166 (let* ((curl (assoc-ref inputs "curl"))
167 (lib (string-append curl "/lib/")))
168 (substitute* "src/lib/ecore_con/ecore_con_url_curl.c"
169 (("libcurl.so.?" libcurl) ; libcurl.so.[45]
170 (string-append lib libcurl)))
172 (add-after 'unpack 'set-home-directory
173 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
174 (lambda _ (setenv "HOME" "/tmp") #t)))))
175 (home-page "https://www.enlightenment.org/about-efl")
176 (synopsis "Enlightenment Foundation Libraries")
178 "Enlightenment Foundation Libraries is a set of libraries developed
179 for Enlightenment. Libraries covers data serialization, wide support for
180 graphics rendering, UI layout and themes, interaction with OS, access to
181 removable devices or support for multimedia.")
182 ;; Different parts are under different licenses.
183 (license (list license:bsd-2 license:lgpl2.1 license:zlib))))
185 (define-public terminology
192 (string-append "https://download.enlightenment.org/rel/apps/"
193 "terminology/terminology-" version ".tar.xz"))
196 "0q1y7fadj42n23aspx9y8hm4w4xlc316wc3415wnf75ibsx08ngd"))
197 (modules '((guix build utils)))
198 ;; Remove the bundled fonts.
201 (delete-file-recursively "data/fonts")
202 (substitute* "data/meson.build"
203 (("subdir\\('fonts'\\)") ""))
205 (build-system meson-build-system)
207 `(#:configure-flags '("-Dtests=true")
209 (modify-phases %standard-phases
210 (add-after 'unpack 'set-home-directory
211 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
212 (lambda _ (setenv "HOME" "/tmp") #t))
215 (with-directory-excursion
216 (string-append "../" ,name "-" ,version "/tests")
217 (invoke "sh" "run_tests.sh" "--verbose"
218 "-t" "../../build/src/bin/tytest"))))
219 (add-after 'install 'remove-test-binary
220 (lambda* (#:key outputs #:allow-other-keys)
221 ;; This file is not meant to be installed.
222 (delete-file (string-append (assoc-ref outputs "out")
226 `(("gettext" ,gettext-minimal)
228 ("pkg-config" ,pkg-config)))
231 (home-page "https://www.enlightenment.org/about-terminology")
232 (synopsis "Powerful terminal emulator based on EFL")
234 "Terminology is fast and feature rich terminal emulator. It is solely
235 based on Enlightenment Foundation Libraries. It supports multiple tabs, UTF-8,
236 URL and local path detection, themes, popup based content viewer for non-text
238 (license license:bsd-2)))
248 "https://download.enlightenment.org/rel/apps/rage/rage-"
252 "0gfzdd4jg78bkmj61yg49w7bzspl5m1nh6agqgs8k7qrq9q26xqy"))))
253 (build-system meson-build-system)
256 (modify-phases %standard-phases
257 (add-after 'unpack 'set-home-directory
258 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
259 (lambda _ (setenv "HOME" "/tmp") #t)))))
261 `(("pkg-config" ,pkg-config)))
264 (home-page "https://www.enlightenment.org/about-rage")
265 (synopsis "Video and audio player based on EFL")
267 "Rage is a video and audio player written with Enlightenment Foundation
268 Libraries with some extra bells and whistles.")
269 (license license:bsd-2)))
271 (define-public enlightenment
273 (name "enlightenment")
278 (string-append "https://download.enlightenment.org/rel/apps/"
279 name "/" name "-" version ".tar.xz"))
282 "0ygy891rrw5c7lhk539nhif77j88phvz2h0fhx172iaridy9kx2r"))
283 (patches (search-patches "enlightenment-fix-setuid-path.patch"))))
284 (build-system gnu-build-system)
287 (modify-phases %standard-phases
288 (add-before 'configure 'set-system-actions
289 (lambda* (#:key inputs #:allow-other-keys)
290 (let ((xkeyboard (assoc-ref inputs "xkeyboard-config"))
291 (setxkbmap (assoc-ref inputs "setxkbmap"))
292 (utils (assoc-ref inputs "util-linux"))
293 (libc (assoc-ref inputs "libc"))
294 (efl (assoc-ref inputs "efl")))
295 ;; We need to patch the path to 'base.lst' to be able
296 ;; to switch the keyboard layout in E.
297 (substitute* (list "src/modules/xkbswitch/e_mod_parse.c"
298 "src/modules/wizard/page_011.c")
299 (("/usr/share/X11/xkb/rules/xorg.lst")
300 (string-append xkeyboard
301 "/share/X11/xkb/rules/base.lst")))
302 (substitute* "src/bin/e_xkb.c"
304 (string-append "\"" setxkbmap "/bin/setxkbmap \"")))
305 (substitute* (list "src/bin/e_intl.c"
306 "src/modules/conf_intl/e_int_config_intl.c"
307 "src/modules/wizard/page_010.c")
308 (("locale -a") (string-append libc "/bin/locale -a")))
309 (substitute* "src/bin/e_import_config_dialog.c"
310 (("%s/edje_cc -v %s %s %s\", e_prefix_bin_get\\(\\)")
311 (string-append efl "/bin/edje_cc -v %s %s %s\"")))
312 (substitute* "src/modules/everything/evry_plug_apps.c"
314 (substitute* "configure"
315 (("/bin/mount") (string-append utils "/bin/mount"))
316 (("/bin/umount") (string-append utils "/bin/umount"))
317 (("/usr/bin/eject") (string-append utils "/bin/eject"))
318 (("/etc/acpi/sleep.sh force") "/run/current-system/profile/bin/loginctl suspend")
319 (("/etc/acpi/hibernate.sh force") "/run/current-system/profile/bin/loginctl hibernate")
320 (("/sbin/shutdown -h now") "/run/current-system/profile/bin/loginctl poweroff now")
321 (("/sbin/shutdown -r now") "/run/current-system/profile/bin/loginctl reboot now"))
324 `(("gettext" ,gettext-minimal)
325 ("pkg-config" ,pkg-config)
326 ("util-linux" ,util-linux)))
328 `(("alsa-lib" ,alsa-lib)
331 ("freetype" ,freetype)
334 ("linux-pam" ,linux-pam)
335 ("setxkbmap" ,setxkbmap)
336 ("xcb-util-keysyms" ,xcb-util-keysyms)
337 ("xkeyboard-config" ,xkeyboard-config)))
338 (home-page "https://www.enlightenment.org/about-enlightenment")
339 (synopsis "Lightweight desktop environment")
341 "Enlightenment is resource friendly desktop environment with integrated
342 file manager, wide range of configuration options, plugin system allowing to
343 unload unused functionality, with support for touchscreen and suitable for
345 (license license:bsd-2)))
347 (define-public python-efl
354 (uri (string-append "http://download.enlightenment.org/rel/bindings/"
355 "python/python-efl-" version ".tar.xz"))
358 "08x2cv8hnf004c3711250wrax21ffj5y8951pvk77h98als4pq47"))))
359 (build-system python-build-system)
362 (modify-phases %standard-phases
365 (setenv "ENABLE_CYTHON" "1")
366 (invoke "python" "setup.py" "build")))
367 (add-before 'build 'set-flags
370 (string-append "-I" (assoc-ref %build-inputs "python-dbus")
371 "/include/dbus-1.0"))
373 (add-before 'check 'set-environment
375 ;; Some tests require write access to HOME.
376 (setenv "HOME" "/tmp")
377 ;; These tests try to connect to the internet.
378 (delete-file "tests/ecore/test_09_file_download.py")
379 (delete-file "tests/ecore/test_11_con.py")
382 `(("pkg-config" ,pkg-config)
383 ("python-cython" ,python-cython)))
386 ("python-dbus" ,python-dbus)))
387 (home-page "https://www.enlightenment.org/")
388 (synopsis "Python bindings for EFL")
390 "PYTHON-EFL are the python bindings for the whole Enlightenment Foundation
391 Libraries stack (eo, evas, ecore, edje, emotion, ethumb and elementary).")
392 (license license:lgpl3)))
394 (define-public python2-efl
395 (package-with-python2 python-efl))
404 (uri (string-append "https://download.enlightenment.org/rel/apps/edi/"
405 name "-" version ".tar.xz"))
408 "0iqkah327ms5m7k054hcik2l9v68i4mg9yy52brprfqpd5jk7pw8"))))
409 (build-system gnu-build-system)
412 (modify-phases %standard-phases
413 (add-after 'unpack 'set-home-directory
414 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
415 (lambda _ (setenv "HOME" "/tmp") #t)))
416 #:tests? #f)) ; tests require running dbus service
418 `(("pkg-config" ,pkg-config)))
422 (home-page "https://www.enlightenment.org/about-edi")
423 (synopsis "Development environment for Enlightenment")
424 (description "EDI is a development environment designed for and built using
425 the EFL. It's aim is to create a new, native development environment for Linux
426 that tries to lower the barrier to getting involved in Enlightenment development
427 and in creating applications based on the Enlightenment Foundation Library suite.")
428 (license (list license:public-domain ; data/extra/skeleton
429 license:gpl2)))) ; edi
437 (uri (pypi-uri "Lekha" version))
440 "0zr6i74ik58pbzrd7r9l7sawqbdv0r2c1a9927qkqzwga27x8j15"))))
441 (build-system python-build-system)
443 `(#:tests? #f ; no test target
446 (modify-phases %standard-phases
447 (add-after 'unpack 'fix-data-location
448 (lambda _ (substitute* "setup.py"
452 `(("python2-efl" ,python2-efl)
453 ("python2-pypdf2" ,python2-pypdf2)
454 ("python2-pyxdg" ,python2-pyxdg)))
455 (synopsis "Simple PDF viewer")
457 "Simple PDF viewer based on the Enlightenment Foundation Libraries.")
458 (home-page "https://github.com/kaihu/lekha")
459 (license license:gpl3+)))
461 (define-public ephoto
468 (uri (list (string-append "http://www.smhouston.us/stuff/ephoto-"
470 (string-append "https://download.enlightenment.org/rel/"
471 "apps/ephoto/ephoto-" version ".tar.xz")))
474 "04kli43sfsy6s660g13pjc0kjmgdcmq8m4qh02vvpcwv60mf9mgz"))))
475 (build-system gnu-build-system)
478 (modify-phases %standard-phases
479 (add-after 'unpack 'set-home-directory
480 ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2
481 (lambda _ (setenv "HOME" "/tmp") #t)))))
484 ("pkg-config" ,pkg-config)))
487 (home-page "http://smhouston.us/ephoto/")
488 (synopsis "EFL image viewer/editor/manipulator/slideshow creator")
489 (description "Ephoto is an image viewer and editor written using the
490 @dfn{Enlightenment Foundation Libraries} (EFL). It focuses on simplicity and
491 ease of use, while taking advantage of the speed and small footprint the EFL
494 Ephoto’s features include:
496 @item Browsing the file system and displaying images in an easy-to-use grid view.
497 @item Browsing images in a single image view format.
498 @item Viewing images in a slideshow.
499 @item Editing your image with features such as cropping, auto enhance,
500 blurring, sharpening, brightness/contrast/gamma adjustments, hue/saturation/value
501 adjustments, and color level adjustment.
502 @item Applying artistic filters to your image such as black and white and old
504 @item Drag And Drop along with file operations to easily maintain your photo
508 license:bsd-2 ; Ephoto's thumbnailing code