summaryrefslogtreecommitdiffstats
path: root/pigz
diff options
context:
space:
mode:
authorMatt Mower <mowerm@gmail.com>2016-08-24 09:11:32 +0200
committerMatt Mower <mowerm@gmail.com>2017-01-18 20:04:35 +0100
commitc55b9a78936d1874d780501416209db6b95d2a33 (patch)
treeb6a32fefa76a3635de5812c7803ff7ee4daaba05 /pigz
parentAdd missing license headers (diff)
downloadandroid_bootable_recovery-c55b9a78936d1874d780501416209db6b95d2a33.tar
android_bootable_recovery-c55b9a78936d1874d780501416209db6b95d2a33.tar.gz
android_bootable_recovery-c55b9a78936d1874d780501416209db6b95d2a33.tar.bz2
android_bootable_recovery-c55b9a78936d1874d780501416209db6b95d2a33.tar.lz
android_bootable_recovery-c55b9a78936d1874d780501416209db6b95d2a33.tar.xz
android_bootable_recovery-c55b9a78936d1874d780501416209db6b95d2a33.tar.zst
android_bootable_recovery-c55b9a78936d1874d780501416209db6b95d2a33.zip
Diffstat (limited to 'pigz')
-rw-r--r--pigz/Android.mk31
1 files changed, 6 insertions, 25 deletions
diff --git a/pigz/Android.mk b/pigz/Android.mk
index 9fff2f95c..89f9635d7 100644
--- a/pigz/Android.mk
+++ b/pigz/Android.mk
@@ -12,29 +12,10 @@ LOCAL_C_INCLUDES += $(LOCAL_PATH) \
external/zlib
LOCAL_SHARED_LIBRARIES += libz libc
-include $(BUILD_EXECUTABLE)
-
-PIGZ_TOOLS := unpigz
-SYMLINKS := $(addprefix $(TARGET_RECOVERY_ROOT_OUT)/sbin/,$(PIGZ_TOOLS))
-$(SYMLINKS): PIGZ_BINARY := $(LOCAL_MODULE)
-$(SYMLINKS): $(LOCAL_INSTALLED_MODULE)
- @echo "Symlink: $@ -> $(PIGZ_BINARY)"
- @mkdir -p $(dir $@)
- @rm -rf $@
- $(hide) ln -sf $(PIGZ_BINARY) $@
-
-ifneq (,$(filter $(PLATFORM_SDK_VERSION),16 17 18))
-ALL_DEFAULT_INSTALLED_MODULES += $(SYMLINKS)
+LOCAL_POST_INSTALL_CMD := \
+ $(hide) mkdir -p $(TARGET_RECOVERY_ROOT_OUT)/sbin && \
+ ln -sf pigz $(TARGET_RECOVERY_ROOT_OUT)/sbin/gunzip && \
+ ln -sf pigz $(TARGET_RECOVERY_ROOT_OUT)/sbin/gzip && \
+ ln -sf pigz $(TARGET_RECOVERY_ROOT_OUT)/sbin/unpigz
-# We need this so that the installed files could be picked up based on the
-# local module name
-ALL_MODULES.$(LOCAL_MODULE).INSTALLED := \
- $(ALL_MODULES.$(LOCAL_MODULE).INSTALLED) $(SYMLINKS)
-endif
-
-include $(CLEAR_VARS)
-LOCAL_MODULE := unpigz_symlink
-LOCAL_MODULE_TAGS := optional
-LOCAL_ADDITIONAL_DEPENDENCIES := $(SYMLINKS)
-include $(BUILD_PHONY_PACKAGE)
-SYMLINKS :=
+include $(BUILD_EXECUTABLE)