mirror of
				https://github.com/kata-containers/kata-containers.git
				synced 2025-11-04 03:29:55 +00:00 
			
		
		
		
	kata-deploy: Add Makefile
Add makefile to document possible options to run. e.g Default: Create a kata tarball, it will build assets concurrently. ``` $ make ``` Create a tarball build for cloud-hypervisor. ``` $ make cloud-hypervisor ``` Signed-off-by: Carlos Venegas <jos.c.venegas.munoz@intel.com>
This commit is contained in:
		
							
								
								
									
										8
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										8
									
								
								Makefile
									
									
									
									
									
								
							@@ -33,4 +33,10 @@ generate-protocols:
 | 
			
		||||
static-checks: build
 | 
			
		||||
	bash ci/static-checks.sh
 | 
			
		||||
 | 
			
		||||
.PHONY: all default static-checks
 | 
			
		||||
binary-tarball:
 | 
			
		||||
	make -f ./tools/packaging/kata-deploy/local-build/Makefile
 | 
			
		||||
 | 
			
		||||
install-binary-tarball:
 | 
			
		||||
	make -f ./tools/packaging/kata-deploy/local-build/Makefile install
 | 
			
		||||
 | 
			
		||||
.PHONY: all default static-checks binary-tarball install-binary-tarball
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										53
									
								
								tools/packaging/kata-deploy/local-build/Makefile
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										53
									
								
								tools/packaging/kata-deploy/local-build/Makefile
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,53 @@
 | 
			
		||||
# Copyright (c) 2021 Intel Corporation
 | 
			
		||||
#
 | 
			
		||||
# SPDX-License-Identifier: Apache-2.0
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
MK_PATH := $(abspath $(lastword $(MAKEFILE_LIST)))
 | 
			
		||||
MK_DIR := $(dir $(MK_PATH))
 | 
			
		||||
 | 
			
		||||
# Verbose build
 | 
			
		||||
V ?=
 | 
			
		||||
ifneq ($(V),)
 | 
			
		||||
SILENT_BUILD_FLAG =
 | 
			
		||||
else
 | 
			
		||||
SILENT_BUILD_FLAG = -s
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
define BUILD
 | 
			
		||||
	$(MK_DIR)/kata-deploy-binaries-in-docker.sh $(SILENT_BUILD_FLAG) --build=$1
 | 
			
		||||
endef
 | 
			
		||||
 | 
			
		||||
kata-tarball: | all-parallel merge-builds
 | 
			
		||||
 | 
			
		||||
all-parallel:
 | 
			
		||||
	make -f $(MK_PATH) all -j$$(( $$(nproc) - 1  )) NO_TTY="true"
 | 
			
		||||
 | 
			
		||||
all: cloud-hypervisor firecracker kernel qemu rootfs-image rootfs-initrd shim-v2
 | 
			
		||||
 | 
			
		||||
cloud-hypervisor:
 | 
			
		||||
	$(call BUILD,$@)
 | 
			
		||||
 | 
			
		||||
firecracker:
 | 
			
		||||
	$(call BUILD,$@)
 | 
			
		||||
 | 
			
		||||
kernel:
 | 
			
		||||
	$(call BUILD,$@)
 | 
			
		||||
 | 
			
		||||
qemu:
 | 
			
		||||
	$(call BUILD,$@)
 | 
			
		||||
 | 
			
		||||
rootfs-image:
 | 
			
		||||
	$(call BUILD,$@)
 | 
			
		||||
 | 
			
		||||
rootfs-initrd:
 | 
			
		||||
	$(call BUILD,$@)
 | 
			
		||||
 | 
			
		||||
shim-v2:
 | 
			
		||||
	$(call BUILD,$@)
 | 
			
		||||
 | 
			
		||||
merge-builds:
 | 
			
		||||
	$(MK_DIR)/kata-deploy-merge-builds.sh build
 | 
			
		||||
 | 
			
		||||
install:
 | 
			
		||||
	tar -xvf ./kata-static.tar.xz -C /
 | 
			
		||||
		Reference in New Issue
	
	Block a user