1{ lib, stdenv, fetchFromGitHub, cmake, boost, openssl }:
2
3stdenv.mkDerivation rec {
4 pname = "cpp-netlib";
5 version = "0.13.0-final";
6
7 src = fetchFromGitHub {
8 owner = pname;
9 repo = pname;
10 rev = "${pname}-${version}";
11 sha256 = "18782sz7aggsl66b4mmi1i0ijwa76iww337fi9sygnplz2hs03a3";
12 fetchSubmodules = true;
13 };
14
15 nativeBuildInputs = [ cmake ];
16 buildInputs = [ boost openssl ];
17
18 cmakeFlags = [
19 "-DCPP-NETLIB_BUILD_SHARED_LIBS=ON"
20 # fatal error: 'boost/asio/stream_socket_service.hpp' file not found
21 "-DCPP-NETLIB_BUILD_EXAMPLES=OFF"
22 "-DCPP-NETLIB_BUILD_TESTS=OFF"
23 ];
24
25 # Most tests make network GET requests to various websites
26 doCheck = false;
27
28 meta = with lib; {
29 description = "Collection of open-source libraries for high level network programming";
30 homepage = "https://cpp-netlib.org";
31 license = licenses.boost;
32 platforms = platforms.all;
33 };
34}