springLobby: reformat

This commit is contained in:
Weijia Wang 2022-11-09 00:58:23 +01:00
parent dd9aa5d6c9
commit faa599ced6
2 changed files with 100 additions and 22 deletions

View File

@ -1,7 +1,31 @@
{ lib, stdenv, fetchFromGitHub, cmake, xz, boost, libdevil, zlib, p7zip { lib
, openal, libvorbis, glew, freetype, xorg, SDL2, libGLU, libGL , stdenv
, asciidoc, docbook_xsl, docbook_xsl_ns, curl, makeWrapper , fetchFromGitHub
, jdk ? null, python ? null, systemd, libunwind, which, minizip , cmake
, xz
, boost
, libdevil
, zlib
, p7zip
, openal
, libvorbis
, glew
, freetype
, xorg
, SDL2
, libGLU
, libGL
, asciidoc
, docbook_xsl
, docbook_xsl_ns
, curl
, makeWrapper
, jdk
, python
, systemd
, libunwind
, which
, minizip
, withAI ? true # support for AI Interfaces and Skirmish AIs , withAI ? true # support for AI Interfaces and Skirmish AIs
}: }:
@ -36,14 +60,34 @@ stdenv.mkDerivation rec {
echo "${version} maintenance" > VERSION echo "${version} maintenance" > VERSION
''; '';
cmakeFlags = ["-DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=ON" cmakeFlags = [
"-DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=ON"
"-DCMAKE_INSTALL_RPATH_USE_LINK_PATH:BOOL=ON" "-DCMAKE_INSTALL_RPATH_USE_LINK_PATH:BOOL=ON"
"-DPREFER_STATIC_LIBS:BOOL=OFF"]; "-DPREFER_STATIC_LIBS:BOOL=OFF"
];
nativeBuildInputs = [ cmake makeWrapper docbook_xsl docbook_xsl_ns asciidoc ]; nativeBuildInputs = [ cmake makeWrapper docbook_xsl docbook_xsl_ns asciidoc ];
buildInputs = [ xz boost libdevil zlib p7zip openal libvorbis freetype SDL2 buildInputs = [
xorg.libX11 xorg.libXcursor libGLU libGL glew curl xz
systemd libunwind which minizip ] boost
libdevil
zlib
p7zip
openal
libvorbis
freetype
SDL2
xorg.libX11
xorg.libXcursor
libGLU
libGL
glew
curl
systemd
libunwind
which
minizip
]
++ lib.optional withAI jdk ++ lib.optional withAI jdk
++ lib.optional withAI python; ++ lib.optional withAI python;
@ -57,8 +101,8 @@ stdenv.mkDerivation rec {
meta = with lib; { meta = with lib; {
homepage = "https://springrts.com/"; homepage = "https://springrts.com/";
description = "A powerful real-time strategy (RTS) game engine"; description = "A powerful real-time strategy (RTS) game engine";
license = licenses.gpl2; license = licenses.gpl2Plus;
maintainers = with maintainers; [ qknight domenkozar sorki ]; maintainers = with maintainers; [ qknight domenkozar sorki ];
platforms = platforms.linux; platforms = [ "i686-linux" "x86_64-linux" ];
}; };
} }

View File

@ -1,6 +1,28 @@
{ lib, stdenv, fetchurl, fetchpatch, cmake, wxGTK30, openal, pkg-config, curl, libtorrent-rasterbar { lib
, libpng, libX11, gettext, boost, libnotify, gtk2, doxygen, spring , stdenv
, makeWrapper, glib, minizip, alure, pcre, jsoncpp }: , fetchurl
, fetchpatch
, cmake
, wxGTK30
, openal
, pkg-config
, curl
, libtorrent-rasterbar
, libpng
, libX11
, gettext
, boost
, libnotify
, gtk2
, doxygen
, spring
, makeWrapper
, glib
, minizip
, alure
, pcre
, jsoncpp
}:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "springlobby"; pname = "springlobby";
@ -13,8 +35,20 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake pkg-config gettext doxygen makeWrapper ]; nativeBuildInputs = [ cmake pkg-config gettext doxygen makeWrapper ];
buildInputs = [ buildInputs = [
wxGTK30 openal curl libtorrent-rasterbar pcre jsoncpp wxGTK30
boost libpng libX11 libnotify gtk2 glib minizip alure openal
curl
libtorrent-rasterbar
pcre
jsoncpp
boost
libpng
libX11
libnotify
gtk2
glib
minizip
alure
]; ];
patches = [ patches = [
@ -33,10 +67,10 @@ stdenv.mkDerivation rec {
''; '';
meta = with lib; { meta = with lib; {
homepage = "https://springlobby.info/"; homepage = "https://springlobby.springrts.com";
description = "Cross-platform lobby client for the Spring RTS project"; description = "Cross-platform lobby client for the Spring RTS project";
license = licenses.gpl2; license = licenses.gpl2Plus;
maintainers = with maintainers; [ qknight domenkozar ]; maintainers = with maintainers; [ qknight domenkozar ];
platforms = platforms.linux; platforms = [ "i686-linux" "x86_64-linux" ];
}; };
} }