Skip to content

Commit

Permalink
awesome: Allows awesome to load svg images.
Browse files Browse the repository at this point in the history
Awesome can load SVG images, just like it can do PNG, through gdk.

The support for SVG images through GDK needs librvsg.

This commits adds the plumbing necessary in the wrapper that makes
awesome be able to load SVG images.

Without this, awesome will not load SVG images. The related error message is:

 > Couldn't recognize the image file format for file

Which comes from gdk.
  • Loading branch information
samueldr committed May 14, 2017
1 parent 3d79d8c commit 14520e7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pkgs/applications/window-managers/awesome/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv, fetchurl, fetchFromGitHub, luaPackages, cairo, cmake, imagemagick, pkgconfig, gdk_pixbuf
{ stdenv, fetchurl, fetchFromGitHub, luaPackages, cairo, librsvg, cmake, imagemagick, pkgconfig, gdk_pixbuf
, xorg, libstartup_notification, libxdg_basedir, libpthreadstubs
, xcb-util-cursor, makeWrapper, pango, gobjectIntrospection, unclutter
, compton, procps, iproute, coreutils, curl, alsaUtils, findutils, xterm
Expand Down Expand Up @@ -30,7 +30,7 @@ with luaPackages; stdenv.mkDerivation rec {
];

propagatedUserEnvPkgs = [ hicolor_icon_theme ];
buildInputs = [ cairo dbus gdk_pixbuf gobjectIntrospection
buildInputs = [ cairo librsvg dbus gdk_pixbuf gobjectIntrospection
git lgi libpthreadstubs libstartup_notification
libxdg_basedir lua nettools pango xcb-util-cursor
xorg.libXau xorg.libXdmcp xorg.libxcb xorg.libxshmfence
Expand All @@ -54,6 +54,7 @@ with luaPackages; stdenv.mkDerivation rec {

postInstall = ''
wrapProgram $out/bin/awesome \
--set GDK_PIXBUF_MODULE_FILE "$GDK_PIXBUF_MODULE_FILE" \
--prefix LUA_CPATH ";" '"${lgi}/lib/lua/${lua.luaversion}/?.so"' \
--prefix LUA_PATH ";" '"${lgi}/share/lua/${lua.luaversion}/?.lua;${lgi}/share/lua/${lua.luaversion}/lgi/?.lua"' \
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH" \
Expand Down

0 comments on commit 14520e7

Please sign in to comment.