diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2019-02-18 12:54:43 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-18 12:54:43 +0100 |
commit | f2139a651706b10824a1641a360020d932798827 (patch) | |
tree | d626d873c041e7c3ddcab8f8f9384590081a7ba7 | |
parent | 3f32eae56fed23e93c45d7da53da33702e954a26 (diff) | |
parent | 383e573299e00b9c09e2c23cc5b11b5a3b6e75c5 (diff) | |
download | podman-f2139a651706b10824a1641a360020d932798827.tar.gz podman-f2139a651706b10824a1641a360020d932798827.tar.bz2 podman-f2139a651706b10824a1641a360020d932798827.zip |
Merge pull request #2359 from nitkon/master
packer: Make Makefile host arch sensitive
-rw-r--r-- | contrib/cirrus/packer/Makefile | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/contrib/cirrus/packer/Makefile b/contrib/cirrus/packer/Makefile index 0a783e979..91a1dfeef 100644 --- a/contrib/cirrus/packer/Makefile +++ b/contrib/cirrus/packer/Makefile @@ -4,7 +4,9 @@ # e.g for names see libpod_images.yml PACKER_VER ?= 1.3.2 -PACKER_DIST_FILENAME := packer_${PACKER_VER}_linux_amd64.zip +GOARCH=$(shell go env GOARCH) +ARCH=$(uname -m) +PACKER_DIST_FILENAME := packer_${PACKER_VER}_linux_${GOARCH}.zip # Only needed for libpod_base_images target TIMESTAMP := $(shell date +%s) @@ -30,7 +32,7 @@ ${PACKER_DIST_FILENAME}: packer: ${PACKER_DIST_FILENAME} @curl -L --silent --show-error \ https://releases.hashicorp.com/packer/${PACKER_VER}/packer_${PACKER_VER}_SHA256SUMS \ - | grep 'linux_amd64' > /tmp/packer_sha256sums + | grep linux_${GOARCH} > /tmp/packer_sha256sums @sha256sum --check /tmp/packer_sha256sums @unzip -o ${PACKER_DIST_FILENAME} @touch --reference=Makefile ${PACKER_DIST_FILENAME} @@ -93,7 +95,7 @@ endif -var GOSRC=$(GOSRC) \ -var PACKER_BASE=$(PACKER_BASE) \ -var SCRIPT_BASE=$(SCRIPT_BASE) \ - -var RHEL_BASE_IMAGE_NAME=$(shell basename $(RHEL_IMAGE_FILE) | tr -d '[[:space:]]' | sed -r -e 's/\.x86_64\.raw\.xz//' | tr '[[:upper:]]' '[[:lower:]]' | tr '[[:punct:]]' '-') \ + -var RHEL_BASE_IMAGE_NAME=$(shell basename $(RHEL_IMAGE_FILE) | tr -d '[[:space:]]' | sed -r -e 's/\.${ARCH}\.raw\.xz//' | tr '[[:upper:]]' '[[:lower:]]' | tr '[[:punct:]]' '-') \ -var RHEL_IMAGE_FILE=$(RHEL_IMAGE_FILE) \ -var RHEL_CSUM_FILE=$(RHEL_CSUM_FILE) \ -var 'RHSM_COMMAND=$(RHSM_COMMAND)' \ |