From c6595bee54b1a87d737e5e4849079028b9b71ee6 Mon Sep 17 00:00:00 2001 From: "Xinwei Xiong(cubxxw-openim)" <3293172751nss@gmail.com> Date: Sat, 10 Jun 2023 09:07:20 +0800 Subject: [PATCH] feat: make multiarch --- Makefile | 5 +++++ script/make-rules/common.mk | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 92db8aed0..b047ae370 100644 --- a/Makefile +++ b/Makefile @@ -60,6 +60,11 @@ export USAGE_OPTIONS build: @$(MAKE) go.build +## multiarch: Build binaries for multiple platforms. See option PLATFORMS. +.PHONY: build-multiarch +build-multiarch: + @$(MAKE) go.build.multiarch + ## tidy: tidy go.mod .PHONY: tidy tidy: diff --git a/script/make-rules/common.mk b/script/make-rules/common.mk index c73c5cacf..e79102d89 100644 --- a/script/make-rules/common.mk +++ b/script/make-rules/common.mk @@ -150,8 +150,8 @@ define MAKEFILE_EXAMPLE # make linux.arm64 imctl is compiled on arm64 platform. # make verify-copyright Verify the license headers for all files. # make install-deepcopy-gen Install deepcopy-gen tools if the license is missing. -# make build BINS=imctl V=1 DEBUG=1 Build debug binaries for only imctl. -# make multiarch PLATFORMS="linux_arm64 linux_amd64" V=1 Build binaries for both platforms. +# make build BINS=imctl V=1 DEBUG=1 Build debug binaries for only imctl. +# make multiarch PLATFORMS="linux_arm64 linux_amd64" V=1 Build binaries for both platforms. endef export MAKEFILE_EXAMPLE