-LOCAL_CFLAGS += \
- -Os \
- -Wno-char-subscripts \
- -Wno-sign-compare \
- -Wno-uninitialized \
- -Wno-unused-parameter \
- -funsigned-char -ffunction-sections -fdata-sections -fno-asynchronous-unwind-tables \
+LOCAL_CFLAGS := $(common_cflags)
+LOCAL_CLANG := true
+
+# This doesn't actually prevent us from dragging in libc++ at runtime
+# because libnetd_client.so is C++.
+LOCAL_CXX_STL := none
+
+LOCAL_C_INCLUDES += bionic/libc/dns/include
+
+LOCAL_MODULE := libtoybox
+
+include $(BUILD_STATIC_LIBRARY)
+
+
+# Host binary to enumerate the toys
+include $(CLEAR_VARS)
+LOCAL_SRC_FILES := scripts/install.c
+LOCAL_MODULE_TAGS := optional
+LOCAL_CFLAGS := $(common_cflags)
+LOCAL_CLANG := true
+LOCAL_MODULE := toybox-instlist
+include $(BUILD_HOST_EXECUTABLE)