diff options
author | Alyssa Ross <hi@alyssa.is> | 2020-07-13 23:20:04 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2020-07-13 23:21:06 +0000 |
commit | a42c1d6d62656dcf9bd85de620f2e200a5ad22d8 (patch) | |
tree | 7d481fea9872f62a034452612be17f4494159baa /nixpkgs/pkgs/tools/misc/fontforge/default.nix | |
parent | 55f69a6b0e53c1c4b3e0396937c53bf5662b5519 (diff) | |
parent | 9480bae337095fd24f61380bce3174fdfe926a00 (diff) | |
download | nixlib-a42c1d6d62656dcf9bd85de620f2e200a5ad22d8.tar nixlib-a42c1d6d62656dcf9bd85de620f2e200a5ad22d8.tar.gz nixlib-a42c1d6d62656dcf9bd85de620f2e200a5ad22d8.tar.bz2 nixlib-a42c1d6d62656dcf9bd85de620f2e200a5ad22d8.tar.lz nixlib-a42c1d6d62656dcf9bd85de620f2e200a5ad22d8.tar.xz nixlib-a42c1d6d62656dcf9bd85de620f2e200a5ad22d8.tar.zst nixlib-a42c1d6d62656dcf9bd85de620f2e200a5ad22d8.zip |
Merge commit '9480bae337095fd24f61380bce3174fdfe926a00'
This is the last nixos-unstable release before 13b2903169f, which I'm a bit nervous about. So I want the update including that one to be as small as possible, hence going to this one first.
Diffstat (limited to 'nixpkgs/pkgs/tools/misc/fontforge/default.nix')
-rw-r--r-- | nixpkgs/pkgs/tools/misc/fontforge/default.nix | 35 |
1 files changed, 15 insertions, 20 deletions
diff --git a/nixpkgs/pkgs/tools/misc/fontforge/default.nix b/nixpkgs/pkgs/tools/misc/fontforge/default.nix index 67ab7b2d6917..82fd5c8210dd 100644 --- a/nixpkgs/pkgs/tools/misc/fontforge/default.nix +++ b/nixpkgs/pkgs/tools/misc/fontforge/default.nix @@ -1,21 +1,24 @@ { stdenv, fetchurl, lib -, autoconf, automake, gnum4, libtool, perl, uthash, pkgconfig, gettext +, cmake, perl, uthash, pkgconfig, gettext , python, freetype, zlib, glib, libungif, libpng, libjpeg, libtiff, libxml2, cairo, pango , readline, woff2, zeromq, libuninameslist , withSpiro ? false, libspiro -, withGTK ? false, gtk2 +, withGTK ? false, gtk3 +, withGUI ? withGTK , withPython ? true , withExtras ? true , Carbon ? null, Cocoa ? null }: +assert withGTK -> withGUI; + stdenv.mkDerivation rec { pname = "fontforge"; - version = "20190801"; + version = "20200314"; src = fetchurl { - url = "https://github.com/${pname}/${pname}/releases/download/${version}/${pname}-${version}.tar.gz"; - sha256 = "0lh8yx01asbzxm6car5cfi64njh5p4lxc7iv8dldr5rwg357a86r"; + url = "https://github.com/${pname}/${pname}/releases/download/${version}/${pname}-${version}.tar.xz"; + sha256 = "0qf88wd6riycq56d24brybyc93ns74s0nyyavm43zp2kfcihn6fd"; }; # use $SOURCE_DATE_EPOCH instead of non-deterministic timestamps @@ -30,41 +33,33 @@ stdenv.mkDerivation rec { # do not use x87's 80-bit arithmetic, rouding errors result in very different font binaries NIX_CFLAGS_COMPILE = lib.optionalString stdenv.isi686 "-msse2 -mfpmath=sse"; - nativeBuildInputs = [ pkgconfig autoconf automake gnum4 libtool perl gettext ]; + nativeBuildInputs = [ pkgconfig cmake ]; buildInputs = [ readline uthash woff2 zeromq libuninameslist python freetype zlib glib libungif libpng libjpeg libtiff libxml2 ] ++ lib.optionals withSpiro [libspiro] - ++ lib.optionals withGTK [ gtk2 cairo pango ] + ++ lib.optionals withGUI [ gtk3 cairo pango ] ++ lib.optionals stdenv.isDarwin [ Carbon Cocoa ]; - configureFlags = [ "--enable-woff2" ] - ++ lib.optionals (!withPython) [ "--disable-python-scripting" "--disable-python-extension" ] - ++ lib.optional withGTK "--enable-gtk2-use" - ++ lib.optional (!withGTK) "--without-x" - ++ lib.optional withExtras "--enable-fontforge-extras"; + cmakeFlags = [ "-DCMAKE_BUILD_WITH_INSTALL_RPATH=ON" ] + ++ lib.optional (!withSpiro) "-DENABLE_LIBSPIRO=OFF" + ++ lib.optional (!withGUI) "-DENABLE_GUI=OFF" + ++ lib.optional (!withGTK) "-DENABLE_X11=ON" + ++ lib.optional withExtras "-DENABLE_FONTFORGE_EXTRAS=ON"; # work-around: git isn't really used, but configuration fails without it preConfigure = '' # The way $version propagates to $version of .pe-scripts (https://github.com/dejavu-fonts/dejavu-fonts/blob/358190f/scripts/generate.pe#L19) export SOURCE_DATE_EPOCH=$(date -d ${version} +%s) - - export GIT="$(type -P true)" - ./bootstrap --skip-git --force ''; - doCheck = false; # tries to wget some fonts - doInstallCheck = doCheck; - postInstall = # get rid of the runtime dependency on python lib.optionalString (!withPython) '' rm -r "$out/share/fontforge/python" ''; - enableParallelBuilding = true; - meta = { description = "A font editor"; homepage = "http://fontforge.github.io"; |