ci/eval: add rebuildsByPlatform to the comparison result (#363751)
[NixPkgs.git] / pkgs / by-name / t4 / t4kcommon / package.nix
blobd5e07eb4bbde9a01cae90cd64787021ca39bdd63
2   lib,
3   stdenv,
4   fetchFromGitHub,
5   fetchurl,
6   cmake,
7   pkg-config,
8   SDL,
9   SDL_image,
10   SDL_mixer,
11   SDL_net,
12   SDL_ttf,
13   libpng,
14   librsvg,
15   libxml2,
18 stdenv.mkDerivation rec {
19   version = "0.1.1";
20   pname = "t4kcommon";
22   src = fetchFromGitHub {
23     owner = "tux4kids";
24     repo = "t4kcommon";
25     rev = "upstream/${version}";
26     sha256 = "13q02xpmps9qg8zrzzy2gzv4a6afgi28lxk4z242j780v0gphchp";
27   };
29   patches = [
30     # patch from debian to support libpng16 instead of libpng12
31     (fetchurl {
32       url = "https://salsa.debian.org/tux4kids-pkg-team/t4kcommon/raw/f7073fa384f5a725139f54844e59b57338b69dc7/debian/patches/libpng16.patch";
33       sha256 = "1lcpkdy5gvxgljg1vkrxych74amq0gramb1snj2831dam48is054";
34     })
35   ];
37   # Workaround build failure on -fno-common toolchains like upstream
38   # gcc-10. Otherwise build fails as:
39   #   ld: CMakeFiles/t4k_common.dir/t4k_throttle.c.o:(.bss+0x0): multiple definition of
40   #     `wrapped_lines'; CMakeFiles/t4k_common.dir/t4k_audio.c.o:(.bss+0x0): first defined here
41   # TODO: revisit https://github.com/tux4kids/t4kcommon/pull/10 when merged.
42   env.NIX_CFLAGS_COMPILE = "-fcommon";
44   nativeBuildInputs = [
45     cmake
46     pkg-config
47   ];
48   buildInputs = [
49     SDL
50     SDL_image
51     SDL_mixer
52     SDL_net
53     SDL_ttf
54     libpng
55     librsvg
56     libxml2
57   ];
59   meta = with lib; {
60     description = "Library of code shared between tuxmath and tuxtype";
61     homepage = "https://github.com/tux4kids/t4kcommon";
62     license = licenses.gpl3Plus;
63     maintainers = [ maintainers.aanderse ];
64     platforms = platforms.linux;
65   };