summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlambdadroid <lambdadroid@gmail.com>2019-05-12 11:48:04 +0200
committerlambdadroid <lambdadroid@gmail.com>2019-05-12 11:54:38 +0200
commitead0f49cbbe47bf0b4d249cd56715f57ac6454ec (patch)
treee9e7b3609f5ecb09d36484fe805dc6a1cc157b37
parentMerge "language: update Chinese translations" into android-9.0 (diff)
downloadandroid_bootable_recovery-ead0f49cbbe47bf0b4d249cd56715f57ac6454ec.tar
android_bootable_recovery-ead0f49cbbe47bf0b4d249cd56715f57ac6454ec.tar.gz
android_bootable_recovery-ead0f49cbbe47bf0b4d249cd56715f57ac6454ec.tar.bz2
android_bootable_recovery-ead0f49cbbe47bf0b4d249cd56715f57ac6454ec.tar.lz
android_bootable_recovery-ead0f49cbbe47bf0b4d249cd56715f57ac6454ec.tar.xz
android_bootable_recovery-ead0f49cbbe47bf0b4d249cd56715f57ac6454ec.tar.zst
android_bootable_recovery-ead0f49cbbe47bf0b4d249cd56715f57ac6454ec.zip
-rw-r--r--toolbox/Android.mk55
1 files changed, 27 insertions, 28 deletions
diff --git a/toolbox/Android.mk b/toolbox/Android.mk
index 6698491b3..926743850 100644
--- a/toolbox/Android.mk
+++ b/toolbox/Android.mk
@@ -289,6 +289,33 @@ $(TOOLS_H): PRIVATE_CUSTOM_TOOL = echo "/* file generated automatically */" > $@
$(TOOLS_H):
$(transform-generated-source)
+# toolbox setenforce is used during init in non-symlink form, so it was
+# required to be included as part of the suite above. if busybox already
+# provides setenforce, we can omit the toolbox symlink
+TEMP_TOOLS := $(filter-out $(RECOVERY_BUSYBOX_TOOLS), $(ALL_TOOLS))
+ALL_TOOLS := $(TEMP_TOOLS)
+
+# Make /sbin/toolbox launchers for each tool
+SYMLINKS := $(addprefix $(TARGET_RECOVERY_ROOT_OUT)/sbin/,$(ALL_TOOLS))
+$(SYMLINKS): TOOLBOX_BINARY := $(LOCAL_MODULE_STEM)
+$(SYMLINKS): $(LOCAL_INSTALLED_MODULE)
+ @echo "Symlink: $@ -> $(TOOLBOX_BINARY)"
+ @mkdir -p $(dir $@)
+ @rm -rf $@
+ $(hide) ln -sf $(TOOLBOX_BINARY) $@
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := toolbox_symlinks
+LOCAL_MODULE_TAGS := optional
+LOCAL_ADDITIONAL_DEPENDENCIES := $(SYMLINKS)
+include $(BUILD_PHONY_PACKAGE)
+
+ifneq (,$(filter $(PLATFORM_SDK_VERSION),16 17 18))
+ # Only needed if the build system lacks support for LOCAL_ADDITIONAL_DEPENDENCIES
+ ALL_DEFAULT_INSTALLED_MODULES += $(SYMLINKS)
+ ALL_MODULES.$(LOCAL_MODULE).INSTALLED := \
+ $(ALL_MODULES.$(LOCAL_MODULE).INSTALLED) $(SYMLINKS)
+endif
ifeq ($(TW_USE_TOOLBOX), true)
ifeq ($(shell test $(PLATFORM_SDK_VERSION) -gt 23; echo $$?),0)
@@ -320,34 +347,6 @@ ifeq ($(TW_USE_TOOLBOX), true)
endif
endif
-# toolbox setenforce is used during init in non-symlink form, so it was
-# required to be included as part of the suite above. if busybox already
-# provides setenforce, we can omit the toolbox symlink
-TEMP_TOOLS := $(filter-out $(RECOVERY_BUSYBOX_TOOLS), $(ALL_TOOLS))
-ALL_TOOLS := $(TEMP_TOOLS)
-
-# Make /sbin/toolbox launchers for each tool
-SYMLINKS := $(addprefix $(TARGET_RECOVERY_ROOT_OUT)/sbin/,$(ALL_TOOLS))
-$(SYMLINKS): TOOLBOX_BINARY := $(LOCAL_MODULE_STEM)
-$(SYMLINKS): $(LOCAL_INSTALLED_MODULE)
- @echo "Symlink: $@ -> $(TOOLBOX_BINARY)"
- @mkdir -p $(dir $@)
- @rm -rf $@
- $(hide) ln -sf $(TOOLBOX_BINARY) $@
-
-include $(CLEAR_VARS)
-LOCAL_MODULE := toolbox_symlinks
-LOCAL_MODULE_TAGS := optional
-LOCAL_ADDITIONAL_DEPENDENCIES := $(SYMLINKS)
-include $(BUILD_PHONY_PACKAGE)
-
-ifneq (,$(filter $(PLATFORM_SDK_VERSION),16 17 18))
- # Only needed if the build system lacks support for LOCAL_ADDITIONAL_DEPENDENCIES
- ALL_DEFAULT_INSTALLED_MODULES += $(SYMLINKS)
- ALL_MODULES.$(LOCAL_MODULE).INSTALLED := \
- $(ALL_MODULES.$(LOCAL_MODULE).INSTALLED) $(SYMLINKS)
-endif
-
SYMLINKS :=
ALL_TOOLS :=
BSD_TOOLS :=