Skip to content

Instantly share code, notes, and snippets.

@infinisil
Forked from cleverca22/scyther.nix
Last active June 22, 2017 00:52
Show Gist options
  • Save infinisil/0e95855e41e40a148ba9d2d82ce11d4f to your computer and use it in GitHub Desktop.
Save infinisil/0e95855e41e40a148ba9d2d82ce11d4f to your computer and use it in GitHub Desktop.
with (import <nixpkgs> {}).pkgsi686Linux;
stdenv.mkDerivation rec {
name = "scyther-${version}";
version = "1.1.3";
src = pkgs.fetchFromGitHub {
owner = "cascremers";
repo = "scyther";
rev = "v${version}";
sha256 = "0rb4ha5bnjxnwj4f3hciq7kyj96fhw14hqbwl5kr9cdw8q62mx0h";
};
preConfigure = ''
cd src
echo "#define TAGVERSION \"${src.rev}\"" >> version.h
'';
dontUseCmakeBuildDir = true;
cmakeFlags = [ "-DCMAKE_BUILD_TYPE:STRING=Release" ];
buildInputs = [
cmake
flex
bison
];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment