OSDN Git Service

Stop building getprop
authorTom Cherry <tomcherry@google.com>
Thu, 4 Jan 2018 18:13:59 +0000 (10:13 -0800)
committerTom Cherry <tomcherry@google.com>
Thu, 4 Jan 2018 18:14:59 +0000 (10:14 -0800)
We've replaced this with our own C++ version to support the new
property info parsing.

Bug: 36001741
Test: Compared getprop results with toybox getprop
Change-Id: Iba71544e0d8eb2c0d683fdd244fa7ccb87294de4

.config
Android.mk
generated/config.h
generated/flags.h

diff --git a/.config b/.config
index 868534e..92ea2cc 100644 (file)
--- a/.config
+++ b/.config
@@ -116,7 +116,7 @@ CONFIG_FSFREEZE=y
 # CONFIG_FTPPUT is not set
 CONFIG_GETENFORCE=y
 CONFIG_GETFATTR=y
-CONFIG_GETPROP=y
+# CONFIG_GETPROP is not set
 # CONFIG_GETTY is not set
 CONFIG_GREP=y
 # CONFIG_GROUPADD is not set
index ac05206..f6f49e1 100644 (file)
@@ -66,7 +66,6 @@ common_SRC_FILES := \
     lib/xwrap.c \
     main.c \
     toys/android/getenforce.c \
-    toys/android/getprop.c \
     toys/android/load_policy.c \
     toys/android/log.c \
     toys/android/restorecon.c \
@@ -282,7 +281,6 @@ ALL_TOOLS := \
     flock \
     free \
     getenforce \
-    getprop \
     groups \
     gunzip \
     gzip \
index 593ca7b..d5472e2 100644 (file)
 #define USE_GETENFORCE(...) __VA_ARGS__
 #define CFG_GETFATTR 1
 #define USE_GETFATTR(...) __VA_ARGS__
-#define CFG_GETPROP 1
-#define USE_GETPROP(...) __VA_ARGS__
+#define CFG_GETPROP 0
+#define USE_GETPROP(...)
 #define CFG_GETTY 0
 #define USE_GETTY(...)
 #define CFG_GREP 1
index d9dcedc..f77c67b 100644 (file)
 #undef FLAG_d
 #endif
 
-// getprop >2Z >2Z
+// getprop   >2Z
 #undef OPTSTR_getprop
 #define OPTSTR_getprop ">2Z"
 #ifdef CLEANUP_getprop
 #ifndef TT
 #define TT this.getprop
 #endif
-#define FLAG_Z (1<<0)
+#define FLAG_Z (FORCED_FLAG<<0)
 #endif
 
 #ifdef FOR_getty