2018-06-17 02:21:41 +03:00
|
|
|
|
{ config, lib, pkgs, ... }:
|
|
|
|
|
|
|
|
|
|
with lib;
|
|
|
|
|
|
2018-06-17 03:43:19 +03:00
|
|
|
|
let
|
|
|
|
|
cfg = config.mobile.hardware.socs;
|
|
|
|
|
in
|
2018-06-17 02:21:41 +03:00
|
|
|
|
{
|
|
|
|
|
options.mobile = {
|
2018-07-02 00:58:30 +03:00
|
|
|
|
hardware.socs.qualcomm-apq8064-1aa.enable = mkOption {
|
|
|
|
|
type = types.bool;
|
|
|
|
|
default = false;
|
|
|
|
|
description = "enable when SOC is APQ8064–1AA";
|
|
|
|
|
};
|
2018-06-17 03:43:19 +03:00
|
|
|
|
hardware.socs.qualcomm-msm8939.enable = mkOption {
|
2018-06-17 02:21:41 +03:00
|
|
|
|
type = types.bool;
|
|
|
|
|
default = false;
|
|
|
|
|
description = "enable when SOC is msm8939";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
2018-07-02 00:58:30 +03:00
|
|
|
|
config = mkMerge [
|
|
|
|
|
{
|
|
|
|
|
mobile = mkIf cfg.qualcomm-msm8939.enable {
|
|
|
|
|
system.platform = "aarch64-linux";
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
{
|
|
|
|
|
mobile = mkIf cfg.qualcomm-apq8064-1aa.enable {
|
|
|
|
|
system.platform = "armv7a-linux";
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
];
|
2018-06-17 02:21:41 +03:00
|
|
|
|
}
|