nixpkgs/pkgs/games/stepmania/default.nix
Rick van Schijndel 9833d56c24 treewide: mark packages broken that never built on PLATFORM
Done with the help of https://github.com/Mindavi/nixpkgs-mark-broken
Tool is still WIP but this is one of the first results.

I manually audited the results and removed some results that were not valid.

Note that some of these packages maybe should have more constrained platforms set
instead of broken set, but I think not being perfectly correct is better than
just keep trying to build all these things and never succeeding.

Some observations:

- Some darwin builds require XCode tools
- aarch64-linux builds sometimes suffer from using gcc9
  - gcc9 is getting older and misses some new libraries/features
- Sometimes tools try to do system detection or expect some explicit settings for
  platforms that are not x86_64-linux
2022-12-13 21:40:12 +01:00

49 lines
1.2 KiB
Nix

{ stdenv, lib, fetchFromGitHub, cmake, nasm
, gtk2, glib, ffmpeg, alsa-lib, libmad, libogg, libvorbis
, glew, libpulseaudio, udev
}:
stdenv.mkDerivation rec {
pname = "stepmania";
version = "5.1.0-b2";
src = fetchFromGitHub {
owner = "stepmania";
repo = "stepmania";
rev = "v${version}";
sha256 = "0a7y9l7xm510vgnpmj1is7p9m6d6yd0fcaxrjcickz295k5w3rdn";
};
patches = [
./0001-fix-build-with-ffmpeg-4.patch
];
nativeBuildInputs = [ cmake nasm ];
buildInputs = [
gtk2 glib ffmpeg alsa-lib libmad libogg libvorbis
glew libpulseaudio udev
];
cmakeFlags = [
"-DWITH_SYSTEM_FFMPEG=1"
"-DGTK2_GDKCONFIG_INCLUDE_DIR=${gtk2.out}/lib/gtk-2.0/include"
"-DGTK2_GLIBCONFIG_INCLUDE_DIR=${glib.out}/lib/glib-2.0/include"
];
postInstall = ''
mkdir -p $out/bin
ln -s $out/stepmania-5.1/stepmania $out/bin/stepmania
'';
meta = with lib; {
homepage = "https://www.stepmania.com/";
description = "Free dance and rhythm game for Windows, Mac, and Linux";
platforms = platforms.linux;
license = licenses.mit; # expat version
maintainers = [ ];
# never built on aarch64-linux since first introduction in nixpkgs
broken = stdenv.isLinux && stdenv.isAarch64;
};
}