meta-virtualization.lists.yoctoproject.org archive mirror
 help / color / mirror / Atom feed
* [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings
@ 2022-06-12  8:00 Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 2/9] docker-distribution: fix build error on new hosts Chen Qi
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

In order for systemd variables such as SYSTEMD_AUTO_ENABLE to have
effect, we need to inherit the systemd class. We also need to specify
the package which contains the service.

As go.bbclass already inherits goarch.bbclass, we only need to inehrit
go.bbclass.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 .../docker-distribution/docker-distribution_git.bb            | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/recipes-containers/docker-distribution/docker-distribution_git.bb b/recipes-containers/docker-distribution/docker-distribution_git.bb
index 0dbdc49..395694a 100644
--- a/recipes-containers/docker-distribution/docker-distribution_git.bb
+++ b/recipes-containers/docker-distribution/docker-distribution_git.bb
@@ -16,8 +16,7 @@ S = "${WORKDIR}/git/src/github.com/docker/distribution"
 
 GO_IMPORT = "import"
 
-inherit goarch
-inherit go
+inherit goarch go systemd
 
 # This disables seccomp and apparmor, which are on by default in the
 # go package. 
@@ -66,6 +65,7 @@ FILES:docker-registry += "${systemd_unitdir}/system/docker-registry.service"
 FILES:docker-registry += "${sysconfdir}/docker-distribution/*"
 FILES:docker-registry += "${localstatedir}/lib/registry/"
 
+SYSTEMD_PACKAGES = "docker-registry"
 SYSTEMD_SERVICE:docker-registry = "${@bb.utils.contains('DISTRO_FEATURES','systemd','docker-registry.service','',d)}"
 SYSTEMD_AUTO_ENABLE:docker-registry = "enable"
 
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 2/9] docker-distribution: fix build error on new hosts
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 3/9] docker-distribution: upgrade to 2.8.1 Chen Qi
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

Fix settings for GOROOT, CGO_CFLAGS and CGO_LDFLAGS.

The previous setting for GOROOT is no longer valid as the directory
does not exist for now. So adjust the GOROOT setting.

Currently CGO_CFLAGS is set to use BUILDSDK_CFLAGS, and this is
incorrect. We need target flags instead of SDK related flags. Such
setting happens to work for some hosts. However, when building on
newer hosts, we get QA error like below:

  ERROR: docker-distribution-v2.7.1-r0 do_package_qa:
  QA Issue: /usr/sbin/registry contained in package docker-registry requires
  libc.so.6(GLIBC_2.34)(64bit), but no providers found in RDEPENDS_docker-registry? [file-rdeps]

The above error was found on hardknott on host Fedora 35.
Tracking down the error and I found it's using host stuff which is likely
to be caused by using incorrect CGO_CFLAGS. As the master branch is
using the same settings, it has the same issue.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 .../docker-distribution/docker-distribution_git.bb          | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/recipes-containers/docker-distribution/docker-distribution_git.bb b/recipes-containers/docker-distribution/docker-distribution_git.bb
index 395694a..89c5980 100644
--- a/recipes-containers/docker-distribution/docker-distribution_git.bb
+++ b/recipes-containers/docker-distribution/docker-distribution_git.bb
@@ -25,15 +25,15 @@ EXTRA_OEMAKE="BUILDTAGS=''"
 do_compile() {
 	export GOARCH="${TARGET_GOARCH}"
 	export GOPATH="${WORKDIR}/git/"
-	export GOROOT="${STAGING_LIBDIR_NATIVE}/${TARGET_SYS}/go"
+	export GOROOT="${STAGING_LIBDIR}/go"
 	# Pass the needed cflags/ldflags so that cgo
 	# can find the needed headers files and libraries
 	export CGO_ENABLED="1"
 	export CFLAGS=""
 	export LDFLAGS=""
-	export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+	export CGO_CFLAGS="${TARGET_CFLAGS}"
 	export GO_GCFLAGS=""
-	export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+	export CGO_LDFLAGS="${TARGET_LDFLAGS}"
 	export GO111MODULE=off
 
 	cd ${S}
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 3/9] docker-distribution: upgrade to 2.8.1
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 2/9] docker-distribution: fix build error on new hosts Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 4/9] skopeo: clean up depends and fix CGO settings Chen Qi
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

v2.8.1 is the latest stable version.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 .../docker-distribution/docker-distribution_git.bb          | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/recipes-containers/docker-distribution/docker-distribution_git.bb b/recipes-containers/docker-distribution/docker-distribution_git.bb
index 89c5980..93c2067 100644
--- a/recipes-containers/docker-distribution/docker-distribution_git.bb
+++ b/recipes-containers/docker-distribution/docker-distribution_git.bb
@@ -3,15 +3,15 @@ SUMMARY = "The Docker toolset to pack, ship, store, and deliver content"
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=d2794c0df5b907fdace235a619d80314"
 
