target.bzl 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. load(":touch_modules.bzl", "touch_driver_modules")
  2. load(":touch_modules_build.bzl", "define_target_variant_modules")
  3. load("//msm-kernel:target_variants.bzl", "get_all_la_variants", "get_all_le_variants", "get_all_lxc_variants")
  4. def define_pineapple(t,v):
  5. define_target_variant_modules(
  6. target = t,
  7. variant = v,
  8. registry = touch_driver_modules,
  9. modules = [
  10. "nt36xxx-i2c",
  11. "atmel_mxt_ts",
  12. "dummy_ts",
  13. "goodix_ts"
  14. ],
  15. config_options = [
  16. "TOUCH_DLKM_ENABLE",
  17. "CONFIG_ARCH_PINEAPPLE",
  18. "CONFIG_MSM_TOUCH",
  19. "CONFIG_TOUCHSCREEN_GOODIX_BRL",
  20. "CONFIG_TOUCHSCREEN_NT36XXX_I2C",
  21. "CONFIG_TOUCHSCREEN_ATMEL_MXT",
  22. "CONFIG_TOUCHSCREEN_DUMMY"
  23. ],
  24. )
  25. def define_blair(t,v):
  26. define_target_variant_modules(
  27. target = t,
  28. variant = v,
  29. registry = touch_driver_modules,
  30. modules = [
  31. "nt36xxx-i2c",
  32. "goodix_ts",
  33. "focaltech_fts",
  34. "synaptics_tcm_ts"
  35. ],
  36. config_options = [
  37. "TOUCH_DLKM_ENABLE",
  38. "CONFIG_ARCH_BLAIR",
  39. "CONFIG_MSM_TOUCH",
  40. "CONFIG_TOUCHSCREEN_NT36XXX_I2C",
  41. "CONFIG_TOUCHSCREEN_GOODIX_BRL",
  42. "CONFIG_TOUCH_FOCALTECH",
  43. "CONFIG_TOUCHSCREEN_SYNAPTICS_TCM"
  44. ],
  45. )
  46. def define_touch_target():
  47. for (t, v) in get_all_la_variants() + get_all_le_variants() + get_all_lxc_variants():
  48. if t == "blair":
  49. define_blair(t, v)
  50. else:
  51. define_pineapple(t, v)