From e9f18b5ec3cebaf337af36aacc652f23466a64c7 Mon Sep 17 00:00:00 2001 From: kyehn Date: Mon, 1 Sep 2025 20:34:00 +0800 Subject: [PATCH] ttfautohint: 1.8.3 -> 1.8.4 --- pkgs/tools/misc/ttfautohint/default.nix | 31 +++++++++++-------------- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 15 insertions(+), 18 deletions(-) diff --git a/pkgs/tools/misc/ttfautohint/default.nix b/pkgs/tools/misc/ttfautohint/default.nix index a4fea24080fd..0b7f037b2d4f 100644 --- a/pkgs/tools/misc/ttfautohint/default.nix +++ b/pkgs/tools/misc/ttfautohint/default.nix @@ -4,49 +4,47 @@ fetchurl, pkg-config, autoreconfHook, + perl, freetype, harfbuzz, - libiconv, - qtbase, + libsForQt5, enableGUI ? true, }: stdenv.mkDerivation rec { - version = "1.8.3"; + version = "1.8.4"; pname = "ttfautohint"; src = fetchurl { url = "mirror://savannah/freetype/ttfautohint-${version}.tar.gz"; - sha256 = "0zpqgihn3yh3v51ynxwr8asqrijvs4gv686clwv7bm8sawr4kfw7"; + hash = "sha256-iodhF/puv9L/4bNoKpqYyALA9HGJ9X09tLmXdCBoMuE="; }; + postPatch = '' + echo "${version}" > VERSION + ''; + postAutoreconf = '' - substituteInPlace configure --replace "macx-g++" "macx-clang" + substituteInPlace configure --replace-fail "macx-g++" "macx-clang" ''; nativeBuildInputs = [ pkg-config autoreconfHook - ]; + perl + ] + ++ lib.optionals enableGUI [ libsForQt5.qt5.wrapQtAppsHook ]; buildInputs = [ freetype harfbuzz - libiconv ] - ++ lib.optional enableGUI qtbase; + ++ lib.optionals enableGUI [ libsForQt5.qt5.qtbase ]; - configureFlags = [ ''--with-qt=${if enableGUI then "${qtbase}/lib" else "no"}'' ]; - - # workaround https://github.com/NixOS/nixpkgs/issues/155458 - preBuild = lib.optionalString stdenv.cc.isClang '' - rm version - ''; + configureFlags = [ ''--with-qt=${if enableGUI then "${libsForQt5.qt5.qtbase}/lib" else "no"}'' ]; enableParallelBuilding = true; - dontWrapQtApps = true; - meta = with lib; { description = "Automatic hinter for TrueType fonts"; mainProgram = "ttfautohint"; @@ -61,5 +59,4 @@ stdenv.mkDerivation rec { maintainers = [ ]; platforms = platforms.unix; }; - } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 0907b9121b65..3f6bab344044 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4343,7 +4343,7 @@ with pkgs; trytond = with python3Packages; toPythonApplication trytond; - ttfautohint = libsForQt5.callPackage ../tools/misc/ttfautohint { }; + ttfautohint = callPackage ../tools/misc/ttfautohint { }; ttfautohint-nox = ttfautohint.override { enableGUI = false; }; twilight = callPackage ../tools/graphics/twilight {