From 4eda982a77a7a812fcd6b97ebb858d4c0a4cf802 Mon Sep 17 00:00:00 2001 From: Colin Cross Date: Tue, 18 Apr 2017 17:42:10 -0700 Subject: [PATCH 1/2] Don't export libutils_headers from libbase libutils headers are only used by the implementation of libbase, and should not be exported to everything that uses libbase headers. Test: m -j Change-Id: I76f248908f649e3a3c91cd3e84d629a0049939ef --- base/Android.bp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/base/Android.bp b/base/Android.bp index afb7dd363..81b96db43 100644 --- a/base/Android.bp +++ b/base/Android.bp @@ -26,9 +26,6 @@ cc_library_headers { host_supported: true, export_include_dirs: ["include"], - header_libs: ["libutils_headers"], - export_header_lib_headers: ["libutils_headers"], - target: { linux_bionic: { enabled: true, @@ -54,7 +51,10 @@ cc_library { "test_utils.cpp", ], - header_libs: ["libbase_headers"], + header_libs: [ + "libbase_headers", + "libutils_headers", + ], export_header_lib_headers: ["libbase_headers"], cppflags: libbase_cppflags, From cafe889aa8ba4d77caec15620e9fbc1dbc995e58 Mon Sep 17 00:00:00 2001 From: Colin Cross Date: Wed, 19 Apr 2017 16:46:46 -0700 Subject: [PATCH 2/2] Convert libnetutils to Android.bp See build/soong/README.md for more information. Test: m -j checkbuild Change-Id: Ia11dffde6fc4d89be6ee651be06b48131c877dc0 --- libnetutils/Android.bp | 19 +++++++++++++++++++ libnetutils/Android.mk | 21 --------------------- 2 files changed, 19 insertions(+), 21 deletions(-) create mode 100644 libnetutils/Android.bp delete mode 100644 libnetutils/Android.mk diff --git a/libnetutils/Android.bp b/libnetutils/Android.bp new file mode 100644 index 000000000..f710ba29e --- /dev/null +++ b/libnetutils/Android.bp @@ -0,0 +1,19 @@ +cc_library_shared { + name: "libnetutils", + + srcs: [ + "dhcpclient.c", + "dhcpmsg.c", + "ifc_utils.c", + "packet.c", + ], + + shared_libs: [ + "libcutils", + "liblog", + ], + + cflags: ["-Werror"], + + export_include_dirs: ["include"], +} diff --git a/libnetutils/Android.mk b/libnetutils/Android.mk deleted file mode 100644 index 215027988..000000000 --- a/libnetutils/Android.mk +++ /dev/null @@ -1,21 +0,0 @@ -LOCAL_PATH := $(call my-dir) -include $(CLEAR_VARS) - -LOCAL_SRC_FILES := \ - dhcpclient.c \ - dhcpmsg.c \ - ifc_utils.c \ - packet.c - -LOCAL_SHARED_LIBRARIES := \ - libcutils \ - liblog - -LOCAL_MODULE := libnetutils - -LOCAL_CFLAGS := -Werror - -LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include -LOCAL_C_INCLUDES := $(LOCAL_PATH)/include - -include $(BUILD_SHARED_LIBRARY)