docker-distribution: fix do package qa warning[ldflags]
PATCH 1/1 docker-distribution: fix do package qa warning[ldflags]
From: Changqing Li <[email protected]>
fix below warning:do_package_qa: QA Issue: No GNU_HASH in the elf binary:
xxx/usr/sbin/registry' [ldflags]
--- recipes-containers/docker-distribution/docker-distribution_git.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
recipes-containers/docker-distribution/docker-distribution_git.bb +1 -1
@@ -58,7 +58,7 @@ do_install() { } INSANE_SKIP_${PN} += "ldflags already-stripped" -INSANE_SKIP_docker-registry += "ldflags already-stripped" +INSANE_SKIP_${MLPREFIX}docker-registry += "ldflags already-stripped" FILES_docker-registry = "${sbindir}/*" FILES_docker-registry += "${systemd_unitdir}/system/docker-registry.service"
Signature · 1 line
2.7.4
PATCH 1/1 docker: fix package qa warning
From: Changqing Li <[email protected]>
fix below warning:do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' has relocations in .text [textrel]
--- recipes-containers/docker/docker_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 31 ++++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 recipes-containers/docker/files/0001-fix-do_package_qa-error.patch
recipes-containers/docker/docker_git.bb +1 -0
@@ -28,6 +28,7 @@ SRC_URI = "\ file://docker.init \ file://hi.Dockerfile \ file://0001-libnetwork-use-GO-instead-of-go.patch \ + file://0001-fix-do_package_qa-error.patch \ " # Apache-2.0 for docker
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +31 -0
@@ -0,0 +1,31 @@ +From 56c865e2a7269d63f0780b4cd1ed6fdb18e3ff1b Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Wed, 26 Sep 2018 17:41:59 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + cli/scripts/build/dynbinary | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/cli/scripts/build/dynbinary b/cli/scripts/build/dynbinary +index 3c32ed3..938e086 100755 +--- a/cli/scripts/build/dynbinary ++++ b/cli/scripts/build/dynbinary +@@ -9,6 +9,6 @@ source ./scripts/build/.variables + + echo "Building dynamically linked $TARGET" + export CGO_ENABLED=1 +-go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" "${SOURCE}" ++go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" -buildmode=pie "${SOURCE}" + + ln -sf "$(basename "${TARGET}")" build/docker +-- +2.7.4 +
Signature · 1 line
2.7.4
Re: [PATCH] docker: fix package qa warning
Quoted 48 lines · On Sat, Sep 29, 2018 at 11:18 PM <[email protected]> wrote:
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' has relocations in .text [textrel]Signed-off-by Changqing Li <[email protected]>--- recipes-containers/docker/docker_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 31 ++++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 recipes-containers/docker/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker/docker_git.bb +1
-0@@ -28,6 +28,7 @@ SRC_URI = "\ file://docker.init \ file://hi.Dockerfile \ file://0001-libnetwork-use-GO-instead-of-go.patch \ + file://0001-fix-do_package_qa-error.patch \ " # Apache-2.0 for dockerrecipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +16
-0@@ -0,0 +1,31 @@ +From 56c865e2a7269d63f0780b4cd1ed6fdb18e3ff1b Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Wed, 26 Sep 2018 17:41:59 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + cli/scripts/build/dynbinary | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) +
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch line 26
Quoted 10 lines
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +10
-0+diff --git a/cli/scripts/build/dynbinary b/cli/scripts/build/dynbinary +index 3c32ed3..938e086 100755 +--- a/cli/scripts/build/dynbinary ++++ b/cli/scripts/build/dynbinary +@@ -9,6 +9,6 @@ source ./scripts/build/.variables + + echo "Building dynamically linked $TARGET" + export CGO_ENABLED=1 +-go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" "${SOURCE}" ++go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" -buildmode=pie "${SOURCE}"
As I mentioned in my other replies, I've never seen these warnings myself. So I need to understand the configuration better.
Since I've never seen this before, my first reaction is that any change of the flags to include buildmode=pie needs to be conditional on some other distro feature that is enabled in your configuration.
Bruce
Quoted 13 lines
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +5
-1+ + ln -sf "$(basename "${TARGET}")" build/docker +-- +2.7.4 + --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 2 lines
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"
Re: [PATCH] docker: fix package qa warning
Quoted 63 lines · Bruce Ashfield
Quoted 48 lines · On Sat, Sep 29, 2018 at 11:18 PM <[email protected]> wrote:
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' has relocations in .text [textrel]Signed-off-by Changqing Li <[email protected]>--- recipes-containers/docker/docker_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 31 ++++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 recipes-containers/docker/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker/docker_git.bb +1
-0@@ -28,6 +28,7 @@ SRC_URI = "\ file://docker.init \ file://hi.Dockerfile \ file://0001-libnetwork-use-GO-instead-of-go.patch \ + file://0001-fix-do_package_qa-error.patch \ " # Apache-2.0 for dockerrecipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +16
-0@@ -0,0 +1,31 @@ +From 56c865e2a7269d63f0780b4cd1ed6fdb18e3ff1b Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Wed, 26 Sep 2018 17:41:59 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + cli/scripts/build/dynbinary | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) +recipes-containers/docker/files/0001-fix-do_package_qa-error.patch line 26
Quoted 10 lines
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +10
-0+diff --git a/cli/scripts/build/dynbinary b/cli/scripts/build/dynbinary +index 3c32ed3..938e086 100755 +--- a/cli/scripts/build/dynbinary ++++ b/cli/scripts/build/dynbinary +@@ -9,6 +9,6 @@ source ./scripts/build/.variables + + echo "Building dynamically linked $TARGET" + export CGO_ENABLED=1 +-go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" "${SOURCE}" ++go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" -buildmode=pie "${SOURCE}"As I mentioned in my other replies, I've never seen these warnings myself. So I need to understand the configuration better.
Quoted 3 lines
Since I've never seen this before, my first reaction is that any change of the flags to include buildmode=pie needs to be conditional on some other distro feature that is enabled in your configuration.
Most likely the security flags at play. Could also be that you don't have the check enabled. At any rate I agree the details need to be captured in the commit log.
MarkA
Quoted 27 lines
Bruce
Quoted 8 lines
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +5
-1+ + ln -sf "$(basename "${TARGET}")" build/docker +-- +2.7.4 + --2.7.4
Quoted 5 lines
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization--
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"
--
_______________________________________________
meta-virtualization mailing list [email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Re: [PATCH] docker: fix package qa warning
Quoted 63 lines · M. Asselstine
Quoted 61 lines · Bruce Ashfield
Quoted 47 lines · On Sat, Sep 29, 2018 at 11:18 PM <[email protected]> wrote:
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' has relocations in .text [textrel]Signed-off-by Changqing Li <[email protected]>--- recipes-containers/docker/docker_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 31 ++++++++++++++++++++++ 2 files changed, 32 insertions(+)create mode 100644
recipes-containers/docker/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker/docker_git.bb +1
-0@@ -28,6 +28,7 @@ SRC_URI = "\ file://docker.init \ file://hi.Dockerfile \ file://0001-libnetwork-use-GO-instead-of-go.patch \ + file://0001-fix-do_package_qa-error.patch \ " # Apache-2.0 for dockerrecipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +16
-0@@ -0,0 +1,31 @@ +From 56c865e2a7269d63f0780b4cd1ed6fdb18e3ff1b Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Wed, 26 Sep 2018 17:41:59 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/bin/docker' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + cli/scripts/build/dynbinary | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) +recipes-containers/docker/files/0001-fix-do_package_qa-error.patch line 26
Quoted 10 lines
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +10
-0+diff --git a/cli/scripts/build/dynbinary b/cli/scripts/build/dynbinary +index 3c32ed3..938e086 100755 +--- a/cli/scripts/build/dynbinary ++++ b/cli/scripts/build/dynbinary +@@ -9,6 +9,6 @@ source ./scripts/build/.variables + + echo "Building dynamically linked $TARGET" + export CGO_ENABLED=1 +-go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" "${SOURCE}" ++go build -o "${TARGET}" -tags pkcs11 --ldflags "${LDFLAGS}" -buildmode=pie "${SOURCE}"As I mentioned in my other replies, I've never seen these warnings myself. So I need to understand the configuration better.
Quoted 8 lines
Quoted 3 lines
Since I've never seen this before, my first reaction is that any change of the flags to include buildmode=pie needs to be conditional on some other distro feature that is enabled in your configuration.
Most likely the security flags at play. Could also be that you don't have the check enabled. At any rate I agree the details need to be captured in the commit log.
MarkA
Yes. This is caused by security flags -pie -fpie, but this flags are enabled by default now.
below workaround can also make these warning disappear.
SECURITY_CFLAGS_pn-docker = "${SECURITY_NOPIE_CFLAGS}" (SECURITY_NOPIE_CFLAGS ?= "-no-pie -fno-PIE") SECURITY_LDFLAGS_pn-docker = ""
Quoted 26 lines
Quoted 26 lines
Bruce
Quoted 8 lines
recipes-containers/docker/files/0001-fix-do_package_qa-error.patch new file +5
-1+ + ln -sf "$(basename "${TARGET}")" build/docker +-- +2.7.4 + --2.7.4
Quoted 5 lines
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization--
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"
--
_______________________________________________
meta-virtualization mailing list [email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
PATCH 1/1 oci-image-tools: fix do package qa warning
In reply to [email protected]From: Changqing Li <[email protected]>
fix below warning:do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/oci-image-tool' has relocations in .text [textrel]
Add GOBUILDFLAGS which have -buildmode=pie to fix the problem
--- .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ .../oci-image-tools/oci-image-tools_git.bb | 4 ++- 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 recipes-containers/oci-image-tools/files/0001-fix-do_package_qa-error.patch
recipes-containers/oci-image-tools/files/0001-fix-do_package_qa-error.patch new file +32 -0
@@ -0,0 +1,32 @@ +From 981e2582128911d0b131cb47aeb88005b04b38fe Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Thu, 27 Sep 2018 12:54:42 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/oci-image-tool' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + src/import/Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/import/Makefile b/src/import/Makefile +index 61d7a80..7e641e9 100644 +--- a/src/import/Makefile ++++ b/src/import/Makefile +@@ -29,7 +29,7 @@ check-license: + + .PHONY: tool + tool: +- go build -ldflags "-X main.gitCommit=${COMMIT}" -o oci-image-tool ./cmd/oci-image-tool ++ go build -ldflags "-X main.gitCommit=${COMMIT}" ${GOBUILDFLAGS} -o oci-image-tool ./cmd/oci-image-tool + + + all: tool man +-- +2.7.4 +
recipes-containers/oci-image-tools/oci-image-tools_git.bb +3 -1
@@ -15,7 +15,9 @@ DEPENDS = "\ SRC_URI = "git://github.com/opencontainers/image-tools.git \ file://0001-image-manifest-Recursively-remove-pre-existing-entri.patch \ file://0002-image-manifest-Split-unpackLayerEntry-into-its-own-f.patch \ - file://0001-config-make-Config.User-mapping-errors-a-warning.patch" + file://0001-config-make-Config.User-mapping-errors-a-warning.patch \ + file://0001-fix-do_package_qa-error.patch \ +" SRCREV = "4abe1a166f9be97e8e71b1bb4d7599cc29323011" PV = "0.2.0-dev+git${SRCPV}"
Signature · 1 line
2.7.4
PATCH 1/1 docker-distribution: fix do package qa warning [textrel]
In reply to [email protected]From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]
Add GOBUILDFLAGS which have -buildmode=pie to fix it
--- .../docker-distribution/docker-distribution_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch
recipes-containers/docker-distribution/docker-distribution_git.bb +1 -0
@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution \ file://docker-registry.service \ + file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry"
recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file +32 -0
@@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 +
Signature · 1 line
2.7.4
Re: [PATCH] docker-distribution: fix do package qa warning [textrel]
Quoted 9 lines · On Sat, Sep 29, 2018 at 11:18 PM <[email protected]> wrote:
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]Add GOBUILDFLAGS which have -buildmode=pie to fix it
This is not universally true, so your configuration needs more explanation. We haven't needed these flags before, and I've never seen the warnings.
I just build docker and dumped the environment, my GOBUILDFLAGS do not have buildmode=pie
So clearly, your config is different.
I'm not against adding the extra variable, but we are taking a the risk of injecting build configurations that we haven't needed before, and may not want.
So I need to understand what configuration you are building that is making them required, and then figure out what else is being injected that wasn't being injected before.
Same comment applies for all the QA fixes.
Bruce
Quoted 66 lines
Signed-off-by Changqing Li <[email protected]>--- .../docker-distribution/docker-distribution_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker-distribution/docker-distribution_git.bb +1
-0@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution \ file://docker-registry.service \ + file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry"recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file +32
-1@@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 + --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 2 lines
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"
Re: [PATCH] docker-distribution: fix do package qa warning [textrel]
Quoted 22 lines · Bruce Ashfield
Quoted 8 lines · On Sat, Sep 29, 2018 at 11:18 PM <[email protected]> wrote:
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]Add GOBUILDFLAGS which have -buildmode=pie to fix it
This is not universally true, so your configuration needs more explanation. We haven't needed these flags before, and I've never seen the warnings.
I just build docker and dumped the environment, my GOBUILDFLAGS do not have buildmode=pie
So clearly, your config is different.
I'm not against adding the extra variable, but we are taking a the risk of injecting build configurations that we haven't needed before, and may not want.
Quoted 7 lines
So I need to understand what configuration you are building that is making them required, and then figure out what else is being injected that wasn't being injected before.
Same comment applies for all the QA fixes.
Bruce
Hi, Bruce
I do some research, package QA check is enabled by default in insane.bbclass. variable WARN_QA contains the checked items. and textrel is checked by default.
But, this warning is arch related(Besides arch, no other special config). Here is my test result of which archs the warnings can see.
docker arm64 arm x86 x86-64 docker-distribution arm64 containerd-opencontainers arm64 arm x86 x86-64 oci-image-tools arm64 oci-runtime-tools arm64
runc-docker arm64 arm x86 x86-64
About GOBUILDFLAGS, buildmode=pie is added to oe-core recently, so maybe you need to check lastest code, here is the patch.
Do you think we need add the fix patch only for special arch? like SRC_URI_append_aarch64="file://0001-fix-do_package_qa-error.patch"
//Sandy
Quoted 68 lines
Quoted 66 lines
Signed-off-by Changqing Li <[email protected]>--- .../docker-distribution/docker-distribution_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+)create mode 100644
recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker-distribution/docker-distribution_git.bb +1
-0@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution \ file://docker-registry.service \ + file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry"recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file +32
-1@@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 + --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
Re: [PATCH] docker-distribution: fix do package qa warning [textrel]
Quoted 55 lines · Changqing Li
Quoted 22 lines · Bruce Ashfield
Quoted 8 lines · On Sat, Sep 29, 2018 at 11:18 PM<[email protected]> wrote:
From: Changqing Li<[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]Add GOBUILDFLAGS which have -buildmode=pie to fix it
This is not universally true, so your configuration needs more explanation. We haven't needed these flags before, and I've never seen the warnings.
I just build docker and dumped the environment, my GOBUILDFLAGS do not have buildmode=pie
So clearly, your config is different.
I'm not against adding the extra variable, but we are taking a the risk of injecting build configurations that we haven't needed before, and may not want.
Quoted 7 lines
So I need to understand what configuration you are building that is making them required, and then figure out what else is being injected that wasn't being injected before.
Same comment applies for all the QA fixes.
Bruce
Hi, Bruce
I do some research, package QA check is enabled by default in insane.bbclass. variable
WARN_QAcontains the checked items. and textrel is checked by default.But, this warning is arch
related(Besides arch, no other special config). Here is my test result of which archs the warnings can see.docker arm64 arm x86 x86-64 docker-distribution arm64 containerd-opencontainers arm64 arm x86 x86-64 oci-image-tools arm64 oci-runtime-tools arm64
runc-docker arm64 arm x86 x86-64About GOBUILDFLAGS, buildmode=pie is added to oe-core recently, so maybe you need to check lastest code, here is the patch.
Quoted 4 lines
Do you think we need add the fix patch only for special arch? like SRC_URI_append_aarch64="file://0001-fix-do_package_qa-error.patch"
//Sandy
PS: Refer this commit, http://cgit.openembedded.org/openembedded-core/commit/?id=b689c72ad2dc84b8bb55ecbf72d95701707b9bb3
seems problem only met on aarch64, but not only skip aarch64.
//Sandy
Quoted 75 lines
Quoted 67 lines
Quoted 66 lines
Signed-off-by Changqing Li<[email protected]>--- .../docker-distribution/docker-distribution_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+)create mode 100644
recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker-distribution/docker-distribution_git.bb +1
-0@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM ="file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution \ file://docker-registry.service \ +file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry"recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file +32
-1@@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li<[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li<[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 + --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualizationSignature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
Signature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
Re: [PATCH] docker-distribution: fix do package qa warning [textrel]
Quoted 69 lines · Changqing Li
On 10/09/2018 11:14 AM, Changqing Li wrote:
On 10/01/2018 09:22 AM, Bruce Ashfield wrote:
On Sat, Sep 29, 2018 at 11:18 PM <[email protected]> <[email protected]> wrote:
From: Changqing Li <[email protected]> <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]Add GOBUILDFLAGS which have -buildmode=pie to fix it
This is not universally true, so your configuration needs more explanation. We haven't needed these flags before, and I've never seen the warnings.
I just build docker and dumped the environment, my GOBUILDFLAGS do not have buildmode=pie
So clearly, your config is different.
I'm not against adding the extra variable, but we are taking a the risk of injecting build configurations that we haven't needed before, and may not want.
So I need to understand what configuration you are building that is making them required, and then figure out what else is being injected that wasn't being injected before.
Same comment applies for all the QA fixes.
Bruce
Hi, Bruce
I do some research, package QA check is enabled by default in insane.bbclass.
variableWARN_QAcontains the checked items. and textrel is checked by default.But, this warning is arch
related(Besides arch, no other special config).
Here is my test result of which archs the warnings can see.docker arm64 arm x86 x86-64
docker-distribution arm64
containerd-opencontainers arm64 arm x86 x86-64
oci-image-tools arm64
oci-runtime-tools arm64
runc-docker arm64 arm x86 x86-64About GOBUILDFLAGS, buildmode=pie is added to oe-core recently, so maybe you need
to check lastest code, here is the patch.Do you think we need add the fix patch only for special arch? like SRC_URI_append_aarch64="file://0001-fix-do_package_qa-error.patch"
Quoted 7 lines
//Sandy
PS: Refer this commit,
http://cgit.openembedded.org/openembedded-core/commit/?id=b689c72ad2dc84b8bb55ecbf72d95701707b9bb3
seems problem only met on aarch64, but not only skip aarch64.
My trees are completely up to date. I always track master and master-next for these builds.
And yet, I can't trigger any build issues from the QA check. I'd have expected that other docker
users would also be hitting this and would have either reported an issue, or sent patches.
But like the commit you are referencing, I'd prefer to just add a skip to the QA versus take
patches for issues that I'm not able to reproduce.
Bruce
Quoted 85 lines
//Sandy
Signed-off-by Changqing Li <[email protected]> <[email protected]>--- .../docker-distribution/docker-distribution_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker-distribution/docker-distribution_git.bb +1
-0@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution \ file://docker-registry.service \ + file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry"recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file +32
-1@@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> <[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> <[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 + --2.7.4
--
_______________________________________________
meta-virtualization mailing [email protected]://lists.yoctoproject.org/listinfo/meta-virtualization--
BRsSandy(Li Changqing)
Wind River Linux--
BRsSandy(Li Changqing)
Wind River Linux
Signature · 2 lines
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"
Re: [PATCH] docker-distribution: fix do package qa warning [textrel]
Quoted 78 lines · Bruce Ashfield
On Tue, Oct 9, 2018 at 5:20 AM Changqing Li <[email protected] <mailto:[email protected]>> wrote:
On 10/09/2018 11:14 AM, Changqing Li wrote:Quoted 59 lines · Bruce Ashfield
Quoted 22 lines · On Sat, Sep 29, 2018 at 11:18 PM<[email protected]>…
Quoted 8 lines
From: Changqing Li<[email protected]> <mailto:[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]Add GOBUILDFLAGS which have -buildmode=pie to fix it
This is not universally true, so your configuration needs more explanation. We haven't needed these flags before, and I've never seen the warnings.
I just build docker and dumped the environment, my GOBUILDFLAGS do not have buildmode=pie
So clearly, your config is different.
I'm not against adding the extra variable, but we are taking a the risk of injecting build configurations that we haven't needed before, and may not want.
Quoted 7 lines
So I need to understand what configuration you are building that is making them required, and then figure out what else is being injected that wasn't being injected before.
Same comment applies for all the QA fixes.
Bruce
Hi, Bruce
I do some research, package QA check is enabled by default in insane.bbclass.
variableWARN_QAcontains the checked items. and textrel is checked by default.But, this warning is arch
related(Besides arch, no other special config).
Here is my test result of which archs the warnings can see.docker arm64 arm x86 x86-64 docker-distribution arm64 containerd-opencontainers arm64 arm x86 x86-64 oci-image-tools arm64 oci-runtime-tools arm64
runc-docker arm64 arm x86 x86-64About GOBUILDFLAGS, buildmode=pie is added to oe-core recently, so maybe you need
to check lastest code, here is the patch.Quoted 4 lines
Do you think we need add the fix patch only for special arch? like SRC_URI_append_aarch64="file://0001-fix-do_package_qa-error.patch"
//Sandy
PS: Refer this commit,
http://cgit.openembedded.org/openembedded-core/commit/?id=b689c72ad2dc84b8bb55ecbf72d95701707b9bb3
seems problem only met on aarch64, but not only skip aarch64.My trees are completely up to date. I always track master and master-next for these builds.
Quoted 7 lines
And yet, I can't trigger any build issues from the QA check. I'd have expected that other docker users would also be hitting this and would have either reported an issue, or sent patches.
But like the commit you are referencing, I'd prefer to just add a skip to the QA versus take patches for issues that I'm not able to reproduce.
Bruce
ok. I will resend the patch to skip the qa check.
//Sandy
Quoted 91 lines
//SandyQuoted 69 lines
Quoted 62 lines
Quoted 62 lines
Signed-off-by: Changqing Li<[email protected]> <mailto:[email protected]> --- .../docker-distribution/docker-distribution_git.bb <http://docker-distribution_git.bb> | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch diff --git a/recipes-containers/docker-distribution/docker-distribution_git.bb <http://docker-distribution_git.bb> b/recipes-containers/docker-distribution/docker-distribution_git.bb <http://docker-distribution_git.bb> index add5ce1..7c7bce2 100644 --- a/recipes-containers/docker-distribution/docker-distribution_git.bb <http://docker-distribution_git.bb> +++ b/recipes-containers/docker-distribution/docker-distribution_git.bb <http://docker-distribution_git.bb> @@ -6,6 +6,7 @@ LIC_FILES_CHKSUM ="file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution <http://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution> \ file://docker-registry.service \ +file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry" diff --git a/recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch b/recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file mode 100644 index 0000000..269b0cd --- /dev/null +++ b/recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch @@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li<[email protected]> <mailto:[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li<[email protected]> <mailto:[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 + -- 2.7.4Quoted 6 lines
Quoted 6 lines
-- _______________________________________________ meta-virtualization mailing list [email protected] <mailto:[email protected]> https://lists.yoctoproject.org/listinfo/meta-virtualizationQuoted 7 lines
--
BRsSandy(Li Changqing)
Wind River Linux--
BRsSandy(Li Changqing)
Wind River LinuxSignature · 1 line
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"
Signature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
Re: [PATCH] docker-distribution: fix do package qa warning [textrel]
In reply to Bruce AshfieldQuoted 22 lines · Bruce Ashfield
Quoted 8 lines · On Sat, Sep 29, 2018 at 11:18 PM <[email protected]> wrote:
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]Add GOBUILDFLAGS which have -buildmode=pie to fix it
This is not universally true, so your configuration needs more explanation. We haven't needed these flags before, and I've never seen the warnings.
I just build docker and dumped the environment, my GOBUILDFLAGS do not have buildmode=pie
So clearly, your config is different.
I'm not against adding the extra variable, but we are taking a the risk of injecting build configurations that we haven't needed before, and may not want.
Quoted 7 lines
So I need to understand what configuration you are building that is making them required, and then figure out what else is being injected that wasn't being injected before.
Same comment applies for all the QA fixes.
Bruce
Hi, Bruce
I do some research, package QA check is enabled by default in insane.bbclass. variable WARN_QA contains the checked items. and textrel is checked by default.
But, this warning is arch related(Besides arch, no other special config). Here is my test result of which archs the warnings can see.
docker arm64 arm x86 x86-64 docker-distribution arm64 containerd-opencontainers arm64 arm x86 x86-64 oci-image-tools arm64 oci-runtime-tools arm64
runc-docker arm64 arm x86 x86-64
About GOBUILDFLAGS, buildmode=pie is added to oe-core recently, so maybe you need to check lastest code, here is the patch.
Do you think we need add the fix patch only for special arch? like SRC_URI_append_aarch64="file://0001-fix-do_package_qa-error.patch"
Quoted 68 lines
Quoted 66 lines
Signed-off-by Changqing Li <[email protected]>--- .../docker-distribution/docker-distribution_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+)create mode 100644
recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker-distribution/docker-distribution_git.bb +1
-0@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution \ file://docker-registry.service \ + file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry"recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file +32
-1@@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 + --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
Re: [PATCH] docker-distribution: fix do package qa warning [textrel]
Please ignore this mail, this mail is same as next one, just send two times by mistake.
Quoted 132 lines · Changqing Li
Quoted 22 lines · Bruce Ashfield
Quoted 8 lines · On Sat, Sep 29, 2018 at 11:18 PM<[email protected]> wrote:
From: Changqing Li<[email protected]>
fix below warning:
do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' has relocations in .text [textrel]Add GOBUILDFLAGS which have -buildmode=pie to fix it
This is not universally true, so your configuration needs more explanation. We haven't needed these flags before, and I've never seen the warnings.
I just build docker and dumped the environment, my GOBUILDFLAGS do not have buildmode=pie
So clearly, your config is different.
I'm not against adding the extra variable, but we are taking a the risk of injecting build configurations that we haven't needed before, and may not want.
Quoted 7 lines
So I need to understand what configuration you are building that is making them required, and then figure out what else is being injected that wasn't being injected before.
Same comment applies for all the QA fixes.
Bruce
Hi, Bruce
I do some research, package QA check is enabled by default in insane.bbclass. variable
WARN_QAcontains the checked items. and textrel is checked by default.But, this warning is arch
related(Besides arch, no other special config). Here is my test result of which archs the warnings can see.docker arm64 arm x86 x86-64 docker-distribution arm64 containerd-opencontainers arm64 arm x86 x86-64 oci-image-tools arm64 oci-runtime-tools arm64
runc-docker arm64 arm x86 x86-64About GOBUILDFLAGS, buildmode=pie is added to oe-core recently, so maybe you need to check lastest code, here is the patch.
Do you think we need add the fix patch only for special arch? like SRC_URI_append_aarch64="file://0001-fix-do_package_qa-error.patch"
Quoted 66 lines
Quoted 65 lines
Signed-off-by Changqing Li<[email protected]>--- .../docker-distribution/docker-distribution_git.bb | 1 + .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ 2 files changed, 33 insertions(+)create mode 100644
recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patchrecipes-containers/docker-distribution/docker-distribution_git.bb +1
-0@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM ="file://LICENSE;md5=d2794c0df5b907fdace235a619d80314" SRCREV_distribution="48294d928ced5dd9b378f7fd7c6f5da3ff3f2c89" SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.6;name=distribution;destsuffix=git/src/github.com/docker/distribution \ file://docker-registry.service \ +file://0001-fix-do_package_qa-error.patch \ " PACKAGES =+ "docker-registry"recipes-containers/docker-distribution/files/0001-fix-do_package_qa-error.patch new file +32
-1@@ -0,0 +1,32 @@ +From 4b9d701fabff8e7969db081406d00fa9fe46b3fd Mon Sep 17 00:00:00 2001 +From: Changqing Li<[email protected]> +Date: Thu, 27 Sep 2018 11:05:51 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/registry' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li<[email protected]> +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 47b8f1d..13b0f92 100644 +--- a/Makefile ++++ b/Makefile +@@ -39,7 +39,7 @@ GODEP=$(shell which godep || echo '') + + ${PREFIX}/bin/registry: $(GOFILES) + @echo "+ $@" +- @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GO_GCFLAGS} ./cmd/registry ++ @go build -tags "${DOCKER_BUILDTAGS}" -o $@ ${GO_LDFLAGS} ${GOBUILDFLAGS} ${GO_GCFLAGS} ./cmd/registry + + ${PREFIX}/bin/digest: $(GOFILES) + @echo "+ $@" +-- +2.7.4 + --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualizationSignature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
Signature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux
PATCH 1/1 oci-runtime-tools: fix do package qa warning
In reply to [email protected]From: Changqing Li <[email protected]>
fix below warning:do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/oci-runtime-tool' has relocations in .text [textrel]
Add GOBUILDFLAGS which have -buildmode=pie to fix the problem
--- .../files/0001-fix-do_package_qa-error.patch | 32 ++++++++++++++++++++++ .../oci-runtime-tools/oci-runtime-tools_git.bb | 1 + 2 files changed, 33 insertions(+) create mode 100644 recipes-containers/oci-runtime-tools/files/0001-fix-do_package_qa-error.patch
recipes-containers/oci-runtime-tools/files/0001-fix-do_package_qa-error.patch new file +32 -0
@@ -0,0 +1,32 @@ +From 7de9fd7db7a001b66d92d5e80806e50bb5252392 Mon Sep 17 00:00:00 2001 +From: Changqing Li <[email protected]> +Date: Thu, 27 Sep 2018 12:50:32 +0800 +Subject: [PATCH] fix do_package_qa error + +fix below error: +do_package_qa: QA Issue: ELF binary 'xxx/usr/sbin/oci-runtime-tool' +has relocations in .text [textrel] + +Upstream-Status: Inappropriate [oe-specific] + +Signed-off-by: Changqing Li <[email protected]> +--- + src/import/Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/import/Makefile b/src/import/Makefile +index 77626d2..b97f6ec 100644 +--- a/src/import/Makefile ++++ b/src/import/Makefile +@@ -8,7 +8,7 @@ COMMIT=$(shell git rev-parse HEAD 2> /dev/null || true) + all: tool runtimetest + + tool: +- go build -tags "$(BUILDTAGS)" -ldflags "-X main.gitCommit=${COMMIT}" -o oci-runtime-tool ./cmd/oci-runtime-tool ++ go build -tags "$(BUILDTAGS)" -ldflags "-X main.gitCommit=${COMMIT}" ${GOBUILDFLAGS} -o oci-runtime-tool ./cmd/oci-runtime-tool + + .PHONY: runtimetest + runtimetest: +-- +2.7.4 +
recipes-containers/oci-runtime-tools/oci-runtime-tools_git.bb +1 -0
@@ -5,6 +5,7 @@ LIC_FILES_CHKSUM = "file://src/import/LICENSE;md5=b355a61a394a504dacde901c958f66 SRC_URI = "git://github.com/opencontainers/runtime-tools.git \ file://0001-Revert-implement-add-set-function-for-hooks-items.patch \ + file://0001-fix-do_package_qa-error.patch \ " SRCREV = "6e7da8148f4de2c9e9c9d3b345576898d4f412cb"
Signature · 1 line
2.7.4
The shortlog of this isn't quite right.
You are not really fixing the QA warning, but are making sure that it is masked in some sort of multlib configuration ?
That needs to be clarified in the shortlog.
Quoted 6 lines · On Sat, Sep 29, 2018 at 11:17 PM <[email protected]> wrote:
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: NoGNU_HASHin the elf binary:
xxx/usr/sbin/registry' [ldflags]
And the configuration explained here.
Bruce
Quoted 27 lines
Signed-off-by Changqing Li <[email protected]>--- recipes-containers/docker-distribution/docker-distribution_git.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)recipes-containers/docker-distribution/docker-distribution_git.bb +1
-2@@ -58,7 +58,7 @@ do_install() { } INSANE_SKIP_${PN} += "ldflags already-stripped" -INSANE_SKIP_docker-registry += "ldflags already-stripped" +INSANE_SKIP_${MLPREFIX}docker-registry += "ldflags already-stripped" FILES_docker-registry = "${sbindir}/*" FILES_docker-registry += "${systemd_unitdir}/system/docker-registry.service" --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 2 lines
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"
Quoted 7 lines · Bruce Ashfield
The shortlog of this isn't quite right.
You are not really fixing the QA warning, but are making sure that it is masked in some sort of multlib configuration ?
That needs to be clarified in the shortlog.On Sat, Sep 29, 2018 at 11:17 PM <[email protected]> wrote:
Quoted 8 lines
Quoted 5 lines
From: Changqing Li <[email protected]>
fix below warning:
do_package_qa: QA Issue: NoGNU_HASHin the elf binary:
xxx/usr/sbin/registry' [ldflags]And the configuration explained here.
Bruce
I will update the shortlog in next version.
//Sandy
Quoted 29 lines
Quoted 27 lines
Signed-off-by Changqing Li <[email protected]>--- recipes-containers/docker-distribution/docker-distribution_git.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)recipes-containers/docker-distribution/docker-distribution_git.bb +1
-2@@ -58,7 +58,7 @@ do_install() { } INSANE_SKIP_${PN} += "ldflags already-stripped" -INSANE_SKIP_docker-registry += "ldflags already-stripped" +INSANE_SKIP_${MLPREFIX}docker-registry += "ldflags already-stripped" FILES_docker-registry = "${sbindir}/*" FILES_docker-registry += "${systemd_unitdir}/system/docker-registry.service" --2.7.4
--
_______________________________________________
meta-virtualization mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/meta-virtualization
Signature · 4 lines
BRs Sandy(Li Changqing) Wind River Linux