xf.li | f1aed28 | 2024-02-06 00:31:51 -0800 | [diff] [blame] | 1 | LOCAL_PATH:= $(call my-dir) |
| 2 | include $(CLEAR_VARS) |
| 3 | |
| 4 | LOCAL_SRC_FILES:=clatd.c dump.c checksum.c translate.c icmp.c ipv4.c ipv6.c config.c dns64.c logging.c getaddr.c netlink_callbacks.c netlink_msg.c setif.c mtu.c tun.c ring.c |
| 5 | |
| 6 | LOCAL_CFLAGS := -Wall -Werror -Wunused-parameter |
| 7 | # Bug: http://b/33566695 |
| 8 | LOCAL_CFLAGS += -Wno-address-of-packed-member |
| 9 | LOCAL_C_INCLUDES := external/libnl/include bionic/libc/dns/include system/netd/include |
| 10 | LOCAL_STATIC_LIBRARIES := libnl |
| 11 | LOCAL_SHARED_LIBRARIES := libcutils liblog libnetutils |
| 12 | |
| 13 | # The clat daemon. |
| 14 | LOCAL_MODULE := clatd |
| 15 | |
| 16 | include $(BUILD_EXECUTABLE) |
| 17 | |
| 18 | |
| 19 | # The configuration file. |
| 20 | include $(CLEAR_VARS) |
| 21 | |
| 22 | LOCAL_MODULE := clatd.conf |
| 23 | LOCAL_MODULE_CLASS := ETC |
| 24 | LOCAL_MODULE_PATH := $(TARGET_OUT)/etc |
| 25 | LOCAL_SRC_FILES := $(LOCAL_MODULE) |
| 26 | |
| 27 | include $(BUILD_PREBUILT) |
| 28 | |
| 29 | |
| 30 | # Unit tests. |
| 31 | include $(CLEAR_VARS) |
| 32 | |
| 33 | LOCAL_MODULE := clatd_test |
| 34 | LOCAL_CFLAGS := -Wall -Werror -Wunused-parameter |
| 35 | # Bug: http://b/33566695 |
| 36 | LOCAL_CFLAGS += -Wno-address-of-packed-member |
| 37 | LOCAL_SRC_FILES := clatd_test.cpp checksum.c translate.c icmp.c ipv4.c ipv6.c logging.c config.c tun.c |
| 38 | LOCAL_MODULE_TAGS := eng tests |
| 39 | LOCAL_SHARED_LIBRARIES := liblog libnetutils |
| 40 | |
| 41 | include $(BUILD_NATIVE_TEST) |
| 42 | |
| 43 | # Microbenchmark. |
| 44 | include $(CLEAR_VARS) |
| 45 | |
| 46 | LOCAL_CLANG := true |
| 47 | LOCAL_MODULE := clatd_microbenchmark |
| 48 | LOCAL_CFLAGS := -Wall -Werror -Wunused-parameter |
| 49 | LOCAL_SRC_FILES := clatd_microbenchmark.c checksum.c tun.c |
| 50 | LOCAL_MODULE_TAGS := eng tests |
| 51 | |
| 52 | include $(BUILD_NATIVE_TEST) |