about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/libssh2/default.nix
blob: 1b5d65335b8d0909c002babd6d52e74b9f2d3c7f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
{ lib, stdenv, fetchurl, openssl, zlib, windows }:

stdenv.mkDerivation rec {
  pname = "libssh2";
  version = "1.10.0";

  src = fetchurl {
    url = "https://www.libssh2.org/download/libssh2-${version}.tar.gz";
    sha256 = "sha256-LWTpDz3tOUuR06LndMogOkF59prr7gMAPlpvpiHkHVE=";
  };

  outputs = [ "out" "dev" "devdoc" ];

  patches = [
    # https://github.com/libssh2/libssh2/pull/700
    # openssl: add support for LibreSSL 3.5.x
    ./openssl_add_support_for_libressl_3_5.patch
  ];

  buildInputs = [ openssl zlib ]
    ++ lib.optional stdenv.hostPlatform.isMinGW windows.mingw_w64;

  meta = with lib; {
    description = "A client-side C library implementing the SSH2 protocol";
    homepage = "https://www.libssh2.org";
    platforms = platforms.all;
    license = licenses.bsd3;
    maintainers = with maintainers; [ SuperSandro2000 ];
  };
}