nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 20.09 25 lines 863 B view raw
1{ stdenv, cmake, fetchFromGitHub }: 2 3stdenv.mkDerivation rec { 4 name = "libraspberrypi"; 5 version = "2020-05-28"; 6 src = fetchFromGitHub { 7 owner = "raspberrypi"; 8 repo = "userland"; 9 rev = "f97b1af1b3e653f9da2c1a3643479bfd469e3b74"; 10 sha256 = "1r7n05rv96hqjq0rn0qzchmfqs0j7vh3p8jalgh66s6l0vms5mwy"; 11 }; 12 13 cmakeFlags = if (stdenv.targetPlatform.system == "aarch64-linux") 14 then "-DARM64=ON" 15 else "-DARM64=OFF"; 16 preConfigure = ''cmakeFlags="$cmakeFlags -DVMCS_INSTALL_PREFIX=$out"''; 17 nativeBuildInputs = [ cmake ]; 18 meta = with stdenv.lib; { 19 description = "Userland libraries for interfacing with Raspberry Pi hardware"; 20 homepage = "https://github.com/raspberrypi/userland"; 21 license = licenses.bsd3; 22 platforms = [ "armv6l-linux" "armv7l-linux" "aarch64-linux" ]; 23 maintainers = with maintainers; [ tkerber ]; 24 }; 25}