summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJhon Honce <jhonce@redhat.com>2019-09-11 14:35:18 -0700
committerJhon Honce <jhonce@redhat.com>2019-09-11 16:15:52 -0700
commitecb958e59851186630e946d7973d91f8d524ea17 (patch)
treebc476050109b042906b08b9bdb909fc26bee061d /Makefile
parent79ebb5f254d6f3498500f823cf1b856fed2e6149 (diff)
downloadpodman-ecb958e59851186630e946d7973d91f8d524ea17.tar.gz
podman-ecb958e59851186630e946d7973d91f8d524ea17.tar.bz2
podman-ecb958e59851186630e946d7973d91f8d524ea17.zip
Support building Windows msi file
* Update Makefile to build msi * Add podman.wxs to define podman.msi * Version information provided by Makefile * Add podman.bat wrapper for podman-remote-windows.exe to ensure environment * Add wix xml schemas for reference Signed-off-by: Jhon Honce <jhonce@redhat.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 840bfced7..b4f8020f2 100644
--- a/Makefile
+++ b/Makefile
@@ -84,6 +84,7 @@ GINKGOTIMEOUT ?= -timeout=90m
RELEASE_VERSION ?= $(shell hack/get_release_info.sh VERSION)
RELEASE_NUMBER ?= $(shell hack/get_release_info.sh NUMBER)
+RELEASE_NUMERIC = $(shell echo $(RELEASE_NUMBER) |sed -e 's/^v\(.*\)/\1/')
RELEASE_DIST ?= $(shell hack/get_release_info.sh DIST)
RELEASE_DIST_VER ?= $(shell hack/get_release_info.sh DIST_VER)
RELEASE_ARCH ?= $(shell hack/get_release_info.sh ARCH)
@@ -164,6 +165,10 @@ podman: .gopathok $(PODMAN_VARLINK_DEPENDENCIES) ## Build with podman
podman-remote: .gopathok $(PODMAN_VARLINK_DEPENDENCIES) ## Build with podman on remote environment
$(GO_BUILD) $(BUILDFLAGS) -gcflags '$(GCFLAGS)' -asmflags '$(ASMFLAGS)' -ldflags '$(LDFLAGS_PODMAN)' -tags "$(BUILDTAGS) remoteclient" -o bin/$@ $(PROJECT)/cmd/podman
+.PHONY: podman.msi
+podman.msi: podman-remote-windows ## Will always rebuild exe as there is no podman-remote-windows.exe target to verify timestamp
+ wixl -D VERSION=$(RELEASE_NUMERIC) -o bin/podman-$(RELEASE_NUMBER).msi contrib/msi/podman.wxs
+
podman-remote-%: .gopathok $(PODMAN_VARLINK_DEPENDENCIES) ## Build podman for a specific GOOS
$(eval BINSFX := $(shell test "$*" != "windows" || echo ".exe"))
CGO_ENABLED=0 GOOS=$* $(GO_BUILD) -gcflags '$(GCFLAGS)' -asmflags '$(ASMFLAGS)' -ldflags '$(LDFLAGS_PODMAN)' -tags "remoteclient containers_image_openpgp exclude_graphdriver_devicemapper" -o bin/$@$(BINSFX) $(PROJECT)/cmd/podman