2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv, fetchurl, pkg-config
|
2022-09-09 14:08:57 +00:00
|
|
|
, gnutls
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2021-07-21 07:28:18 +00:00
|
|
|
pname = "ucommon";
|
|
|
|
version = "7.0.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-07-21 07:28:18 +00:00
|
|
|
url = "mirror://gnu/commoncpp/${pname}-${version}.tar.gz";
|
2020-04-24 23:36:52 +00:00
|
|
|
sha256 = "6ac9f76c2af010f97e916e4bae1cece341dc64ca28e3881ff4ddc3bc334060d7";
|
|
|
|
};
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
nativeBuildInputs = [ pkg-config ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
# use C++14 Standard until error handling code gets updated upstream
|
|
|
|
CXXFLAGS = [ "-std=c++14" ];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
# disable flaky networking test
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace test/stream.cpp \
|
|
|
|
--replace 'ifndef UCOMMON_SYSRUNTIME' 'if 0'
|
|
|
|
'';
|
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
# ucommon.pc has link time depdendencies on -lusecure -lucommon -lgnutls
|
|
|
|
propagatedBuildInputs = [ gnutls ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "C++ library to facilitate using C++ design patterns";
|
|
|
|
homepage = "https://www.gnu.org/software/commoncpp/";
|
2021-02-05 17:12:51 +00:00
|
|
|
license = lib.licenses.lgpl3Plus;
|
|
|
|
maintainers = with lib.maintainers; [ ];
|
|
|
|
platforms = lib.platforms.linux;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|