summaryrefslogtreecommitdiffstats
path: root/toolbox/Android.mk
diff options
context:
space:
mode:
Diffstat (limited to 'toolbox/Android.mk')
-rw-r--r--toolbox/Android.mk25
1 files changed, 19 insertions, 6 deletions
diff --git a/toolbox/Android.mk b/toolbox/Android.mk
index c53f17d..fb2c5c7 100644
--- a/toolbox/Android.mk
+++ b/toolbox/Android.mk
@@ -1,4 +1,17 @@
LOCAL_PATH:= $(call my-dir)
+
+common_cflags := \
+ -std=gnu99 \
+ -Werror -Wno-unused-parameter \
+ -include bsd-compatibility.h \
+
+include $(CLEAR_VARS)
+LOCAL_SRC_FILES := upstream-netbsd/bin/kill/kill.c
+LOCAL_CFLAGS += $(common_cflags) -Dmain=kill_main
+LOCAL_MODULE := libtoolbox_kill
+LOCAL_ADDITIONAL_DEPENDENCIES += $(LOCAL_PATH)/Android.mk
+include $(BUILD_STATIC_LIBRARY)
+
include $(CLEAR_VARS)
TOOLS := \
@@ -24,7 +37,6 @@ TOOLS := \
insmod \
ioctl \
ionice \
- kill \
ln \
load_policy \
log \
@@ -79,7 +91,8 @@ endif
ALL_TOOLS = $(TOOLS)
ALL_TOOLS += \
cp \
- grep
+ grep \
+ kill \
LOCAL_SRC_FILES := \
cp/cp.c \
@@ -94,10 +107,7 @@ LOCAL_SRC_FILES := \
toolbox.c \
uid_from_user.c \
-LOCAL_CFLAGS += \
- -std=gnu99 \
- -Werror -Wno-unused-parameter \
- -include bsd-compatibility.h \
+LOCAL_CFLAGS += $(common_cflags)
LOCAL_C_INCLUDES += external/openssl/include
@@ -111,6 +121,9 @@ LOCAL_SHARED_LIBRARIES := \
LOCAL_STATIC_LIBRARIES := \
libusbhost \
+LOCAL_WHOLE_STATIC_LIBRARIES := \
+ libtoolbox_kill \
+
LOCAL_MODULE := toolbox
LOCAL_ADDITIONAL_DEPENDENCIES += $(LOCAL_PATH)/Android.mk