Support for configurable localversion

Adds a new --localversion option to configure.
The value of localversion becomes part of the Zeek version string.
Docker builds allow an environment variable (LOCALVERSION) to set
the localversion string.
This commit is contained in:
Peter Cullen 2024-04-03 19:16:12 +00:00 committed by Christian Kreibich
parent 1563814c4a
commit d57679e3dd
5 changed files with 21 additions and 3 deletions

View file

@ -1,6 +1,12 @@
# See the file "COPYING" in the main distribution directory for copyright.
VERSION := $(shell cat ../VERSION)
LOCALVERSION ?= ""
LOCAL_VERSION_FLAG = ""
ifneq ($(LOCALVERSION), "")
VERSION := $(VERSION)-$(LOCALVERSION)
LOCAL_VERSION_FLAG := "--localversion=$(LOCALVERSION)"
endif
BUILD_IMAGE := zeek-builder:$(VERSION)
BUILD_CONTAINER := zeek-builder-container-$(VERSION)
ZEEK_IMAGE ?= zeek:$(VERSION)
@ -11,7 +17,7 @@ ZEEK_CONFIGURE_FLAGS ?= \
--build-type=Release \
--disable-btest-pcaps \
--disable-broker-tests \
--disable-cpp-tests
--disable-cpp-tests $(LOCAL_VERSION_FLAG)
.PHONY: all