Do not run qemu static register automatically
This commit is contained in:
parent
333f37e554
commit
8a0ed4f787
2 changed files with 10 additions and 4 deletions
7
Makefile
7
Makefile
|
@ -115,8 +115,6 @@ ifeq ($(ARCH),amd64)
|
||||||
$(SED_I) "/CROSS_BUILD_/d" $(DOCKERFILE)
|
$(SED_I) "/CROSS_BUILD_/d" $(DOCKERFILE)
|
||||||
else
|
else
|
||||||
# When cross-building, only the placeholder "CROSS_BUILD_" should be removed
|
# When cross-building, only the placeholder "CROSS_BUILD_" should be removed
|
||||||
# Register /usr/bin/qemu-ARCH-static as the handler for ARM binaries in the kernel
|
|
||||||
$(DOCKER) run --rm --privileged multiarch/qemu-user-static:register --reset
|
|
||||||
curl -sSL https://github.com/multiarch/qemu-user-static/releases/download/$(QEMUVERSION)/x86_64_qemu-$(QEMUARCH)-static.tar.gz | tar -xz -C $(TEMP_DIR)/rootfs
|
curl -sSL https://github.com/multiarch/qemu-user-static/releases/download/$(QEMUVERSION)/x86_64_qemu-$(QEMUARCH)-static.tar.gz | tar -xz -C $(TEMP_DIR)/rootfs
|
||||||
$(SED_I) "s/CROSS_BUILD_//g" $(DOCKERFILE)
|
$(SED_I) "s/CROSS_BUILD_//g" $(DOCKERFILE)
|
||||||
endif
|
endif
|
||||||
|
@ -128,6 +126,11 @@ ifeq ($(ARCH), amd64)
|
||||||
$(DOCKER) tag $(MULTI_ARCH_IMG):$(TAG) $(IMAGE):$(TAG)
|
$(DOCKER) tag $(MULTI_ARCH_IMG):$(TAG) $(IMAGE):$(TAG)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
.PHONY: register-qemu
|
||||||
|
register-qemu:
|
||||||
|
# Register /usr/bin/qemu-ARCH-static as the handler for binaries in multiple platforms
|
||||||
|
$(DOCKER) run --rm --privileged multiarch/qemu-user-static:register --reset
|
||||||
|
|
||||||
.PHONY: push
|
.PHONY: push
|
||||||
push: .push-$(ARCH)
|
push: .push-$(ARCH)
|
||||||
|
|
||||||
|
|
|
@ -76,8 +76,6 @@ ifeq ($(ARCH),amd64)
|
||||||
cd $(TEMP_DIR) && $(SED_I) "/CROSS_BUILD_/d" Dockerfile
|
cd $(TEMP_DIR) && $(SED_I) "/CROSS_BUILD_/d" Dockerfile
|
||||||
else
|
else
|
||||||
# When cross-building, only the placeholder "CROSS_BUILD_" should be removed
|
# When cross-building, only the placeholder "CROSS_BUILD_" should be removed
|
||||||
# Register /usr/bin/qemu-ARCH-static as the handler for ARM binaries in the kernel
|
|
||||||
$(DOCKER) run --rm --privileged multiarch/qemu-user-static:register --reset
|
|
||||||
curl -sSL https://github.com/multiarch/qemu-user-static/releases/download/$(QEMUVERSION)/x86_64_qemu-$(QEMUARCH)-static.tar.gz | tar -xz -C $(TEMP_DIR)
|
curl -sSL https://github.com/multiarch/qemu-user-static/releases/download/$(QEMUVERSION)/x86_64_qemu-$(QEMUARCH)-static.tar.gz | tar -xz -C $(TEMP_DIR)
|
||||||
cd $(TEMP_DIR) && $(SED_I) "s/CROSS_BUILD_//g" Dockerfile
|
cd $(TEMP_DIR) && $(SED_I) "s/CROSS_BUILD_//g" Dockerfile
|
||||||
endif
|
endif
|
||||||
|
@ -89,6 +87,11 @@ ifeq ($(ARCH), amd64)
|
||||||
$(DOCKER) tag $(MULTI_ARCH_IMG):$(TAG) $(IMAGE):$(TAG)
|
$(DOCKER) tag $(MULTI_ARCH_IMG):$(TAG) $(IMAGE):$(TAG)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
.PHONY: register-qemu
|
||||||
|
register-qemu:
|
||||||
|
# Register /usr/bin/qemu-ARCH-static as the handler for binaries in multiple platforms
|
||||||
|
$(DOCKER) run --rm --privileged multiarch/qemu-user-static:register --reset
|
||||||
|
|
||||||
push: .push-$(ARCH)
|
push: .push-$(ARCH)
|
||||||
.push-$(ARCH): .container-$(ARCH)
|
.push-$(ARCH): .container-$(ARCH)
|
||||||
$(DOCKER) push $(MULTI_ARCH_IMG):$(TAG)
|
$(DOCKER) push $(MULTI_ARCH_IMG):$(TAG)
|
||||||
|
|
Loading…
Reference in a new issue