nixpkgs/pkgs/development/libraries/SDL2_ttf/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

33 lines
1.0 KiB
Nix
Raw Normal View History

{ lib, stdenv, pkg-config, darwin, fetchurl, SDL2, freetype, harfbuzz, libGL, testers }:
2015-03-07 11:49:59 +00:00
stdenv.mkDerivation (finalAttrs: {
pname = "SDL2_ttf";
2023-02-11 07:24:28 +00:00
version = "2.20.2";
2015-03-07 11:49:59 +00:00
src = fetchurl {
url = "https://www.libsdl.org/projects/SDL_ttf/release/${finalAttrs.pname}-${finalAttrs.version}.tar.gz";
2023-02-11 07:24:28 +00:00
sha256 = "sha256-ncce2TSHUhsQeixKnKa/Q/ti9r3dXCawVea5FBiiIFM=";
2015-03-07 11:49:59 +00:00
};
configureFlags = [ "--disable-harfbuzz-builtin" ]
++ lib.optionals stdenv.isDarwin [ "--disable-sdltest" ];
2021-11-01 09:54:40 +00:00
nativeBuildInputs = [ pkg-config ];
buildInputs = [ SDL2 freetype harfbuzz ]
2023-05-29 11:48:35 +00:00
++ lib.optional (!stdenv.isDarwin) libGL
++ lib.optional stdenv.isDarwin darwin.libobjc;
2015-03-07 11:49:59 +00:00
passthru.tests.pkg-config = testers.hasPkgConfigModules {
package = finalAttrs.finalPackage;
};
meta = with lib; {
2022-01-13 00:34:36 +00:00
description = "Support for TrueType (.ttf) font files with Simple Directmedia Layer";
platforms = platforms.unix;
license = licenses.zlib;
2022-01-13 00:34:36 +00:00
homepage = "https://github.com/libsdl-org/SDL_ttf";
pkgConfigModules = [ "SDL2_ttf" ];
2015-03-07 11:49:59 +00:00
};
})