Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 47 lines 1.0 kB view raw
1{ 2 stdenvNoCC, 3 fetchFromGitHub, 4 lib, 5}: 6 7stdenvNoCC.mkDerivation (finalAttrs: { 8 name = "raygui"; 9 version = "4.0"; 10 11 src = fetchFromGitHub { 12 owner = "raysan5"; 13 repo = "raygui"; 14 tag = finalAttrs.version; 15 hash = "sha256-1qnChZYsb0e5LnPhvs6a/R5Ammgj2HWFNe9625sBRo8="; 16 }; 17 18 dontBuild = true; 19 installPhase = '' 20 runHook preInstall 21 22 mkdir -p $out/{include,lib/pkgconfig} 23 24 install -Dm644 $src/src/raygui.h $out/include/raygui.h 25 26 cat <<EOF > $out/lib/pkgconfig/raygui.pc 27 prefix=$out 28 includedir=$out/include 29 30 Name: raygui 31 Description: ${finalAttrs.meta.description} 32 URL: ${finalAttrs.meta.homepage} 33 Version: ${finalAttrs.version} 34 Cflags: -I"{includedir}" 35 EOF 36 37 runHook postInstall 38 ''; 39 40 meta = { 41 description = "Simple and easy-to-use immediate-mode gui library"; 42 homepage = "https://github.com/raysan5/raygui"; 43 license = lib.licenses.zlib; 44 maintainers = with lib.maintainers; [ sigmanificient ]; 45 platforms = lib.platforms.unix; 46 }; 47})