diff options
author | Dan Willemsen <dwillemsen@google.com> | 2018-06-18 21:55:38 -0700 |
---|---|---|
committer | Dan Willemsen <dwillemsen@google.com> | 2018-06-19 18:16:23 +0000 |
commit | 301c0efcee67601c9e2d29cf921b2d7c968271b5 (patch) | |
tree | 9bffbab01e7c8c0793adb4ba7eaa542013b3f2d9 | |
parent | 2bb7eb83310a844f7495773aac4413314d95fdc7 (diff) | |
download | cuttlefish-301c0efcee67601c9e2d29cf921b2d7c968271b5.tar.gz |
Fix hosttar generation not to depend on PHONY targetsandroid-p-preview-5android-p-preview-4android-o-mr1-iot-release-1.0.2
Instead of depending on the phony targets, which are never considered
clean (so the tar will always rebuild), and include all versions of a
particular module (host, target, etc), use the real files that we're
about to package.
Test: m hosttar
Test: cvd-host_package.tar.gz is the same before&after (except timestamps)
Change-Id: If5e28bfa33bc53e6d451ebd084ab69c2ba567034
Merged-In: If5e28bfa33bc53e6d451ebd084ab69c2ba567034
-rw-r--r-- | host_package.mk | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/host_package.mk b/host_package.mk index bcb6e64f7..ab1f79cd0 100644 --- a/host_package.mk +++ b/host_package.mk @@ -8,8 +8,9 @@ hosttar: $(cvd_host_package_tar) .PHONY: cf_local_image cf_local_image: bootimage cacheimage hosttar systemimage userdataimage vendorimage +$(cvd_host_package_tar): PRIVATE_TAR_FORMAT := ifeq ($(HOST_OS),linux) -CVD_TAR_FORMAT := --format=gnu +$(cvd_host_package_tar): PRIVATE_TAR_FORMAT := --format=gnu endif # Build and store them on the build server. @@ -45,17 +46,13 @@ cvd_host_shared_libraries := \ cvd_host_configs := \ vsoc_mem.json -cvd_host_packages := \ - vsoc_mem_json \ - $(cvd_host_executables) \ - $(cvd_host_tests) \ - cvd_host_package_files := \ $(addprefix config/,$(cvd_host_configs)) \ $(addprefix $(bin_path)/,$(cvd_host_executables)) \ $(addprefix $(lib_path)/,$(addsuffix .so,$(cvd_host_shared_libraries))) \ $(foreach test,$(cvd_host_tests), ${tests_path}/$(test)/$(test)) \ -$(cvd_host_package_tar): $(cvd_host_packages) - $(hide) rm -rf $@ && tar Scfz $@.tmp -C $(HOST_OUT) $(CVD_TAR_FORMAT) $(cvd_host_package_files) +$(cvd_host_package_tar): PRIVATE_FILES := $(cvd_host_package_files) +$(cvd_host_package_tar): $(addprefix $(HOST_OUT)/,$(cvd_host_package_files)) + $(hide) rm -rf $@ && tar Scfz $@.tmp -C $(HOST_OUT) $(PRIVATE_TAR_FORMAT) $(PRIVATE_FILES) $(hide) mv $@.tmp $@ |