aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmit Daniel Kachhap <amit.kachhap@linaro.org>2011-07-22 11:18:04 +0530
committerAmit Daniel Kachhap <amit.kachhap@linaro.org>2011-07-22 11:18:04 +0530
commit23155456786f4bc61cd957504fe8f1719c67f289 (patch)
tree002222f3acc459162f5cffecb8bb26d949bde91c
parenta827caec978a922ba48b6ae590a2e05c5992654b (diff)
downloadpowertop-23155456786f4bc61cd957504fe8f1719c67f289.tar.gz
powertop: android: Fix compilation error for missing css.h
This code adds support for auto generation of css.h in the Android makefile. Signed-off-by: Amit Daniel Kachhap <amit.kachhap@linaro.org>
-rw-r--r--Android.mk11
1 files changed, 11 insertions, 0 deletions
diff --git a/Android.mk b/Android.mk
index e6e73b1..dad2978 100644
--- a/Android.mk
+++ b/Android.mk
@@ -88,3 +88,14 @@ LOCAL_SRC_FILES += \
lib.cpp \
include $(BUILD_EXECUTABLE)
+
+CSSTOH_SOURCE := $(LOCAL_PATH)/csstoh.c
+POWERTOP_CSS_SOURCE := $(LOCAL_PATH)/powertop.css
+GEN_CSSTOH := $(LOCAL_PATH)/csstoh
+GEN_CSS_H := $(LOCAL_PATH)/css.h
+$(GEN_CSS_H):
+ $(CC) -o $(GEN_CSSTOH) $(CSSTOH_SOURCE)
+ ./$(GEN_CSSTOH) $(POWERTOP_CSS_SOURCE) $@
+
+LOCAL_GENERATED_SOURCES += $(GEN_CSS_H)
+