2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, cmake }:
|
2020-06-15 15:56:04 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "utf8cpp";
|
2021-10-08 15:17:17 +00:00
|
|
|
version = "3.2.1";
|
2020-06-15 15:56:04 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nemtrif";
|
|
|
|
repo = "utfcpp";
|
|
|
|
rev = "v${version}";
|
|
|
|
fetchSubmodules = true;
|
2021-10-08 15:17:17 +00:00
|
|
|
sha256 = "0gsbwif97i025bxgyax4fbf6v9z44zrca4s6wwd8x36ac8qzjppf";
|
2020-06-15 15:56:04 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
cmakeFlags = [
|
|
|
|
"-DCMAKE_INSTALL_LIBDIR=lib"
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [ cmake ];
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
# Tests fail on darwin, probably due to a bug in the test framework:
|
|
|
|
# https://github.com/nemtrif/utfcpp/issues/84
|
|
|
|
doCheck = !stdenv.isDarwin;
|
2020-06-15 15:56:04 +00:00
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-06-15 15:56:04 +00:00
|
|
|
homepage = "https://github.com/nemtrif/utfcpp";
|
|
|
|
description = "UTF-8 with C++ in a Portable Way";
|
2021-10-08 15:17:17 +00:00
|
|
|
license = licenses.boost;
|
2020-06-15 15:56:04 +00:00
|
|
|
maintainers = with maintainers; [ jobojeha ];
|
2021-03-19 17:17:44 +00:00
|
|
|
platforms = platforms.all;
|
2020-06-15 15:56:04 +00:00
|
|
|
};
|
|
|
|
}
|