-SRCREV_distribution= "3b7b534569220c840993aad03e3eafe54b923f4d"
-SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.7;name=distribution;destsuffix=git/src/github.com/docker/distribution;protocol=https \
+SRCREV_distribution= "b5ca020cfbe998e5af3457fda087444cf5116496"
+SRC_URI = "git://github.com/docker/distribution.git;branch=release/2.8;name=distribution;destsuffix=git/src/github.com/docker/distribution;protocol=https \
            file://docker-registry.service \
            file://0001-build-use-to-use-cross-go-compiler.patch \
           "
 
 PACKAGES =+ "docker-registry"
 
-PV = "v2.8.0+git${SRCPV}"
+PV = "v2.8.1+git${SRCPV}"
 S = "${WORKDIR}/git/src/github.com/docker/distribution"
 
 GO_IMPORT = "import"
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 4/9] skopeo: clean up depends and fix CGO settings
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 2/9] docker-distribution: fix build error on new hosts Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 3/9] docker-distribution: upgrade to 2.8.1 Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 5/9] umoci: adjust CGO_CFLAGS and CGO_LDFLAGS settings Chen Qi
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

According to https://github.com/containers/skopeo/blob/main/install.md#building-from-source,
the ostree dependency is not needed.

Also, adjust the CGO_CFLAGS and CGO_LDFALGS to use target
flags instead of the SDK ones.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 recipes-containers/skopeo/skopeo_git.bb | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/recipes-containers/skopeo/skopeo_git.bb b/recipes-containers/skopeo/skopeo_git.bb
index f3217db..35377a8 100644
--- a/recipes-containers/skopeo/skopeo_git.bb
+++ b/recipes-containers/skopeo/skopeo_git.bb
@@ -9,7 +9,6 @@ DEPENDS = " \
     lvm2 \
     btrfs-tools \
     glib-2.0 \
-    ostree \
 "
 
 inherit go
@@ -61,8 +60,8 @@ do_compile() {
 	export CGO_ENABLED="1"
 	export CFLAGS=""
 	export LDFLAGS=""
-	export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
-	export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+	export CGO_CFLAGS="${TARGET_CFLAGS}"
+	export CGO_LDFLAGS="${TARGET_LDFLAGS}"
 	cd ${S}/src/import
 
 	export GO111MODULE=off
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 5/9] umoci: adjust CGO_CFLAGS and CGO_LDFLAGS settings
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
                   ` (2 preceding siblings ...)
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 4/9] skopeo: clean up depends and fix CGO settings Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 6/9] oci-runtime-tools: adjust GOROOT, CGO_CFLAGS and CGO_LDFALGS Chen Qi
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

The CGO_CFLAGS and CGO_LDFLAGS should use target flags instead
of the nativesdk ones.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 recipes-containers/umoci/umoci_git.bb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/recipes-containers/umoci/umoci_git.bb b/recipes-containers/umoci/umoci_git.bb
index a2c0827..3e7b912 100644
--- a/recipes-containers/umoci/umoci_git.bb
+++ b/recipes-containers/umoci/umoci_git.bb
@@ -61,8 +61,8 @@ do_compile() {
     export CGO_ENABLED="1"
     export CFLAGS=""
     export LDFLAGS=""
-    export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
-    export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+    export CGO_CFLAGS="${TARGET_CFLAGS}"
+    export CGO_LDFLAGS="${TARGET_LDFLAGS}"
 
     export GO111MODULE=off
 
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 6/9] oci-runtime-tools: adjust GOROOT, CGO_CFLAGS and CGO_LDFALGS
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
                   ` (3 preceding siblings ...)
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 5/9] umoci: adjust CGO_CFLAGS and CGO_LDFLAGS settings Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 7/9] riddler: " Chen Qi
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

Adjust the GOROOT setting as directory specified by the original
one does not exist.

