Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 35 lines 990 B view raw
1{ stdenv, cmake, python3, fetchFromGitHub, fetchpatch, emscripten }: 2 3stdenv.mkDerivation rec { 4 pname = "binaryen"; 5 version = "96"; 6 7 src = fetchFromGitHub { 8 owner = "WebAssembly"; 9 repo = "binaryen"; 10 rev = "version_${version}"; 11 sha256 = "1mqpb6yy87aifpbcy0lczi3bp6kddrwi6d0g6lrhjrdxx2kvbdag"; 12 }; 13 14 patches = [ 15 # Adds --minimize-wasm-changes option required by emscripten 2.0.1 16 (fetchpatch { 17 url = "https://patch-diff.githubusercontent.com/raw/WebAssembly/binaryen/pull/3044.patch"; 18 sha256 = "1hdbc9h9zhh2d3bl4sqv6v9psfmny715612bwpjdln0ibdvc129s"; 19 }) 20 ]; 21 22 nativeBuildInputs = [ cmake python3 ]; 23 24 meta = with stdenv.lib; { 25 homepage = "https://github.com/WebAssembly/binaryen"; 26 description = "Compiler infrastructure and toolchain library for WebAssembly, in C++"; 27 platforms = platforms.all; 28 maintainers = with maintainers; [ asppsa ]; 29 license = licenses.asl20; 30 }; 31 32 passthru.tests = { 33 inherit emscripten; 34 }; 35}