forgejo-lts: 7.0.10 -> 7.0.11
[NixPkgs.git] / pkgs / by-name / lf / lftp / package.nix
blob482347a5ab985d8ab029f8f3ded84ada6e2eb81f
1 { lib, stdenv, fetchurl, openssl, pkg-config, readline, zlib, libidn2, gmp, libiconv, libunistring, gettext }:
3 stdenv.mkDerivation rec {
4   pname = "lftp";
5   version = "4.9.2";
7   src = fetchurl {
8     urls = [
9       "https://lftp.yar.ru/ftp/${pname}-${version}.tar.xz"
10       "https://ftp.st.ryukoku.ac.jp/pub/network/ftp/lftp/${pname}-${version}.tar.xz"
11       ];
12     sha256 = "03b7y0h3mf4jfq5y8zw6hv9v44z3n6i8hc1iswax96y3z7sc85y5";
13   };
15   nativeBuildInputs = [ pkg-config ];
17   buildInputs = [ openssl readline zlib libidn2 gmp libiconv libunistring gettext ];
19   hardeningDisable = lib.optional stdenv.hostPlatform.isDarwin "format";
21   env = lib.optionalAttrs stdenv.hostPlatform.isDarwin {
22     # Required to build with clang 16 or `configure` will fail to detect several standard functions.
23     NIX_CFLAGS_COMPILE = "-Wno-error=implicit-function-declaration";
24   };
26   configureFlags = [
27     "--with-openssl"
28     "--with-readline=${readline.dev}"
29     "--with-zlib=${zlib.dev}"
30     "--without-expat"
31   ];
33   installFlags = [ "PREFIX=$(out)" ];
35   enableParallelBuilding = true;
37   meta = with lib; {
38     description = "File transfer program supporting a number of network protocols";
39     homepage = "https://lftp.yar.ru/";
40     license = licenses.gpl3Plus;
41     platforms = platforms.unix;
42     maintainers = [ maintainers.bjornfor ];
43   };