default.nix (1155B)
1 { 2 lib, 3 stdenv, 4 fetchFromGitea, 5 autoreconfHook, 6 pkg-config, 7 texinfo, 8 makeWrapper, 9 guile, 10 }: 11 12 stdenv.mkDerivation (finalAttrs: { 13 pname = "msg-cli"; 14 version = "0.1.1"; 15 16 src = fetchFromGitea { 17 domain = "forge.superkamiguru.org"; 18 owner = "MSG"; 19 repo = "msg-cli"; 20 tag = "v${finalAttrs.version}"; 21 hash = "sha256-M/MksKwmV/PQxRtv9cT3KwMquhu2yUyBI9+jQL/vsfA="; 22 }; 23 24 postPatch = '' 25 substituteInPlace msg/machine.scm \ 26 --replace-fail "/opt/homebrew/bin/" "" \ 27 --replace-fail "/usr/local/bin/" "" 28 ''; 29 30 nativeBuildInputs = [ 31 autoreconfHook 32 pkg-config 33 texinfo # For makeinfo 34 makeWrapper 35 ]; 36 37 buildInputs = [ guile ]; 38 39 postInstall = '' 40 wrapProgram $out/bin/msg \ 41 --prefix GUILE_LOAD_PATH : "$out/${guile.siteDir}:$GUILE_LOAD_PATH" \ 42 --prefix GUILE_LOAD_COMPILED_PATH : "$out/${guile.siteCcacheDir}:$GUILE_LOAD_COMPILED_PATH" 43 ''; 44 45 meta = { 46 description = "MacOS Subsystem for Guix"; 47 homepage = "https://forge.superkamiguru.org/MSG/msg-cli"; 48 license = lib.licenses.agpl3Only; 49 maintainers = [ lib.maintainers.sikmir ]; 50 mainProgram = "msg"; 51 }; 52 })