Merge pull request #21231 from abbradar/no-fmod
Update DOOM forks, remove top-level fmod
This commit is contained in:
commit
1cb3831f1c
@ -1,41 +0,0 @@
|
|||||||
{ stdenv, fetchurl }:
|
|
||||||
|
|
||||||
assert (stdenv.system == "x86_64-linux") || (stdenv.system == "i686-linux");
|
|
||||||
let
|
|
||||||
bits = stdenv.lib.optionalString (stdenv.system == "x86_64-linux") "64";
|
|
||||||
|
|
||||||
libPath = stdenv.lib.makeLibraryPath
|
|
||||||
[ stdenv.cc.libc stdenv.cc.cc ] + ":${stdenv.cc.cc.lib}/lib64";
|
|
||||||
patchLib = x: "patchelf --set-rpath ${libPath} ${x}";
|
|
||||||
in
|
|
||||||
stdenv.mkDerivation rec {
|
|
||||||
name = "fmod-${version}";
|
|
||||||
version = "4.44.41";
|
|
||||||
|
|
||||||
src = fetchurl {
|
|
||||||
url = "http://www.fmod.org/download/fmodex/api/Linux/fmodapi44441linux.tar.gz";
|
|
||||||
sha256 = "0qjvbhx9g6ijv542n6w3ryv20f74p1qx6bbllda9hl14683z8r8p";
|
|
||||||
};
|
|
||||||
|
|
||||||
dontStrip = true;
|
|
||||||
dontBuild = true;
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
mkdir -p $out/lib $out/include/fmodex
|
|
||||||
|
|
||||||
cd api/inc && cp * $out/include/fmodex && cd ../lib
|
|
||||||
cp libfmodex${bits}-${version}.so $out/lib/libfmodex.so
|
|
||||||
cp libfmodexL${bits}-${version}.so $out/lib/libfmodexL.so
|
|
||||||
|
|
||||||
${patchLib "$out/lib/libfmodex.so"}
|
|
||||||
${patchLib "$out/lib/libfmodexL.so"}
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Programming library and toolkit for the creation and playback of interactive audio";
|
|
||||||
homepage = "http://www.fmod.org/";
|
|
||||||
license = stdenv.lib.licenses.unfreeRedistributable;
|
|
||||||
platforms = stdenv.lib.platforms.linux;
|
|
||||||
maintainers = [ stdenv.lib.maintainers.thoughtpolice ];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,34 +1,51 @@
|
|||||||
{stdenv, fetchFromGitHub, cmake, fmod, mesa, SDL2}:
|
{ stdenv, fetchFromGitHub, cmake, zdoom
|
||||||
|
, openal, fluidsynth, soundfont-fluid, mesa_noglu, SDL2
|
||||||
|
, bzip2, zlib, libjpeg, libsndfile, mpg123, game-music-emu }:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation rec {
|
||||||
name = "gzdoom-2015-05-07";
|
name = "gzdoom-${version}";
|
||||||
src = fetchFromGitHub{
|
version = "2.2.0";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
owner = "coelckers";
|
owner = "coelckers";
|
||||||
repo = "gzdoom";
|
repo = "gzdoom";
|
||||||
rev = "a59824cd8897dea5dd452c31be1328415478f990";
|
rev = "g${version}";
|
||||||
sha256 = "1lg9dk5prn2bjmyznq941a862alljvfgbb42whbpg0vw9vhpikak";
|
sha256 = "0xxgd8fa29pcdir1xah5cvx41bfy76p4dydpp13mf44p9pr29hrb";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [ cmake fmod mesa SDL2 ];
|
nativeBuildInputs = [ cmake ];
|
||||||
|
buildInputs = [
|
||||||
|
SDL2 mesa_noglu openal fluidsynth bzip2 zlib libjpeg libsndfile mpg123
|
||||||
|
game-music-emu
|
||||||
|
];
|
||||||
|
|
||||||
cmakeFlags = [ "-DFMOD_LIBRARY=${fmod}/lib/libfmodex.so" ];
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
preConfigure=''
|
NIX_CFLAGS_LINK = [ "-lopenal" "-lfluidsynth" ];
|
||||||
sed s@gzdoom.pk3@$out/share/gzdoom.pk3@ -i src/version.h
|
|
||||||
|
preConfigure = ''
|
||||||
|
sed -i \
|
||||||
|
-e "s@/usr/share/sounds/sf2/@${soundfont-fluid}/share/soundfonts/@g" \
|
||||||
|
-e "s@FluidR3_GM.sf2@FluidR3_GM2-2.sf2@g" \
|
||||||
|
src/sound/music_fluidsynth_mididevice.cpp
|
||||||
'';
|
'';
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
mkdir -p $out/bin
|
install -Dm755 gzdoom "$out/lib/gzdoom/gzdoom"
|
||||||
cp gzdoom $out/bin
|
for i in *.pk3; do
|
||||||
mkdir -p $out/share
|
install -Dm644 "$i" "$out/lib/gzdoom/$i"
|
||||||
cp gzdoom.pk3 $out/share
|
done
|
||||||
|
mkdir $out/bin
|
||||||
|
ln -s $out/lib/gzdoom/gzdoom $out/bin/gzdoom
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = with stdenv.lib; {
|
||||||
homepage = https://github.com/coelckers/gzdoom;
|
homepage = "https://github.com/coelckers/gzdoom";
|
||||||
description = "A Doom source port based on ZDoom. It features an OpenGL renderer and lots of new features";
|
description = "A Doom source port based on ZDoom. It features an OpenGL renderer and lots of new features";
|
||||||
license = stdenv.lib.licenses.unfree;
|
# Doom source license, MAME license
|
||||||
maintainers = [ stdenv.lib.maintainers.lassulus ];
|
license = licenses.unfreeRedistributable;
|
||||||
|
platforms = platforms.linux;
|
||||||
|
maintainers = with maintainers; [ lassulus ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,9 +1,11 @@
|
|||||||
{ stdenv, lib, fetchhg, cmake, pkgconfig, makeWrapper
|
{ stdenv, lib, fetchhg, cmake, pkgconfig, makeWrapper, callPackage
|
||||||
, SDL, mesa, bzip2, zlib, fmod, libjpeg, fluidsynth, openssl, sqlite-amalgamation
|
, soundfont-fluid, SDL, mesa, bzip2, zlib, libjpeg, fluidsynth, openssl, sqlite-amalgamation, gtk2
|
||||||
, serverOnly ? false
|
, serverOnly ? false
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let suffix = lib.optionalString serverOnly "-server";
|
let
|
||||||
|
suffix = lib.optionalString serverOnly "-server";
|
||||||
|
fmod = callPackage ./fmod.nix { };
|
||||||
|
|
||||||
# FIXME: drop binary package when upstream fixes their protocol versioning
|
# FIXME: drop binary package when upstream fixes their protocol versioning
|
||||||
in stdenv.mkDerivation {
|
in stdenv.mkDerivation {
|
||||||
@ -18,7 +20,7 @@ in stdenv.mkDerivation {
|
|||||||
# I have no idea why would SDL and libjpeg be needed for the server part!
|
# I have no idea why would SDL and libjpeg be needed for the server part!
|
||||||
# But they are.
|
# But they are.
|
||||||
buildInputs = [ openssl bzip2 zlib SDL libjpeg ]
|
buildInputs = [ openssl bzip2 zlib SDL libjpeg ]
|
||||||
++ lib.optionals (!serverOnly) [ mesa fmod fluidsynth ];
|
++ lib.optionals (!serverOnly) [ mesa fmod fluidsynth gtk2 ];
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake pkgconfig makeWrapper ];
|
nativeBuildInputs = [ cmake pkgconfig makeWrapper ];
|
||||||
|
|
||||||
@ -26,6 +28,11 @@ in stdenv.mkDerivation {
|
|||||||
ln -s ${sqlite-amalgamation}/* sqlite/
|
ln -s ${sqlite-amalgamation}/* sqlite/
|
||||||
sed -ie 's| restrict| _restrict|g' dumb/include/dumb.h \
|
sed -ie 's| restrict| _restrict|g' dumb/include/dumb.h \
|
||||||
dumb/src/it/*.c
|
dumb/src/it/*.c
|
||||||
|
'' + lib.optionalString serverOnly ''
|
||||||
|
sed -i \
|
||||||
|
-e "s@/usr/share/sounds/sf2/@${soundfont-fluid}/share/soundfonts/@g" \
|
||||||
|
-e "s@FluidR3_GM.sf2@FluidR3_GM2-2.sf2@g" \
|
||||||
|
src/sound/music_fluidsynth_mididevice.cpp
|
||||||
'';
|
'';
|
||||||
|
|
||||||
cmakeFlags =
|
cmakeFlags =
|
||||||
@ -39,27 +46,26 @@ in stdenv.mkDerivation {
|
|||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
mkdir -p $out/bin
|
mkdir -p $out/bin
|
||||||
mkdir -p $out/share/zandronum
|
mkdir -p $out/lib/zandronum
|
||||||
cp zandronum${suffix} \
|
cp zandronum${suffix} \
|
||||||
zandronum.pk3 \
|
*.pk3 \
|
||||||
skulltag_actors.pk3 \
|
|
||||||
${lib.optionalString (!serverOnly) "liboutput_sdl.so"} \
|
${lib.optionalString (!serverOnly) "liboutput_sdl.so"} \
|
||||||
$out/share/zandronum
|
$out/lib/zandronum
|
||||||
|
|
||||||
# For some reason, while symlinks work for binary version, they don't for source one.
|
# For some reason, while symlinks work for binary version, they don't for source one.
|
||||||
makeWrapper $out/share/zandronum/zandronum${suffix} $out/bin/zandronum${suffix}
|
makeWrapper $out/lib/zandronum/zandronum${suffix} $out/bin/zandronum${suffix}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
postFixup = lib.optionalString (!serverOnly) ''
|
postFixup = lib.optionalString (!serverOnly) ''
|
||||||
patchelf --set-rpath $(patchelf --print-rpath $out/share/zandronum/zandronum):$out/share/zandronum \
|
patchelf --set-rpath $(patchelf --print-rpath $out/lib/zandronum/zandronum):$out/lib/zandronum \
|
||||||
$out/share/zandronum/zandronum
|
$out/lib/zandronum/zandronum
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = http://zandronum.com/;
|
homepage = http://zandronum.com/;
|
||||||
description = "Multiplayer oriented port, based off Skulltag, for Doom and Doom II by id Software";
|
description = "Multiplayer oriented port, based off Skulltag, for Doom and Doom II by id Software";
|
||||||
maintainers = with maintainers; [ lassulus ];
|
maintainers = with maintainers; [ lassulus ];
|
||||||
license = stdenv.lib.licenses.unfree;
|
license = licenses.unfreeRedistributable;
|
||||||
platforms = platforms.linux;
|
platforms = platforms.linux;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -1,40 +1,57 @@
|
|||||||
{ stdenv, fetchFromGitHub, cmake, fmod, mesa, SDL }:
|
{ stdenv, fetchurl, p7zip, cmake
|
||||||
|
, SDL2, openal, fluidsynth, soundfont-fluid, bzip2, zlib, libjpeg, game-music-emu
|
||||||
|
, libsndfile, mpg123 }:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation rec {
|
||||||
name = "zdoom-2.7.1";
|
name = "zdoom-${version}";
|
||||||
src = fetchFromGitHub {
|
majorVersion = "2.8";
|
||||||
#url = "https://github.com/rheit/zdoom";
|
version = "${majorVersion}.1";
|
||||||
owner = "rheit";
|
|
||||||
repo = "zdoom";
|
src = fetchurl {
|
||||||
rev = "2.7.1";
|
url = "https://zdoom.org/files/zdoom/${majorVersion}/zdoom-${version}-src.7z";
|
||||||
sha256 = "00bx4sgl9j1dyih7yysfq4ah6msxw8580g53p99jfym34ky5ppkh";
|
sha256 = "0453fqrh9l00xwphfxni5qkf9y134n3s1mr1dvi5cbkxcva7j8bq";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [ cmake fmod mesa SDL ];
|
nativeBuildInputs = [ p7zip cmake ];
|
||||||
|
buildInputs = [
|
||||||
cmakeFlags = [
|
SDL2 openal fluidsynth bzip2 zlib libjpeg game-music-emu libsndfile mpg123
|
||||||
"-DFMOD_LIBRARY=${fmod}/lib/libfmodex.so"
|
|
||||||
"-DSDL_INCLUDE_DIR=${SDL.dev}/include"
|
|
||||||
];
|
];
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = [ "-I ${SDL.dev}/include/SDL" ];
|
cmakeFlags = [
|
||||||
|
"-DFORCE_INTERNAL_GME=OFF"
|
||||||
|
"-DGME_INCLUDE_DIR=${game-music-emu}/include"
|
||||||
|
"-DGME_LIBRARIES=${game-music-emu}/lib/libgme.so"
|
||||||
|
];
|
||||||
|
|
||||||
|
sourceRoot = ".";
|
||||||
|
|
||||||
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
|
NIX_CFLAGS_LINK = [ "-lopenal" "-lfluidsynth" ];
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
sed s@zdoom.pk3@$out/share/zdoom.pk3@ -i src/version.h
|
sed -i \
|
||||||
|
-e "s@/usr/share/sounds/sf2/@${soundfont-fluid}/share/soundfonts/@g" \
|
||||||
|
-e "s@FluidR3_GM.sf2@FluidR3_GM2-2.sf2@g" \
|
||||||
|
src/sound/music_fluidsynth_mididevice.cpp
|
||||||
'';
|
'';
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
|
install -Dm755 zdoom "$out/lib/zdoom/zdoom"
|
||||||
|
for i in *.pk3; do
|
||||||
|
install -Dm644 "$i" "$out/lib/zdoom/$i"
|
||||||
|
done
|
||||||
mkdir -p $out/bin
|
mkdir -p $out/bin
|
||||||
cp zdoom $out/bin
|
ln -s $out/lib/zdoom/zdoom $out/bin/zdoom
|
||||||
mkdir -p $out/share
|
|
||||||
cp zdoom.pk3 $out/share
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = with stdenv.lib; {
|
||||||
homepage = http://zdoom.org/;
|
homepage = "http://zdoom.org/";
|
||||||
description = "Enhanced port of the official DOOM source code";
|
description = "Enhanced port of the official DOOM source code";
|
||||||
license = stdenv.lib.licenses.unfree;
|
# Doom source license, MAME license
|
||||||
maintainers = [ stdenv.lib.maintainers.lassulus ];
|
license = licenses.unfreeRedistributable;
|
||||||
|
platforms = platforms.linux;
|
||||||
|
maintainers = with maintainer;s [ lassulus ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,6 +25,8 @@ stdenv.mkDerivation rec {
|
|||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
|
setupHook = ./setup-hook.sh;
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
homepage = http://p7zip.sourceforge.net/;
|
homepage = http://p7zip.sourceforge.net/;
|
||||||
description = "A port of the 7-zip archiver";
|
description = "A port of the 7-zip archiver";
|
||||||
|
5
pkgs/tools/archivers/p7zip/setup-hook.sh
Normal file
5
pkgs/tools/archivers/p7zip/setup-hook.sh
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
unpackCmdHooks+=(_try7zip)
|
||||||
|
_try7zip() {
|
||||||
|
if ! [[ "$curSrc" =~ \.7z$ ]]; then return 1; fi
|
||||||
|
7z x "$curSrc"
|
||||||
|
}
|
@ -7038,10 +7038,6 @@ in
|
|||||||
fltk13 = callPackage ../development/libraries/fltk { };
|
fltk13 = callPackage ../development/libraries/fltk { };
|
||||||
fltk = self.fltk13;
|
fltk = self.fltk13;
|
||||||
|
|
||||||
fmod = callPackage ../development/libraries/fmod { };
|
|
||||||
|
|
||||||
fmod42416 = callPackage ../development/libraries/fmod/4.24.16.nix { };
|
|
||||||
|
|
||||||
fplll = callPackage ../development/libraries/fplll {};
|
fplll = callPackage ../development/libraries/fplll {};
|
||||||
fplll_20160331 = callPackage ../development/libraries/fplll/20160331.nix {};
|
fplll_20160331 = callPackage ../development/libraries/fplll/20160331.nix {};
|
||||||
|
|
||||||
@ -16178,7 +16174,6 @@ in
|
|||||||
xsokoban = callPackage ../games/xsokoban { };
|
xsokoban = callPackage ../games/xsokoban { };
|
||||||
|
|
||||||
zandronum = callPackage ../games/zandronum {
|
zandronum = callPackage ../games/zandronum {
|
||||||
fmod = fmod42416;
|
|
||||||
cmake = cmake_2_8;
|
cmake = cmake_2_8;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user