blob: ddf5eebbac626600d0bedc3a7181268e9b74dc39 [file] [log] [blame]
Ping-Hao Wu9e231ee2017-11-09 20:29:34 -08001LOCAL_PATH := $(call my-dir)
2
3cvd_host_package_tar := $(HOST_OUT)/cvd-host_package.tar.gz
4
Greg Hartman257abd32017-12-20 22:16:24 -08005.PHONY: hosttar
6hosttar: $(cvd_host_package_tar)
7
8.PHONY: cf_local_image
9cf_local_image: bootimage cacheimage hosttar systemimage userdataimage vendorimage
10
Ping-Hao Wu9e231ee2017-11-09 20:29:34 -080011ifeq ($(HOST_OS),linux)
12CVD_TAR_FORMAT := --format=gnu
13endif
14
15# Build and store them on the build server.
16$(call dist-for-goals, dist_files, $(cvd_host_package_tar))
17
18bin_path := $(notdir $(HOST_OUT_EXECUTABLES))
19lib_path := $(notdir $(HOST_OUT_SHARED_LIBRARIES))
20tests_path := $(notdir $(HOST_OUT_NATIVE_TESTS))
21
22cvd_host_executables := \
Greg Hartman004fb182018-05-02 18:48:53 -070023 host_region_e2e_test \
Greg Hartman6e78bf52017-11-11 12:03:39 -080024 launch_cvd \
Ryan Hainingb2cfce22018-02-05 08:58:19 -080025 socket_forward_proxy \
Jorge E. Moreira0aa61402018-04-25 18:18:43 -070026 stop_cvd \
Jorge E. Moreira20a6b1a2018-01-25 17:15:26 -080027 vnc_server \
Andreas Huberbd406582018-02-23 11:28:28 -080028 wifi_relay \
Andreas Huber5a6d7b72018-03-09 10:32:42 -080029 record_audio \
Jorge E. Moreiraa635a262018-06-13 14:51:10 -070030 cf_qemu.sh \
Ping-Hao Wu9e231ee2017-11-09 20:29:34 -080031
32cvd_host_tests := \
33 auto_free_buffer_test \
34 circqueue_test \
35 cuttlefish_thread_test \
36 hald_client_test \
37 lock_test \
38 monotonic_time_test \
39 vsoc_graphics_test \
40
41cvd_host_shared_libraries := \
Tomasz Wiszkowski0c8259e2017-12-06 09:47:02 -080042 libbase \
43 vsoc_lib \
44 libcuttlefish_fs \
45 cuttlefish_auto_resources \
Greg Hartmande0df452018-04-09 17:37:11 -070046 libcuttlefish_strings \
Jorge E. Moreira10910de2018-06-11 14:37:03 -070047 libcuttlefish_utils \
Jorge E. Moreiracf8d9882018-02-23 14:43:03 -080048 cuttlefish_tcp_socket \
Tomasz Wiszkowski0c8259e2017-12-06 09:47:02 -080049 liblog \
50 libnl \
Ping-Hao Wu9e231ee2017-11-09 20:29:34 -080051 libc++ \
52 libicuuc-host \
53
54cvd_host_configs := \
Greg Hartmanaf49e9b2018-02-02 16:40:53 -080055 cuttlefish.dtb
Ping-Hao Wu9e231ee2017-11-09 20:29:34 -080056
57cvd_host_packages := \
Greg Hartmanaf49e9b2018-02-02 16:40:53 -080058 cuttlefish_dtb \
Ping-Hao Wu9e231ee2017-11-09 20:29:34 -080059 $(cvd_host_executables) \
60 $(cvd_host_tests) \
61
62cvd_host_package_files := \
63 $(addprefix config/,$(cvd_host_configs)) \
64 $(addprefix $(bin_path)/,$(cvd_host_executables)) \
65 $(addprefix $(lib_path)/,$(addsuffix .so,$(cvd_host_shared_libraries))) \
66 $(foreach test,$(cvd_host_tests), ${tests_path}/$(test)/$(test)) \
67
68$(cvd_host_package_tar): $(cvd_host_packages)
69 $(hide) rm -rf $@ && tar Scfz $@.tmp -C $(HOST_OUT) $(CVD_TAR_FORMAT) $(cvd_host_package_files)
70 $(hide) mv $@.tmp $@