The CGO_CFLAGS and CGO_LDFLAGS should use target flags instead
of the nativesdk ones.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 .../oci-runtime-tools/oci-runtime-tools_git.bb              | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/recipes-containers/oci-runtime-tools/oci-runtime-tools_git.bb b/recipes-containers/oci-runtime-tools/oci-runtime-tools_git.bb
index 838d24b..0a4c909 100644
--- a/recipes-containers/oci-runtime-tools/oci-runtime-tools_git.bb
+++ b/recipes-containers/oci-runtime-tools/oci-runtime-tools_git.bb
@@ -18,7 +18,7 @@ inherit go
 
 do_compile() {
 	export GOARCH="${TARGET_GOARCH}"
-	export GOROOT="${STAGING_LIBDIR_NATIVE}/${TARGET_SYS}/go"
+	export GOROOT="${STAGING_LIBDIR}/go"
 	export GOPATH="${S}/src/import:${S}/src/import/vendor"
 
 	# Pass the needed cflags/ldflags so that cgo
@@ -26,8 +26,8 @@ do_compile() {
 	export CGO_ENABLED="1"
 	export CFLAGS=""
 	export LDFLAGS=""
-	export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
-	export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+	export CGO_CFLAGS="${TARGET_CFLAGS}"
+	export CGO_LDFLAGS="${TARGET_LDFLAGS}"
 	export GO111MODULE=off
 
 	# fixes:
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 7/9] riddler:  adjust GOROOT, CGO_CFLAGS and CGO_LDFALGS
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
                   ` (4 preceding siblings ...)
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 6/9] oci-runtime-tools: adjust GOROOT, CGO_CFLAGS and CGO_LDFALGS Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 8/9] oci-image-tools: " Chen Qi
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

Adjust the GOROOT setting as directory specified by the original
one does not exist.

The CGO_CFLAGS and CGO_LDFLAGS should use target flags instead
of the nativesdk ones.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 recipes-containers/riddler/riddler_git.bb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/recipes-containers/riddler/riddler_git.bb b/recipes-containers/riddler/riddler_git.bb
index be751d6..e103331 100644
--- a/recipes-containers/riddler/riddler_git.bb
+++ b/recipes-containers/riddler/riddler_git.bb
@@ -26,7 +26,7 @@ EXTRA_OEMAKE="BUILDTAGS=''"
 
 do_compile() {
 	export GOARCH="${TARGET_GOARCH}"
-	export GOROOT="${STAGING_LIBDIR_NATIVE}/${TARGET_SYS}/go"
+	export GOROOT="${STAGING_LIBDIR}/go"
 	# Setup vendor directory so that it can be used in GOPATH.
 	#
 	# Go looks in a src directory under any directory in GOPATH but riddler
@@ -44,8 +44,8 @@ do_compile() {
 	export CGO_ENABLED="1"
 	export CFLAGS=""
 	export LDFLAGS=""
-	export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
-	export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+	export CGO_CFLAGS="${TARGET_CFLAGS}"
+	export CGO_LDFLAGS="${TARGET_LDFLAGS}"
 	export GO111MODULE=off
 
 	cd ${S}/src/import
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 8/9] oci-image-tools: adjust GOROOT, CGO_CFLAGS and CGO_LDFALGS
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
                   ` (5 preceding siblings ...)
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 7/9] riddler: " Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 9/9] netns: " Chen Qi
  2022-06-14 19:50 ` [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Bruce Ashfield
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

Adjust the GOROOT setting as directory specified by the original
one does not exist.

The CGO_CFLAGS and CGO_LDFLAGS should use target flags instead
of the nativesdk ones.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 recipes-containers/oci-image-tools/oci-image-tools_git.bb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/recipes-containers/oci-image-tools/oci-image-tools_git.bb b/recipes-containers/oci-image-tools/oci-image-tools_git.bb
index 8bafd2a..90e671c 100644
--- a/recipes-containers/oci-image-tools/oci-image-tools_git.bb
+++ b/recipes-containers/oci-image-tools/oci-image-tools_git.bb
@@ -29,7 +29,7 @@ EXTRA_OEMAKE="BUILDTAGS=''"
 
 do_compile() {
 	export GOARCH="${TARGET_GOARCH}"
-	export GOROOT="${STAGING_LIBDIR_NATIVE}/${TARGET_SYS}/go"
+	export GOROOT="${STAGING_LIBDIR}/go"
 	# Setup vendor directory so that it can be used in GOPATH.
 	#
 	# Go looks in a src directory under any directory in GOPATH but riddler
@@ -48,8 +48,8 @@ do_compile() {
 	export CGO_ENABLED="1"
 	export CFLAGS=""
 	export LDFLAGS=""
-	export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
-	export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+	export CGO_CFLAGS="${TARGET_CFLAGS}"
+	export CGO_LDFLAGS="${TARGET_LDFLAGS}"
 	export GO111MODULE=off
 
 	cd ${S}/src/import
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [meta-virtualization][PATCH V2 9/9] netns: adjust GOROOT, CGO_CFLAGS and CGO_LDFALGS
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
                   ` (6 preceding siblings ...)
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 8/9] oci-image-tools: " Chen Qi
@ 2022-06-12  8:00 ` Chen Qi
  2022-06-14 19:50 ` [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Bruce Ashfield
  8 siblings, 0 replies; 10+ messages in thread
From: Chen Qi @ 2022-06-12  8:00 UTC (permalink / raw)
  To: meta-virtualization

Adjust the GOROOT setting as directory specified by the original
one does not exist.

The CGO_CFLAGS and CGO_LDFLAGS should use target flags instead
of the nativesdk ones.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 recipes-networking/netns/netns_git.bb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/recipes-networking/netns/netns_git.bb b/recipes-networking/netns/netns_git.bb
index cd17e1a..a4dcb42 100644
--- a/recipes-networking/netns/netns_git.bb
+++ b/recipes-networking/netns/netns_git.bb
@@ -19,7 +19,7 @@ EXTRA_OEMAKE = "GO='${GO}'"
 
 do_compile() {
 	export GOARCH="${TARGET_GOARCH}"
-	export GOROOT="${STAGING_LIBDIR_NATIVE}/${TARGET_SYS}/go"
+	export GOROOT="${STAGING_LIBDIR}/go"
 	# Setup vendor directory so that it can be used in GOPATH.
 	#
 	# Go looks in a src directory under any directory in GOPATH but netns
@@ -37,8 +37,8 @@ do_compile() {
 	export CGO_ENABLED="1"
 	export CFLAGS=""
 	export LDFLAGS=""
-	export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
-	export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
+	export CGO_CFLAGS="${TARGET_CFLAGS}"
+	export CGO_LDFLAGS="${TARGET_LDFLAGS}"
 	export GOFLAGS="-mod=vendor"
 
 	cd ${S}/src/import
-- 
2.36.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings
  2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
                   ` (7 preceding siblings ...)
  2022-06-12  8:00 ` [meta-virtualization][PATCH V2 9/9] netns: " Chen Qi
@ 2022-06-14 19:50 ` Bruce Ashfield
  8 siblings, 0 replies; 10+ messages in thread
From: Bruce Ashfield @ 2022-06-14 19:50 UTC (permalink / raw)
  To: Chen Qi; +Cc: meta-virtualization

Thanks!

This series looks better.

I'm working through some other integration issues, but will get this
staged and tested shortly.

Bruce

On Sun, Jun 12, 2022 at 4:00 AM Chen Qi <Qi.Chen@windriver.com> wrote:
>
> In order for systemd variables such as SYSTEMD_AUTO_ENABLE to have
> effect, we need to inherit the systemd class. We also need to specify
> the package which contains the service.
>
> As go.bbclass already inherits goarch.bbclass, we only need to inehrit
> go.bbclass.
>
> Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> ---
>  .../docker-distribution/docker-distribution_git.bb            | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/recipes-containers/docker-distribution/docker-distribution_git.bb b/recipes-containers/docker-distribution/docker-distribution_git.bb
> index 0dbdc49..395694a 100644
> --- a/recipes-containers/docker-distribution/docker-distribution_git.bb
> +++ b/recipes-containers/docker-distribution/docker-distribution_git.bb
> @@ -16,8 +16,7 @@ S = "${WORKDIR}/git/src/github.com/docker/distribution"
>
>  GO_IMPORT = "import"
>
> -inherit goarch
> -inherit go
> +inherit goarch go systemd
>
>  # This disables seccomp and apparmor, which are on by default in the
>  # go package.
> @@ -66,6 +65,7 @@ FILES:docker-registry += "${systemd_unitdir}/system/docker-registry.service"
>  FILES:docker-registry += "${sysconfdir}/docker-distribution/*"
>  FILES:docker-registry += "${localstatedir}/lib/registry/"
>
> +SYSTEMD_PACKAGES = "docker-registry"
>  SYSTEMD_SERVICE:docker-registry = "${@bb.utils.contains('DISTRO_FEATURES','systemd','docker-registry.service','',d)}"
>  SYSTEMD_AUTO_ENABLE:docker-registry = "enable"
>
> --
> 2.36.0
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#7370): https://lists.yoctoproject.org/g/meta-virtualization/message/7370
> Mute This Topic: https://lists.yoctoproject.org/mt/91702570/1050810
> Group Owner: meta-virtualization+owner@lists.yoctoproject.org
> Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [bruce.ashfield@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>


-- 
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2022-06-14 19:50 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-12  8:00 [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 2/9] docker-distribution: fix build error on new hosts Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 3/9] docker-distribution: upgrade to 2.8.1 Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 4/9] skopeo: clean up depends and fix CGO settings Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 5/9] umoci: adjust CGO_CFLAGS and CGO_LDFLAGS settings Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 6/9] oci-runtime-tools: adjust GOROOT, CGO_CFLAGS and CGO_LDFALGS Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 7/9] riddler: " Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 8/9] oci-image-tools: " Chen Qi
2022-06-12  8:00 ` [meta-virtualization][PATCH V2 9/9] netns: " Chen Qi
2022-06-14 19:50 ` [meta-virtualization][PATCH V2 1/9] docker-distribution: fix the inehrit and systemd settings Bruce Ashfield

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).