Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

imv: enable LIBNSGIF and LIBJPEG backends #100821

Merged
merged 1 commit into from
Oct 19, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 32 additions & 23 deletions pkgs/applications/graphics/imv/default.nix
Original file line number Diff line number Diff line change
@@ -1,46 +1,55 @@
{ stdenv, fetchFromGitHub
, freeimage, fontconfig, pkgconfig
, asciidoc, docbook_xsl, libxslt, cmocka
, librsvg, pango, libxkbcommon, wayland
, libGLU, icu
{ asciidoc
, cmocka
, docbook_xsl
, fetchFromGitHub
, fontconfig
, freeimage
, icu
, libGLU
, libheif
, libjpeg_turbo
, libpng
, librsvg
, libtiff
, libxkbcommon
, libxslt
, netsurf
, pango
, pkgconfig
, stdenv
, wayland
}:

stdenv.mkDerivation rec {
pname = "imv";
version = "4.1.0";

src = fetchFromGitHub {
owner = "eXeC64";
repo = "imv";
rev = "v${version}";
owner = "eXeC64";
repo = "imv";
rev = "v${version}";
sha256 = "0gk8g178i961nn3bls75a8qpv6wvfvav6hd9lxca1skaikd33zdx";
};

preBuild = ''
# Version is 4.0.1, but Makefile was not updated
sed -i 's/echo v4\.0\.0/echo v4.0.1/' Makefile
'';

nativeBuildInputs = [
asciidoc
cmocka
docbook_xsl
libxslt
];
nativeBuildInputs = [ asciidoc cmocka docbook_xsl libxslt ];
rnhmjoj marked this conversation as resolved.
Show resolved Hide resolved

buildInputs = [
freeimage
icu
libGLU
libjpeg_turbo
librsvg
libxkbcommon
netsurf.libnsgif
pango
pkgconfig
wayland
icu
];

installFlags = [ "PREFIX=$(out)" "CONFIGPREFIX=$(out)/etc" ];

makeFlags = [ "BACKEND_LIBJPEG=yes" "BACKEND_LIBNSGIF=yes" ];

postFixup = ''
# The `bin/imv` script assumes imv-wayland or imv-x11 in PATH,
# so we have to fix those to the binaries we installed into the /nix/store
Expand All @@ -53,9 +62,9 @@ stdenv.mkDerivation rec {

meta = with stdenv.lib; {
description = "A command line image viewer for tiling window managers";
homepage = "https://github.com/eXeC64/imv";
license = licenses.gpl2;
homepage = "https://github.com/eXeC64/imv";
license = licenses.gpl2;
maintainers = with maintainers; [ rnhmjoj markus1189 ];
platforms = platforms.all;
platforms = platforms.all;
};
}