Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 73 lines 1.4 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 pkg-config, 6 makeWrapper, 7 meson, 8 ninja, 9 wayland-scanner, 10 libjpeg, 11 libpng, 12 libX11, 13 libGL, 14 libdrm, 15 udev, 16 wayland, 17 wayland-protocols, 18 libgbm, 19}: 20 21stdenv.mkDerivation rec { 22 pname = "glmark2"; 23 version = "2023.01"; 24 25 src = fetchFromGitHub { 26 owner = "glmark2"; 27 repo = "glmark2"; 28 rev = version; 29 sha256 = "sha256-WCvc5GqrAdpIKQ4LVqwO6ZGbzBgLCl49NxiGJynIjSQ="; 30 }; 31 32 depsBuildBuild = [ pkg-config ]; 33 nativeBuildInputs = [ 34 pkg-config 35 makeWrapper 36 meson 37 ninja 38 wayland-scanner 39 ]; 40 buildInputs = [ 41 libjpeg 42 libpng 43 libX11 44 libdrm 45 udev 46 wayland 47 wayland-protocols 48 libgbm 49 ]; 50 51 mesonFlags = [ 52 "-Dflavors=drm-gl,drm-glesv2,gbm-gl,gbm-glesv2,wayland-gl,wayland-glesv2,x11-gl,x11-gl-egl,x11-glesv2" 53 ]; 54 55 postInstall = '' 56 for binary in $out/bin/glmark2*; do 57 wrapProgram $binary \ 58 --prefix LD_LIBRARY_PATH ":" ${libGL}/lib 59 done 60 ''; 61 62 meta = with lib; { 63 description = "OpenGL (ES) 2.0 benchmark"; 64 homepage = "https://github.com/glmark2/glmark2"; 65 license = licenses.gpl3Plus; 66 longDescription = '' 67 glmark2 is a benchmark for OpenGL (ES) 2.0. It uses only the subset of 68 the OpenGL 2.0 API that is compatible with OpenGL ES 2.0. 69 ''; 70 platforms = platforms.linux; 71 maintainers = [ maintainers.wmertens ]; 72 }; 73}