diff options
| author | Kenny Root <kroot@google.com> | 2012-10-16 18:00:29 -0700 |
|---|---|---|
| committer | Kenny Root <kroot@google.com> | 2012-10-16 18:00:29 -0700 |
| commit | efb5e3c709214cfc45beec5fcc66c93223ffc744 (patch) | |
| tree | b237c6f2209f0cc61a333c3fc2b853ef78bbd200 | |
| parent | 55d039efb5d30377e2a66d931a7408b13ac24650 (diff) | |
| parent | 20f5daa8653eb2d81af8c161a2084e3b53ec3914 (diff) | |
| download | system_core-efb5e3c709214cfc45beec5fcc66c93223ffc744.zip system_core-efb5e3c709214cfc45beec5fcc66c93223ffc744.tar.gz system_core-efb5e3c709214cfc45beec5fcc66c93223ffc744.tar.bz2 | |
resolved conflicts for merge of 20f5daa8 to master
Change-Id: Ie3e67696d265a56dfa4d089c777506f27783a9a6
| -rw-r--r-- | fastboot/Android.mk | 2 | ||||
| -rw-r--r-- | toolbox/Android.mk | 23 | ||||
| -rw-r--r-- | toolbox/id.c | 7 | ||||
| -rw-r--r-- | toolbox/ls.c | 6 |
4 files changed, 6 insertions, 32 deletions
diff --git a/fastboot/Android.mk b/fastboot/Android.mk index 5e0e172..1189e1f 100644 --- a/fastboot/Android.mk +++ b/fastboot/Android.mk @@ -58,9 +58,7 @@ LOCAL_STATIC_LIBRARIES := \ libz ifneq ($(HOST_OS),windows) -ifeq ($(HAVE_SELINUX), true) LOCAL_STATIC_LIBRARIES += libselinux -endif # HAVE_SELINUX endif # HOST_OS != windows include $(BUILD_HOST_EXECUTABLE) diff --git a/toolbox/Android.mk b/toolbox/Android.mk index b027787..2ecb626 100644 --- a/toolbox/Android.mk +++ b/toolbox/Android.mk @@ -58,11 +58,7 @@ TOOLS := \ lsof \ du \ md5 \ - clear - -ifeq ($(HAVE_SELINUX),true) - -TOOLS += \ + clear \ getenforce \ setenforce \ chcon \ @@ -72,9 +68,6 @@ TOOLS += \ setsebool \ load_policy -endif - - ifneq (,$(filter userdebug eng,$(TARGET_BUILD_VARIANT))) TOOLS += r endif @@ -91,17 +84,13 @@ LOCAL_SRC_FILES := \ cp/cp.c cp/utils.c \ grep/grep.c grep/fastgrep.c grep/file.c grep/queue.c grep/util.c -LOCAL_SHARED_LIBRARIES := libcutils libc libusbhost - LOCAL_C_INCLUDES := bionic/libc/bionic -ifeq ($(HAVE_SELINUX),true) - -LOCAL_CFLAGS += -DHAVE_SELINUX -LOCAL_SHARED_LIBRARIES += libselinux -LOCAL_C_INCLUDES += external/libselinux/include - -endif +LOCAL_SHARED_LIBRARIES := \ + libcutils \ + libc \ + libusbhost \ + libselinux LOCAL_MODULE := toolbox diff --git a/toolbox/id.c b/toolbox/id.c index bc79288..8ec79c1 100644 --- a/toolbox/id.c +++ b/toolbox/id.c @@ -4,10 +4,7 @@ #include <sys/types.h> #include <pwd.h> #include <grp.h> - -#ifdef HAVE_SELINUX #include <selinux/selinux.h> -#endif static void print_uid(uid_t uid) { @@ -34,9 +31,7 @@ int id_main(int argc, char **argv) { gid_t list[64]; int n, max; -#ifdef HAVE_SELINUX char *secctx; -#endif max = getgroups(64, list); if (max < 0) max = 0; @@ -53,12 +48,10 @@ int id_main(int argc, char **argv) print_gid(list[n]); } } -#ifdef HAVE_SELINUX if (getcon(&secctx) == 0) { printf(" context=%s", secctx); free(secctx); } -#endif printf("\n"); return 0; } diff --git a/toolbox/ls.c b/toolbox/ls.c index b7ba1b7..e530521 100644 --- a/toolbox/ls.c +++ b/toolbox/ls.c @@ -5,9 +5,7 @@ #include <dirent.h> #include <errno.h> -#ifdef HAVE_SELINUX #include <selinux/selinux.h> -#endif #include <sys/stat.h> #include <unistd.h> @@ -260,11 +258,7 @@ static int listfile_maclabel(const char *path, int flags) return -1; } -#ifdef HAVE_SELINUX lgetfilecon(path, &maclabel); -#else - maclabel = strdup("-"); -#endif if (!maclabel) { return -1; } |
