Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 cmake, 6 pkg-config, 7}: 8 9stdenv.mkDerivation rec { 10 pname = "cpp-redis"; 11 version = "4.3.1"; 12 13 src = fetchFromGitHub { 14 owner = "cpp-redis"; 15 repo = "cpp_redis"; 16 rev = version; 17 hash = "sha256-dLAnxgldylWWKO3WIyx+F7ylOpRH+0nD7NZjWSOxuwQ="; 18 fetchSubmodules = true; 19 }; 20 21 nativeBuildInputs = [ 22 cmake 23 pkg-config 24 ]; 25 CFLAGS = "-D_GLIBCXX_USE_NANOSLEEP"; 26 patches = [ 27 ./01-fix-sleep_for.patch 28 ]; 29 30 meta = with lib; { 31 description = "C++11 Lightweight Redis client: async, thread-safe, no dependency, pipelining, multi-platform"; 32 homepage = "https://github.com/cpp-redis/cpp_redis"; 33 changelog = "https://github.com/cpp-redis/cpp_redis/blob/${src.rev}/CHANGELOG.md"; 34 license = licenses.mit; 35 maintainers = with maintainers; [ poelzi ]; 36 platforms = platforms.all; 37 }; 38}