depot/third_party/nixpkgs/pkgs/development/libraries/libphonenumber/default.nix
Default email ce641f4048 Project import generated by Copybara.
GitOrigin-RevId: bc5d68306b40b8522ffb69ba6cff91898c2fbbff
2021-12-06 17:07:01 +01:00

36 lines
828 B
Nix

{ lib, stdenv, fetchFromGitHub, cmake, gtest, boost, pkg-config, protobuf, icu, Foundation }:
stdenv.mkDerivation rec {
pname = "phonenumber";
version = "8.12.37";
src = fetchFromGitHub {
owner = "googlei18n";
repo = "libphonenumber";
rev = "v${version}";
sha256 = "sha256-xLxadSxVY3DjFDQrqj3BuOvdMaKdFSLjocfzovJCBB0=";
};
nativeBuildInputs = [
cmake
gtest
pkg-config
];
buildInputs = [
boost
protobuf
icu
] ++ lib.optional stdenv.isDarwin Foundation;
cmakeDir = "../cpp";
checkPhase = "./libphonenumber_test";
meta = with lib; {
description = "Google's i18n library for parsing and using phone numbers";
homepage = "https://github.com/google/libphonenumber";
license = licenses.asl20;
maintainers = with maintainers; [ illegalprime ];
};
}