diff --git a/Makefile b/Makefile index 61452f0f8746..53aad6d68daf 100644 --- a/Makefile +++ b/Makefile @@ -3,6 +3,7 @@ CARGO_PROFILE ?= FEATURES ?= TARGET_DIR ?= TARGET ?= +BUILD_BIN ?= greptime CARGO_BUILD_OPTS := --locked IMAGE_REGISTRY ?= docker.io IMAGE_NAMESPACE ?= greptime @@ -45,6 +46,10 @@ ifneq ($(strip $(TARGET)),) CARGO_BUILD_OPTS += --target ${TARGET} endif +ifneq ($(strip $(BUILD_BIN)),) + CARGO_BUILD_OPTS += --bin ${BUILD_BIN} +endif + ifneq ($(strip $(RELEASE)),) CARGO_BUILD_OPTS += --release endif