From a0800919f1b3b3388d21bffb59e1ce4fd1ab57bb Mon Sep 17 00:00:00 2001 From: Justin Humm Date: Thu, 14 Jan 2021 17:17:19 +0100 Subject: [PATCH] fontforge: 20200314 -> 20201107 also use fetchFromGitHub for getting the source. --- pkgs/tools/misc/fontforge/default.nix | 25 +++++++------------------ 1 file changed, 7 insertions(+), 18 deletions(-) diff --git a/pkgs/tools/misc/fontforge/default.nix b/pkgs/tools/misc/fontforge/default.nix index 2140e405ff4a..ffee232172c0 100644 --- a/pkgs/tools/misc/fontforge/default.nix +++ b/pkgs/tools/misc/fontforge/default.nix @@ -1,5 +1,4 @@ -{ stdenv, fetchurl, lib -, fetchpatch +{ stdenv, fetchFromGitHub, lib , cmake, perl, uthash, pkg-config, gettext , python, freetype, zlib, glib, libungif, libpng, libjpeg, libtiff, libxml2, cairo, pango , readline, woff2, zeromq, libuninameslist @@ -15,25 +14,15 @@ assert withGTK -> withGUI; stdenv.mkDerivation rec { pname = "fontforge"; - version = "20200314"; + version = "20201107"; - src = fetchurl { - url = "https://github.com/${pname}/${pname}/releases/download/${version}/${pname}-${version}.tar.xz"; - sha256 = "0qf88wd6riycq56d24brybyc93ns74s0nyyavm43zp2kfcihn6fd"; + src = fetchFromGitHub { + owner = pname; + repo = pname; + rev = version; + sha256 = "sha256-Rl/5lbXaPgIndANaD0IakaDus6T53FjiBb45FIuGrvc="; }; - patches = [ - # Unreleased fix for https://github.com/fontforge/fontforge/issues/4229 - # which is required to fix an uninterposated `${CMAKE_INSTALL_PREFIX}/lib`, see - # see https://github.com/nh2/static-haskell-nix/pull/98#issuecomment-665395399 - # TODO: Remove https://github.com/fontforge/fontforge/pull/4232 is in a release. - (fetchpatch { - name = "fontforge-cmake-set-rpath-to-the-configure-time-CMAKE_INSTALL_PREFIX"; - url = "https://github.com/fontforge/fontforge/commit/297ee9b5d6db5970ca17ebe5305189e79a1520a1.patch"; - sha256 = "14qfp8pwh0vzzib4hq2nc6xhn8lc1cal1sb0lqwb2q5dijqx5kqk"; - }) - ]; - # use $SOURCE_DATE_EPOCH instead of non-deterministic timestamps postPatch = '' find . -type f -name '*.c' -exec sed -r -i 's#\btime\(&(.+)\)#if (getenv("SOURCE_DATE_EPOCH")) \1=atol(getenv("SOURCE_DATE_EPOCH")); else &#g' {} \;