nixpkgs/pkgs/games/gmad/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

36 lines
911 B
Nix
Raw Normal View History

2021-01-15 04:31:39 +00:00
{ lib, stdenv, fetchFromGitHub, premake4, bootil }:
2016-10-24 16:54:50 +00:00
stdenv.mkDerivation rec {
2021-06-22 21:44:58 +00:00
pname = "gmad";
version = "unstable-2020-02-24";
2016-10-24 16:54:50 +00:00
meta = {
description = "Garry's Mod Addon Creator and Extractor";
homepage = "https://github.com/Facepunch/gmad";
2021-01-15 04:31:39 +00:00
license = lib.licenses.unfree;
maintainers = [ lib.maintainers.abigailbuccaneer ];
platforms = lib.platforms.all;
2016-10-24 16:54:50 +00:00
};
src = fetchFromGitHub {
owner = "Facepunch";
2016-10-24 16:54:50 +00:00
repo = "gmad";
rev = "5236973a2fcbb3043bdd3d4529ce68b6d938ad93";
sha256="04an17nvnj38mpi0w005v41ib8ynb5qhgrdkmsda4hq7l1gn276s";
2016-10-24 16:54:50 +00:00
};
buildInputs = [ premake4 bootil ];
targetName =
if stdenv.isLinux then "gmad_linux"
else if stdenv.isDarwin then "gmad_osx"
else "gmad";
premakeFlags = [ "--bootil_lib=${bootil}/lib" "--bootil_inc=${bootil}/include" ];
2016-10-24 16:54:50 +00:00
installPhase = ''
mkdir -p $out/bin
cp ${targetName} $out/bin/gmad
'';
}