Skip to content

Commit 5d01132

Browse files
committed
static: remove target_platform and switch to xx
Signed-off-by: CrazyMax <[email protected]>
1 parent d5fbee5 commit 5d01132

File tree

5 files changed

+70
-200
lines changed

5 files changed

+70
-200
lines changed

Makefile

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,10 @@ src/github.com/docker/scan-cli-plugin:
5454
git init $@
5555
git -C $@ remote add origin "$(DOCKER_SCAN_REPO)"
5656

57+
src/github.com/tonistiigi/xx:
58+
$(call title,Init $(XX_REPO))
59+
git init $@
60+
git -C $@ remote add origin "$(XX_REPO)"
5761

5862
.PHONY: checkout-cli
5963
checkout-cli: src/github.com/docker/cli
@@ -83,6 +87,11 @@ checkout-scan-cli-plugin: src/github.com/docker/scan-cli-plugin
8387
.PHONY: checkout
8488
checkout: checkout-cli checkout-docker checkout-buildx checkout-compose checkout-scan-cli-plugin ## checkout source at the given reference(s)
8589

90+
.PHONY: checkout-xx
91+
checkout-xx: src/github.com/tonistiigi/xx
92+
$(call title,Checkout $(XX_REPO)#$(XX_REF))
93+
./scripts/checkout.sh src/github.com/tonistiigi/xx "$(XX_REF)"
94+
8695
.PHONY: clean
8796
clean: clean-src ## remove build artifacts
8897
$(MAKE) -C rpm clean
@@ -101,9 +110,8 @@ centos-% fedora-% rhel-%: checkout ## build rpm packages for the specified distr
101110
debian-% raspbian-% ubuntu-%: checkout ## build deb packages for the specified distro
102111
$(MAKE) -C deb $@
103112

104-
105113
.PHONY: static
106-
static: checkout ## build static package
114+
static: checkout checkout-xx ## build static package
107115
$(MAKE) -C static build
108116

109117
.PHONY: verify

common.mk

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@ DOCKER_SCAN_REF ?= v0.17.0
4343
DOCKER_COMPOSE_REF ?= v2.6.1
4444
DOCKER_BUILDX_REF ?= v0.8.2
4545

46+
# XX is used as cross-compilation helper for static bundles
47+
XX_REPO ?= https://github.com/tonistiigi/xx.git
48+
XX_REF ?= v1.1.1
49+
4650
# Use "stage" to install dependencies from download-stage.docker.com during the
4751
# verify step. Leave empty or use any other value to install from download.docker.com
4852
VERIFY_PACKAGE_REPO ?= staging

scripts/target-platform

Lines changed: 0 additions & 146 deletions
This file was deleted.

static/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ ENGINE_DIR=$(realpath $(CURDIR)/../src/github.com/docker/docker)
55
BUILDX_DIR=$(realpath $(CURDIR)/../src/github.com/docker/buildx)
66
COMPOSE_DIR=$(realpath $(CURDIR)/../src/github.com/docker/compose)
77
SCAN_DIR=$(realpath $(CURDIR)/../src/github.com/docker/scan-cli-plugin)
8+
XX_DIR=$(realpath $(CURDIR)/../src/github.com/tonistiigi/xx)
89

910
STATIC_VERSION=$(shell ./gen-static-ver $(CLI_DIR) $(VERSION))
1011
HASH_CMD=docker run -v $(CURDIR):/sum -w /sum debian:jessie bash hash_files
@@ -15,6 +16,7 @@ export ENGINE_DIR
1516
export BUILDX_DIR
1617
export COMPOSE_DIR
1718
export SCAN_DIR
19+
export XX_DIR
1820

1921
export STATIC_VERSION
2022

0 commit comments

Comments
 (0)