From 22037a327a0340341df7ae71a9c1d3551c28c705 Mon Sep 17 00:00:00 2001 From: doncatnip Date: Tue, 20 Sep 2016 14:02:53 -0400 Subject: gnu: awesome: Update to 3.5.9. * gnu/packages/wm.scm (awesome): Update to 3.5.9. [inputs]: Add gobject-introspection, lua-lgi, cairo. Use latest available lua. [arguments]: Set lua search paths. Add cairo to LD_LIBRARY_PATH. Wrap binary in respect to those paths plus GI_TYPELIB_PATH. --- gnu/packages/wm.scm | 63 ++++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 46 insertions(+), 17 deletions(-) (limited to 'gnu/packages/wm.scm') diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm index 6275e6fea0..710a93397f 100644 --- a/gnu/packages/wm.scm +++ b/gnu/packages/wm.scm @@ -10,6 +10,7 @@ ;;; Copyright © 2016 Carlo Zancanaro ;;; Copyright © 2016 Ludovic Courtès ;;; Copyright © 2016 ng0 +;;; Copyright © 2016 doncatnip ;;; ;;; This file is part of GNU Guix. ;;; @@ -383,7 +384,7 @@ experience.") (define-public awesome (package (name "awesome") - (version "3.4.15") + (version "3.5.9") (source (origin (method url-fetch) (uri (string-append @@ -391,7 +392,7 @@ experience.") version ".tar.xz")) (sha256 (base32 - "1m910lr7wkw2dgzmirfvz7dasfswhhccdf65l21iiciv24c3w1bb")) + "0kynair1ykr74b39a4gcm2y24viial64337cf26nhlc7azjbby67")) (modules '((guix build utils) (srfi srfi-19))) (snippet @@ -418,12 +419,14 @@ experience.") ("dbus" ,dbus) ("gdk-pixbuf" ,gdk-pixbuf) ("glib" ,glib) + ("gobject-introspection" ,gobject-introspection) ("imlib2" ,imlib2) ("libev" ,libev) ("libxcb" ,libxcb) ("libxcursor" ,libxcursor) ("libxdg-basedir" ,libxdg-basedir) - ("lua" ,lua-5.1) + ("lua" ,lua) + ("lua-lgi",lua-lgi) ("pango" ,pango) ("startup-notification" ,startup-notification) ("xcb-util" ,xcb-util) @@ -437,20 +440,46 @@ experience.") ;; '--no-name' is used, which removes timestamps from gzip output. #:configure-flags '("-DCOMPRESS_MANPAGES=off") - #:phases (modify-phases %standard-phases - (add-before 'build 'xmlto-skip-validation - (lambda _ - ;; We can't download the necessary schema, so so skip - ;; validation and assume they're valid. - (substitute* "../build/CMakeFiles/man.dir/build.make" - (("/xmlto") - (string-append "/xmlto --skip-validation"))) - #t)) - (replace 'check - (lambda _ - ;; There aren't any tests, so just make sure the binary - ;; gets built and can be run successfully. - (zero? (system* "../build/awesome" "-v"))))))) + #:phases + (modify-phases %standard-phases + (add-before 'build 'xmlto-skip-validation + (lambda _ + ;; We can't download the necessary schema, so so skip + ;; validation and assume they're valid. + (substitute* "../build/CMakeFiles/man.dir/build.make" + (("/xmlto") + (string-append "/xmlto --skip-validation"))) + #t)) + (add-before 'configure 'set-lua-paths + (lambda* (#:key inputs #:allow-other-keys) + ;; The build process needs to load cairo dynamically. + (let* ((cairo (string-append + (assoc-ref inputs "cairo") "/lib" )) + (lua-lgi (assoc-ref inputs "lua-lgi") )) + (setenv "LD_LIBRARY_PATH" cairo ) + (setenv "LUA_PATH" (string-append lua-lgi + "/share/lua/5.2/?.lua")) + (setenv "LUA_CPATH" (string-append lua-lgi + "/lib/lua/5.2/?.so")) + #t))) + (replace 'check + (lambda _ + ;; There aren't any tests, so just make sure the binary + ;; gets built and can be run successfully. + (zero? (system* "../build/awesome" "-v")))) + (add-after 'install 'wrap + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((awesome (assoc-ref outputs "out")) + (cairo (string-append + (assoc-ref inputs "cairo") "/lib" )) + (lua-lgi (assoc-ref inputs "lua-lgi") )) + (wrap-program (string-append awesome "/bin/awesome") + `("GI_TYPELIB_PATH" ":" prefix (,(getenv "GI_TYPELIB_PATH"))) + `("LD_LIBRARY_PATH" suffix (, cairo)) + `("LUA_PATH" suffix (,(string-append lua-lgi + "/share/lua/5.2/?.lua"))) + `("LUA_CPATH" suffix (,(string-append + lua-lgi "/lib/lua/5.2/?.so")))))))))) (synopsis "Highly configurable window manager") (description "Awesome has been designed as a framework window manager. It is fast, small, -- cgit v1.2.3