Android.mk 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353
  1. # Android makefile for display kernel modules
  2. TOUCH_DLKM_ENABLE := true
  3. ifeq ($(TARGET_KERNEL_DLKM_DISABLE), true)
  4. ifeq ($(TARGET_KERNEL_DLKM_TOUCH_OVERRIDE), false)
  5. TOUCH_DLKM_ENABLE := false
  6. endif
  7. endif
  8. ifeq ($(TOUCH_DLKM_ENABLE), true)
  9. TOUCH_SELECT := CONFIG_MSM_TOUCH=m
  10. BOARD_OPENSOURCE_DIR ?= vendor/qcom/opensource
  11. BOARD_COMMON_DIR ?= device/qcom/common
  12. LOCAL_PATH := $(call my-dir)
  13. ifeq ($(TARGET_BOARD_PLATFORM), pineapple)
  14. LOCAL_MODULE_DDK_BUILD := true
  15. endif
  16. ifeq ($(TARGET_BOARD_PLATFORM), blair)
  17. LOCAL_MODULE_DDK_BUILD := true
  18. endif
  19. ifeq ($(TARGET_BOARD_PLATFORM), pitti)
  20. LOCAL_MODULE_DDK_BUILD := true
  21. endif
  22. ifeq ($(TARGET_BOARD_PLATFORM), monaco)
  23. LOCAL_MODULE_DDK_BUILD := true
  24. endif
  25. include $(CLEAR_VARS)
  26. # This makefile is only for DLKM
  27. ifneq ($(findstring vendor,$(LOCAL_PATH)),)
  28. ifneq ($(findstring opensource,$(LOCAL_PATH)),)
  29. TOUCH_BLD_DIR := $(shell pwd)/$(BOARD_OPENSOURCE_DIR)/touch-drivers
  30. endif # opensource
  31. DLKM_DIR := $(TOP)/$(BOARD_COMMON_DIR)/dlkm
  32. LOCAL_ADDITIONAL_DEPENDENCIES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  33. # Build
  34. ###########################################################
  35. # This is set once per LOCAL_PATH, not per (kernel) module
  36. KBUILD_OPTIONS := TOUCH_ROOT=$(TOUCH_BLD_DIR)
  37. KBUILD_OPTIONS += MODNAME=touch_dlkm
  38. KBUILD_OPTIONS += BOARD_PLATFORM=$(TARGET_BOARD_PLATFORM)
  39. KBUILD_OPTIONS += $(TOUCH_SELECT)
  40. ###########################################################
  41. ifeq ($(TARGET_BOARD_PLATFORM), monaco)
  42. ###########################################################
  43. include $(CLEAR_VARS)
  44. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  45. LOCAL_MODULE := pt_ts.ko
  46. LOCAL_MODULE_KBUILD_NAME := pt_ts.ko
  47. LOCAL_MODULE_TAGS := optional
  48. #LOCAL_MODULE_DEBUG_ENABLE := true
  49. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  50. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  51. ###########################################################
  52. ###########################################################
  53. include $(CLEAR_VARS)
  54. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  55. LOCAL_MODULE := pt_i2c.ko
  56. LOCAL_MODULE_KBUILD_NAME := pt_i2c.ko
  57. LOCAL_MODULE_TAGS := optional
  58. #LOCAL_MODULE_DEBUG_ENABLE := true
  59. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  60. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  61. ###########################################################
  62. ###########################################################
  63. include $(CLEAR_VARS)
  64. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  65. LOCAL_MODULE := pt_device_access.ko
  66. LOCAL_MODULE_KBUILD_NAME := pt_device_access.ko
  67. LOCAL_MODULE_TAGS := optional
  68. #LOCAL_MODULE_DEBUG_ENABLE := true
  69. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  70. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  71. ###########################################################
  72. ###########################################################
  73. include $(CLEAR_VARS)
  74. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  75. LOCAL_MODULE := raydium_ts.ko
  76. LOCAL_MODULE_KBUILD_NAME := raydium_ts.ko
  77. LOCAL_MODULE_TAGS := optional
  78. #LOCAL_MODULE_DEBUG_ENABLE := true
  79. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  80. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  81. ###########################################################
  82. else ifeq ($(TARGET_BOARD_PLATFORM), kona)
  83. ###########################################################
  84. include $(CLEAR_VARS)
  85. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  86. LOCAL_MODULE := focaltech_fts.ko
  87. LOCAL_MODULE_KBUILD_NAME := focaltech_fts.ko
  88. LOCAL_MODULE_TAGS := optional
  89. #LOCAL_MODULE_DEBUG_ENABLE := true
  90. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  91. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  92. ###########################################################
  93. else ifeq ($(TARGET_BOARD_PLATFORM), pineapple)
  94. ###########################################################
  95. include $(CLEAR_VARS)
  96. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  97. LOCAL_MODULE := nt36xxx-i2c.ko
  98. LOCAL_MODULE_KBUILD_NAME := nt36xxx-i2c.ko
  99. LOCAL_MODULE_TAGS := optional
  100. #LOCAL_MODULE_DEBUG_ENABLE := true
  101. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  102. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  103. ###########################################################
  104. ###########################################################
  105. include $(CLEAR_VARS)
  106. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  107. LOCAL_MODULE := goodix_ts.ko
  108. LOCAL_MODULE_KBUILD_NAME := goodix_ts.ko
  109. LOCAL_MODULE_TAGS := optional
  110. #LOCAL_MODULE_DEBUG_ENABLE := true
  111. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  112. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  113. ###########################################################
  114. ###########################################################
  115. include $(CLEAR_VARS)
  116. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  117. LOCAL_MODULE := atmel_mxt_ts.ko
  118. LOCAL_MODULE_KBUILD_NAME := atmel_mxt_ts.ko
  119. LOCAL_MODULE_TAGS := optional
  120. #LOCAL_MODULE_DEBUG_ENABLE := true
  121. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  122. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  123. ###########################################################
  124. else ifeq ($(TARGET_BOARD_PLATFORM), kalama)
  125. ###########################################################
  126. include $(CLEAR_VARS)
  127. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  128. LOCAL_MODULE := nt36xxx-i2c.ko
  129. LOCAL_MODULE_KBUILD_NAME := nt36xxx-i2c.ko
  130. LOCAL_MODULE_TAGS := optional
  131. #LOCAL_MODULE_DEBUG_ENABLE := true
  132. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  133. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  134. ###########################################################
  135. ###########################################################
  136. include $(CLEAR_VARS)
  137. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  138. LOCAL_MODULE := goodix_ts.ko
  139. LOCAL_MODULE_KBUILD_NAME := goodix_ts.ko
  140. LOCAL_MODULE_TAGS := optional
  141. #LOCAL_MODULE_DEBUG_ENABLE := true
  142. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  143. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  144. ###########################################################
  145. ###########################################################
  146. include $(CLEAR_VARS)
  147. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  148. LOCAL_MODULE := atmel_mxt_ts.ko
  149. LOCAL_MODULE_KBUILD_NAME := atmel_mxt_ts.ko
  150. LOCAL_MODULE_TAGS := optional
  151. #LOCAL_MODULE_DEBUG_ENABLE := true
  152. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  153. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  154. ###########################################################
  155. else ifeq ($(TARGET_BOARD_PLATFORM), blair)
  156. ###########################################################
  157. include $(CLEAR_VARS)
  158. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  159. LOCAL_MODULE := focaltech_fts.ko
  160. LOCAL_MODULE_KBUILD_NAME := focaltech_fts.ko
  161. LOCAL_MODULE_TAGS := optional
  162. #LOCAL_MODULE_DEBUG_ENABLE := true
  163. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  164. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  165. ###########################################################
  166. ###########################################################
  167. include $(CLEAR_VARS)
  168. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  169. LOCAL_MODULE := nt36xxx-i2c.ko
  170. LOCAL_MODULE_KBUILD_NAME := nt36xxx-i2c.ko
  171. LOCAL_MODULE_TAGS := optional
  172. #LOCAL_MODULE_DEBUG_ENABLE := true
  173. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  174. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  175. ###########################################################
  176. ###########################################################
  177. include $(CLEAR_VARS)
  178. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  179. LOCAL_MODULE := synaptics_tcm_ts.ko
  180. LOCAL_MODULE_KBUILD_NAME := synaptics_tcm_ts.ko
  181. LOCAL_MODULE_TAGS := optional
  182. #LOCAL_MODULE_DEBUG_ENABLE := true
  183. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  184. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  185. ###########################################################
  186. ###########################################################
  187. include $(CLEAR_VARS)
  188. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  189. LOCAL_MODULE := goodix_ts.ko
  190. LOCAL_MODULE_KBUILD_NAME := goodix_ts.ko
  191. LOCAL_MODULE_TAGS := optional
  192. #LOCAL_MODULE_DEBUG_ENABLE := true
  193. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  194. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  195. ###########################################################
  196. else ifeq ($(TARGET_BOARD_PLATFORM), crow)
  197. ###########################################################
  198. include $(CLEAR_VARS)
  199. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  200. LOCAL_MODULE := goodix_ts.ko
  201. LOCAL_MODULE_KBUILD_NAME := goodix_ts.ko
  202. LOCAL_MODULE_TAGS := optional
  203. #LOCAL_MODULE_DEBUG_ENABLE := true
  204. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  205. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  206. ###########################################################
  207. else ifeq ($(TARGET_BOARD_PLATFORM), bengal)
  208. ###########################################################
  209. include $(CLEAR_VARS)
  210. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  211. LOCAL_MODULE := synaptics_tcm_ts.ko
  212. LOCAL_MODULE_KBUILD_NAME := synaptics_tcm_ts.ko
  213. LOCAL_MODULE_TAGS := optional
  214. #LOCAL_MODULE_DEBUG_ENABLE := true
  215. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  216. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  217. ###########################################################
  218. ###########################################################
  219. include $(CLEAR_VARS)
  220. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  221. LOCAL_MODULE := nt36xxx-i2c.ko
  222. LOCAL_MODULE_KBUILD_NAME := nt36xxx-i2c.ko
  223. LOCAL_MODULE_TAGS := optional
  224. #LOCAL_MODULE_DEBUG_ENABLE := true
  225. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  226. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  227. ###########################################################
  228. else ifeq ($(TARGET_BOARD_PLATFORM), trinket)
  229. ###########################################################
  230. include $(CLEAR_VARS)
  231. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  232. LOCAL_MODULE := synaptics_tcm_ts.ko
  233. LOCAL_MODULE_KBUILD_NAME := synaptics_tcm_ts.ko
  234. LOCAL_MODULE_TAGS := optional
  235. #LOCAL_MODULE_DEBUG_ENABLE := true
  236. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  237. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  238. ###########################################################
  239. else ifeq ($(TARGET_BOARD_PLATFORM), pitti)
  240. ###########################################################
  241. include $(CLEAR_VARS)
  242. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  243. LOCAL_MODULE := focaltech_fts.ko
  244. LOCAL_MODULE_KBUILD_NAME := focaltech_fts.ko
  245. LOCAL_MODULE_TAGS := optional
  246. #LOCAL_MODULE_DEBUG_ENABLE := true
  247. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  248. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  249. ###########################################################
  250. ###########################################################
  251. include $(CLEAR_VARS)
  252. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  253. LOCAL_MODULE := goodix_ts.ko
  254. LOCAL_MODULE_KBUILD_NAME := goodix_ts.ko
  255. LOCAL_MODULE_TAGS := optional
  256. #LOCAL_MODULE_DEBUG_ENABLE := true
  257. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  258. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  259. ###########################################################
  260. else
  261. ###########################################################
  262. include $(CLEAR_VARS)
  263. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  264. LOCAL_MODULE := nt36xxx-i2c.ko
  265. LOCAL_MODULE_KBUILD_NAME := nt36xxx-i2c.ko
  266. LOCAL_MODULE_TAGS := optional
  267. #LOCAL_MODULE_DEBUG_ENABLE := true
  268. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  269. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  270. ###########################################################
  271. ###########################################################
  272. include $(CLEAR_VARS)
  273. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  274. LOCAL_MODULE := goodix_ts.ko
  275. LOCAL_MODULE_KBUILD_NAME := goodix_ts.ko
  276. LOCAL_MODULE_TAGS := optional
  277. #LOCAL_MODULE_DEBUG_ENABLE := true
  278. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  279. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  280. ###########################################################
  281. ###########################################################
  282. include $(CLEAR_VARS)
  283. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  284. LOCAL_MODULE := atmel_mxt_ts.ko
  285. LOCAL_MODULE_KBUILD_NAME := atmel_mxt_ts.ko
  286. LOCAL_MODULE_TAGS := optional
  287. #LOCAL_MODULE_DEBUG_ENABLE := true
  288. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  289. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  290. ###########################################################
  291. ###########################################################
  292. include $(CLEAR_VARS)
  293. LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/**/*) $(wildcard $(LOCAL_PATH)/*)
  294. LOCAL_MODULE := synaptics_tcm_ts.ko
  295. LOCAL_MODULE_KBUILD_NAME := synaptics_tcm_ts.ko
  296. LOCAL_MODULE_TAGS := optional
  297. #LOCAL_MODULE_DEBUG_ENABLE := true
  298. LOCAL_MODULE_PATH := $(KERNEL_MODULES_OUT)
  299. include $(DLKM_DIR)/Build_external_kernelmodule.mk
  300. ###########################################################
  301. endif #kona
  302. endif # DLKM check
  303. endif