From dc3223adb251b360dfa33f1827ce94ad6a571859 Mon Sep 17 00:00:00 2001 From: Ethan Yonker Date: Mon, 22 Dec 2014 14:31:37 -0600 Subject: toolbox_recovery should always include setenforce init does not follow symlinks and we need setenforce to be able to set permissive. toolbox_recovery will now always include the setenforce tool even if busybox has it so that our provided init.rc can run /sbin/toolbox setenforce 0 successfully. The symlink for setenforce will remain pointing to busybox if busybox has setenforce. Change-Id: I88a2a99bbed30cef3443ac5d94665e3850872237 --- toolbox/Android.mk | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'toolbox') diff --git a/toolbox/Android.mk b/toolbox/Android.mk index a08e78d38..93e96a8a9 100644 --- a/toolbox/Android.mk +++ b/toolbox/Android.mk @@ -107,7 +107,7 @@ ifneq (,$(filter userdebug eng,$(TARGET_BUILD_VARIANT))) OUR_TOOLS += r endif -ALL_TOOLS = $(BSD_TOOLS) $(OUR_TOOLS) +ALL_TOOLS = $(BSD_TOOLS) $(OUR_TOOLS) setenforce LOCAL_SRC_FILES := \ upstream-netbsd/lib/libc/gen/getbsize.c \ @@ -120,6 +120,10 @@ LOCAL_SRC_FILES := \ $(patsubst %,%.c,$(OUR_TOOLS)) \ toolbox.c \ +ifeq (,$(filter $(LOCAL_SRC_FILES),setenforce.c)) + LOCAL_SRC_FILES += setenforce.c +endif + LOCAL_CFLAGS += $(common_cflags) LOCAL_C_INCLUDES += external/openssl/include -- cgit v1.2.3