Merge pull request #157633 from AndersonTorres/new-misc
Misc modifications: - dosbox: use desktopItems machinery - munt: 2.5.0 -> 2.5.3
This commit is contained in:
commit
4269133f09
@ -1,50 +1,52 @@
|
||||
{ lib
|
||||
, mkDerivation
|
||||
, stdenv
|
||||
, mkDerivation
|
||||
, fetchFromGitHub
|
||||
, makeDesktopItem
|
||||
, alsa-lib
|
||||
, cmake
|
||||
, glib
|
||||
, pkg-config
|
||||
, qtbase
|
||||
, glib
|
||||
, alsa-lib
|
||||
, withJack ? stdenv.hostPlatform.isUnix, jack
|
||||
}:
|
||||
|
||||
let
|
||||
mainProgram = "mt32emu-qt";
|
||||
in
|
||||
mkDerivation rec {
|
||||
pname = "munt";
|
||||
version = "2.5.0";
|
||||
version = "2.5.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = pname;
|
||||
repo = pname;
|
||||
rev = "munt_${lib.replaceChars [ "." ] [ "_" ] version}";
|
||||
sha256 = "1lknq2a72gv1ddhzr7f967wpa12lh805jj4gjacdnamgrc1h22yn";
|
||||
rev = "libmt32emu_${lib.replaceChars [ "." ] [ "_" ] version}";
|
||||
hash = "sha256-n5VV5Swh1tOVQGT3urEKl64A/w7cY95/0y5wC5ZuLm4=";
|
||||
};
|
||||
|
||||
dontFixCmake = true;
|
||||
|
||||
nativeBuildInputs = [ cmake pkg-config ];
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = [ qtbase glib ]
|
||||
++ lib.optional stdenv.hostPlatform.isLinux alsa-lib
|
||||
++ lib.optional withJack jack;
|
||||
buildInputs = [
|
||||
glib
|
||||
qtbase
|
||||
]
|
||||
++ lib.optional stdenv.hostPlatform.isLinux alsa-lib
|
||||
++ lib.optional withJack jack;
|
||||
|
||||
postInstall = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
||||
mkdir $out/Applications
|
||||
mv $out/bin/${mainProgram}.app $out/Applications/
|
||||
ln -s $out/{Applications/${mainProgram}.app/Contents/MacOS,bin}/${mainProgram}
|
||||
mv $out/bin/${meta.mainProgram}.app $out/Applications/
|
||||
ln -s $out/{Applications/${meta.mainProgram}.app/Contents/MacOS,bin}/${meta.mainProgram}
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
inherit mainProgram;
|
||||
description = "Multi-platform software synthesiser emulating Roland MT-32, CM-32L, CM-64 and LAPC-I devices";
|
||||
homepage = "http://munt.sourceforge.net/";
|
||||
description = "An emulator of Roland MT-32, CM-32L, CM-64 and LAPC-I devices";
|
||||
license = with licenses; [ lgpl21 gpl3 ];
|
||||
platforms = platforms.all;
|
||||
maintainers = with maintainers; [ OPNA2608 ];
|
||||
platforms = platforms.all;
|
||||
mainProgram = "mt32emu-qt";
|
||||
};
|
||||
}
|
||||
|
@ -1,4 +1,16 @@
|
||||
{ stdenv, lib, fetchurl, makeDesktopItem, SDL, SDL_net, SDL_sound, libGLU, libGL, libpng, graphicsmagick }:
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, SDL
|
||||
, SDL_net
|
||||
, SDL_sound
|
||||
, copyDesktopItems
|
||||
, graphicsmagick
|
||||
, libGL
|
||||
, libGLU
|
||||
, libpng
|
||||
, makeDesktopItem
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "dosbox";
|
||||
@ -6,31 +18,40 @@ stdenv.mkDerivation rec {
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/dosbox/dosbox-${version}.tar.gz";
|
||||
sha256 = "02i648i50dwicv1vaql15rccv4g8h5blf5g6inv67lrfxpbkvlf0";
|
||||
hash = "sha256-wNE91+0u02O2jeYVR1eB6JHNWC6BYrXDZpE3UCIiJgo=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
copyDesktopItems
|
||||
graphicsmagick
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
SDL
|
||||
SDL_net
|
||||
SDL_sound
|
||||
libGL
|
||||
libGLU
|
||||
libpng
|
||||
];
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
||||
buildInputs = [ SDL SDL_net SDL_sound libGLU libGL libpng ];
|
||||
|
||||
nativeBuildInputs = [ graphicsmagick ];
|
||||
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
desktopItem = makeDesktopItem {
|
||||
name = "dosbox";
|
||||
exec = "dosbox";
|
||||
icon = "dosbox";
|
||||
comment = "x86 emulator with internal DOS";
|
||||
desktopName = "DOSBox";
|
||||
genericName = "DOS emulator";
|
||||
categories = "Emulator;";
|
||||
};
|
||||
desktopItems = [
|
||||
(makeDesktopItem {
|
||||
name = "dosbox";
|
||||
exec = "dosbox";
|
||||
icon = "dosbox";
|
||||
comment = "x86 dos emulator";
|
||||
desktopName = "DOSBox";
|
||||
genericName = "DOS emulator";
|
||||
categories = "Emulator;Game;";
|
||||
})
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/share/applications
|
||||
cp ${desktopItem}/share/applications/* $out/share/applications
|
||||
|
||||
mkdir -p $out/share/icons/hicolor/256x256/apps
|
||||
gm convert src/dosbox.ico $out/share/icons/hicolor/256x256/apps/dosbox.png
|
||||
'';
|
||||
@ -40,8 +61,15 @@ stdenv.mkDerivation rec {
|
||||
meta = with lib; {
|
||||
homepage = "http://www.dosbox.com/";
|
||||
description = "A DOS emulator";
|
||||
platforms = platforms.unix;
|
||||
longDescription = ''
|
||||
DOSBox is an emulator that recreates a MS-DOS compatible environment
|
||||
(complete with Sound, Input, Graphics and even basic networking). This
|
||||
environment is complete enough to run many classic MS-DOS games completely
|
||||
unmodified. In order to utilize all of DOSBox's features you need to first
|
||||
understand some basic concepts about the MS-DOS environment.
|
||||
'';
|
||||
license = licenses.gpl2Plus;
|
||||
maintainers = with maintainers; [ matthewbauer ];
|
||||
license = licenses.gpl2;
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user