20 musicVersion = lib.versions.majorMinor version;
21 music = stdenv.mkDerivation {
23 version = musicVersion;
26 url = "https://www.7kfans.com/downloads/7kaa-music-${musicVersion}.tar.bz2";
27 hash = "sha256-sNdntuJXGaFPXzSpN0SoAi17wkr2YnW+5U38eIaVwcM=";
35 meta.license = lib.licenses.unfree;
38 gccStdenv.mkDerivation (finalAttrs: {
42 src = fetchFromGitHub {
43 owner = "the3dfxdude";
45 rev = "v${finalAttrs.version}";
46 hash = "sha256-kkM+kFQ+tGHS5NrVPeDMRWFQb7waESt8xOLfFGaGdgo=";
49 nativeBuildInputs = [ autoreconfHook autoconf-archive pkg-config ];
51 buildInputs = [ openal enet SDL2 curl gettext libiconv ];
57 hardeningDisable = lib.optionals (stdenv.hostPlatform.isAarch64 && stdenv.hostPlatform.isDarwin) [ "stackprotector" ];
60 mkdir $out/share/7kaa/MUSIC
61 cp -R ${music}/MUSIC $out/share/7kaa/
62 cp ${music}/COPYING-Music.txt $out/share/7kaa/MUSIC
63 cp ${music}/COPYING-Music.txt $out/share/doc/7kaa
66 # Multiplayer is auto-disabled for non-x86 system
69 homepage = "https://www.7kfans.com";
70 description = "GPL release of the Seven Kingdoms with multiplayer (available only on x86 platforms)";
71 license = licenses.gpl2Only;
72 platforms = platforms.x86_64 ++ platforms.aarch64;
73 maintainers = with maintainers; [ _1000101 ];