Files
nixpkgs/pkgs/by-name/fl/flips/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

59 lines
1.2 KiB
Nix

{
lib,
stdenv,
fetchFromGitea,
libdivsufsort,
pkg-config,
withGTK3 ? !stdenv.hostPlatform.isDarwin,
gtk3,
llvmPackages,
wrapGAppsHook3,
}:
stdenv.mkDerivation rec {
pname = "flips";
version = "198";
src = fetchFromGitea {
domain = "git.disroot.org";
owner = "Sir_Walrus";
repo = "Flips";
tag = "v${version}";
hash = "sha256-zYGDcUbtzstk1sTKgX2Mna0rzH7z6Dic+OvjZLI1umI=";
};
nativeBuildInputs = [
pkg-config
]
++ lib.optional withGTK3 wrapGAppsHook3;
buildInputs = [
libdivsufsort
]
++ lib.optional withGTK3 gtk3
++ lib.optional (withGTK3 && stdenv.hostPlatform.isDarwin) llvmPackages.openmp;
patches = [ ./use-system-libdivsufsort.patch ];
makeFlags = [
"PREFIX=${placeholder "out"}"
"TARGET=${if withGTK3 then "gtk" else "cli"}"
];
installPhase = lib.optionalString (!withGTK3) ''
runHook preInstall
install -Dm755 flips -t $out/bin
runHook postInstall
'';
meta = {
description = "Patcher for IPS and BPS files";
homepage = "https://git.disroot.org/Sir_Walrus/Flips";
license = lib.licenses.gpl3Plus;
maintainers = with lib.maintainers; [ aleksana ];
platforms = lib.platforms.unix;
mainProgram = "flips";
};
}