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 { 10 pname = "libraspberrypi"; 11 version = "0-unstable-2022-06-16"; 12 13 src = fetchFromGitHub { 14 owner = "raspberrypi"; 15 repo = "userland"; 16 rev = "54fd97ae4066a10b6b02089bc769ceed328737e0"; 17 hash = "sha512-f7tBgIykcIdkwcFjBKk5ooD/5Bsyrd/0OFr7LNCwWFYeE4DH3XA7UR7YjArkwqUVCVBByr82EOaacw0g1blOkw=="; 18 }; 19 20 nativeBuildInputs = [ 21 cmake 22 pkg-config 23 ]; 24 cmakeFlags = [ 25 # -DARM64=ON disables all targets that only build on 32-bit ARM; this allows 26 # the package to build on aarch64 and other architectures 27 "-DARM64=${if stdenv.hostPlatform.isAarch32 then "OFF" else "ON"}" 28 "-DVMCS_INSTALL_PREFIX=${placeholder "out"}" 29 ]; 30 31 meta = with lib; { 32 description = "Userland tools & libraries for interfacing with Raspberry Pi hardware"; 33 homepage = "https://github.com/raspberrypi/userland"; 34 license = licenses.bsd3; 35 platforms = [ 36 "armv6l-linux" 37 "armv7l-linux" 38 "aarch64-linux" 39 "x86_64-linux" 40 ]; 41 maintainers = with maintainers; [ 42 dezgeg 43 tkerber 44 ]; 45 }; 46}