mirror of
https://github.com/NixOS/nixos-hardware
synced 2024-11-01 08:39:41 +01:00
gpd-win-max-2-2023/bmi260: 0.0.2 -> 1.0.0
This commit is contained in:
parent
99918dfbd7
commit
f682fedae0
2 changed files with 18 additions and 14 deletions
|
@ -1,4 +1,4 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, ... }:
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
|
@ -28,6 +28,9 @@ in
|
||||||
|
|
||||||
config = mkIf config.hardware.sensor.iio.bmi260.enable {
|
config = mkIf config.hardware.sensor.iio.bmi260.enable {
|
||||||
boot.extraModulePackages = [ bmi260 ];
|
boot.extraModulePackages = [ bmi260 ];
|
||||||
boot.kernelModules = [ "bmi260_core" "bmi260_i2c" ];
|
boot.kernelModules = [
|
||||||
|
"bmi260_core"
|
||||||
|
"bmi260_i2c"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,28 +1,26 @@
|
||||||
{ lib
|
{
|
||||||
, stdenv
|
lib,
|
||||||
, fetchFromGitHub
|
stdenv,
|
||||||
, fetchurl
|
fetchFromGitHub,
|
||||||
, kernel
|
kernel,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation (finalAttr: {
|
stdenv.mkDerivation (finalAttr: {
|
||||||
pname = "bmi260";
|
pname = "bmi260";
|
||||||
version = "0.0.2";
|
version = "1.0.0";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "hhd-dev";
|
owner = "hhd-dev";
|
||||||
repo = finalAttr.pname;
|
repo = finalAttr.pname;
|
||||||
rev = "v${finalAttr.version}";
|
rev = "v${finalAttr.version}";
|
||||||
hash = "sha256-J0npD75QqOGY1QUoznBjQ+jX28gq5u6b0JZOseclwE8=";
|
hash = "sha256-EFous0pPpCuVoCsFz6/4NryQRSH9Jw9Qng+RY1hiX1c=";
|
||||||
};
|
};
|
||||||
|
|
||||||
hardeningDisable = [ "pic" ];
|
hardeningDisable = [ "pic" ];
|
||||||
|
|
||||||
nativeBuildInputs = kernel.moduleBuildDependencies;
|
nativeBuildInputs = kernel.moduleBuildDependencies;
|
||||||
|
|
||||||
makeFlags = [
|
makeFlags = [ "KERNEL_SRC=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build" ];
|
||||||
"KERNEL_SRC=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
|
|
||||||
];
|
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
runHook preInstall
|
runHook preInstall
|
||||||
|
@ -34,8 +32,11 @@ stdenv.mkDerivation (finalAttr: {
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
homepage = "https://github.com/hhd-dev/bmi260";
|
homepage = "https://github.com/hhd-dev/bmi260";
|
||||||
description = "A kernel module driver for the Bosch BMI260 IMU";
|
description = "A kernel driver for the Bosch BMI260 IMU";
|
||||||
license = with licenses; [ bsd3 gpl2Only ];
|
license = with licenses; [
|
||||||
|
bsd3
|
||||||
|
gpl2Only
|
||||||
|
];
|
||||||
maintainers = with maintainers; [ Cryolitia ];
|
maintainers = with maintainers; [ Cryolitia ];
|
||||||
platforms = platforms.linux;
|
platforms = platforms.linux;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue