2022-05-18 14:49:53 +00:00
|
|
|
{ lib, fetchurl, fetchpatch, stdenv, zlib, ncurses, libiconv }:
|
2022-03-30 09:31:56 +00:00
|
|
|
|
2024-01-02 11:29:13 +00:00
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
2022-03-30 09:31:56 +00:00
|
|
|
pname = "fnc";
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "0.16";
|
2022-03-30 09:31:56 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2024-01-02 11:29:13 +00:00
|
|
|
url = "https://fnc.bsdbox.org/tarball/${finalAttrs.version}/fnc-${finalAttrs.version}.tar.gz";
|
|
|
|
hash = "sha256-6I6wtSMHaKdnlUK4pYiaybJeODGu2P+smYW8lQDIWGM=";
|
2022-03-30 09:31:56 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ libiconv ncurses zlib ];
|
|
|
|
|
|
|
|
makeFlags = [ "PREFIX=$(out)" ];
|
|
|
|
|
2023-03-04 12:14:45 +00:00
|
|
|
env.NIX_CFLAGS_COMPILE = toString (lib.optionals stdenv.cc.isGNU [
|
2023-02-16 17:41:37 +00:00
|
|
|
# Needed with GCC 12
|
|
|
|
"-Wno-error=maybe-uninitialized"
|
2024-01-02 11:29:13 +00:00
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
|
|
# error: 'strtonum' is only available on macOS 11.0 or newer
|
|
|
|
"-Wno-error=unguarded-availability-new"
|
2023-03-04 12:14:45 +00:00
|
|
|
]);
|
2023-02-16 17:41:37 +00:00
|
|
|
|
2022-03-30 09:31:56 +00:00
|
|
|
preInstall = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Interactive ncurses browser for Fossil repositories";
|
|
|
|
longDescription = ''
|
|
|
|
An interactive ncurses browser for Fossil repositories.
|
|
|
|
|
|
|
|
fnc uses libfossil to create a fossil ui experience in the terminal.
|
|
|
|
'';
|
|
|
|
homepage = "https://fnc.bsdbox.org";
|
|
|
|
license = licenses.isc;
|
|
|
|
platforms = platforms.all;
|
|
|
|
maintainers = with maintainers; [ abbe ];
|
2024-01-02 11:29:13 +00:00
|
|
|
mainProgram = "fnc";
|
2022-03-30 09:31:56 +00:00
|
|
|
};
|
2024-01-02 11:29:13 +00:00
|
|
|
})
|