From d526e331f82cf8f9592994c20ec4cc7214ca9b7f Mon Sep 17 00:00:00 2001 From: Nikolay Korotkiy Date: Thu, 12 Sep 2019 00:18:11 +0300 Subject: [PATCH] xchm: 1.23 -> 1.30 --- pkgs/applications/misc/xchm/default.nix | 30 ++++++++++++++++--------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/pkgs/applications/misc/xchm/default.nix b/pkgs/applications/misc/xchm/default.nix index a7a6500fd22a..6a5e62f54e1e 100644 --- a/pkgs/applications/misc/xchm/default.nix +++ b/pkgs/applications/misc/xchm/default.nix @@ -1,22 +1,30 @@ -{stdenv, fetchurl, wxGTK, chmlib}: +{ stdenv, fetchFromGitHub, autoreconfHook, wxGTK30, chmlib }: -stdenv.mkDerivation { - name = "xchm-1.23"; - src = fetchurl { - url = mirror://sourceforge/xchm/xchm-1.23.tar.gz; - sha256 = "0qn0fyxcrn30ndq2asx31k0qkx3grbm16fb1y580wd2gjmh5r3wg"; +stdenv.mkDerivation rec { + pname = "xchm"; + version = "1.30"; + + src = fetchFromGitHub { + owner = "rzvncj"; + repo = "xCHM"; + rev = version; + sha256 = "1sjvh06m8jbb28k6y3knas3nkh1dfvff4mlwjs33x12ilhddhr8v"; }; - buildInputs = [wxGTK chmlib]; - postConfigure = '' - export NIX_LDFLAGS="$NIX_LDFLAGS $(${wxGTK}/lib/wx/config/* --libs | sed -e s@-pthread@@)" - echo $NIX_LDFLAGS + nativeBuildInputs = [ autoreconfHook ]; + buildInputs = [ wxGTK30 chmlib ]; + + configureFlags = [ "--with-wx-prefix=${wxGTK30}" ]; + + preConfigure = '' + export LDFLAGS="$LDFLAGS $(${wxGTK30}/bin/wx-config --libs | sed -e s@-pthread@@) -lwx_gtk2u_aui-3.0" ''; meta = with stdenv.lib; { description = "A viewer for Microsoft HTML Help files"; - homepage = http://xchm.sourceforge.net; + homepage = "https://github.com/rzvncj/xCHM"; license = licenses.gpl2; + maintainers = with maintainers; [ sikmir ]; platforms = platforms.linux; }; }