[meta-virtualization] [PATCH] lxc: temporary workaround for gcc 7 issue

Bruce Ashfield bruce.ashfield at gmail.com
Mon Jun 19 05:37:39 PDT 2017


merged.

Bruce

On Thu, Jun 15, 2017 at 3:24 PM, Mark Asselstine <
mark.asselstine at windriver.com> wrote:

> gcc 7 has a bug:
> https://bugzilla.yoctoproject.org/show_bug.cgi?id=11672
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78969
>
> In order to avoid the build failure that this causes we reduce the
> range by one. Better to have a slight reduction in the range than
> having nobody to be able to build and use lxc.
>
> Once gcc is fixed this can be reverted.
>
> Signed-off-by: Mark Asselstine <mark.asselstine at windriver.com>
> ---
>  .../files/cgroups-work-around-issue-in-gcc-7.patch | 34
> ++++++++++++++++++++++
>  recipes-containers/lxc/lxc_2.0.8.bb                |  1 +
>  2 files changed, 35 insertions(+)
>  create mode 100644 recipes-containers/lxc/files/
> cgroups-work-around-issue-in-gcc-7.patch
>
> diff --git a/recipes-containers/lxc/files/cgroups-work-around-issue-in-gcc-7.patch
> b/recipes-containers/lxc/files/cgroups-work-around-issue-in-gcc-7.patch
> new file mode 100644
> index 0000000..90740fb
> --- /dev/null
> +++ b/recipes-containers/lxc/files/cgroups-work-around-
> issue-in-gcc-7.patch
> @@ -0,0 +1,34 @@
> +From 58a2d817a82100d287c60c63315d81445cdba3f9 Mon Sep 17 00:00:00 2001
> +From: Mark Asselstine <mark.asselstine at windriver.com>
> +Date: Thu, 15 Jun 2017 15:12:08 -0400
> +Subject: [PATCH] cgroups: work around issue in gcc 7
> +
> +This works around
> +https://bugzilla.yoctoproject.org/show_bug.cgi?id=11672
> +https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78969
> +
> +By removing a single cgroup entry. For the majority of usecases this
> +loss of a single entry should not be an issue and once gcc 7 is fixed
> +we can revert this.
> +
> +Signed-off-by: Mark Asselstine <mark.asselstine at windriver.com>
> +---
> + src/lxc/cgroups/cgfsng.c | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/src/lxc/cgroups/cgfsng.c b/src/lxc/cgroups/cgfsng.c
> +index ebd548b..c520abd 100644
> +--- a/src/lxc/cgroups/cgfsng.c
> ++++ b/src/lxc/cgroups/cgfsng.c
> +@@ -1373,7 +1373,7 @@ static inline bool cgfsng_create(void *hdata)
> +       offset = cgname + len - 5;
> +
> + again:
> +-      if (idx == 1000) {
> ++      if (idx == 999) {
> +               ERROR("Too many conflicting cgroup names");
> +               goto out_free;
> +       }
> +--
> +2.7.4
> +
> diff --git a/recipes-containers/lxc/lxc_2.0.8.bb b/recipes-containers/lxc/
> lxc_2.0.8.bb
> index 80c8da7..3dd9f63 100644
> --- a/recipes-containers/lxc/lxc_2.0.8.bb
> +++ b/recipes-containers/lxc/lxc_2.0.8.bb
> @@ -28,6 +28,7 @@ SRC_URI = "http://linuxcontainers.org/
> downloads/${BPN}-${PV}.tar.gz \
>         file://lxc-fix-B-S.patch \
>         file://lxc-doc-upgrade-to-use-docbook-3.1-DTD.patch \
>         file://logs-optionally-use-base-filenames-to-report-src-fil.patch
> \
> +       file://cgroups-work-around-issue-in-gcc-7.patch \
>         "
>
>  SRC_URI[md5sum] = "7bfd95280522d7936c0979dfea92cdb5"
> --
> 2.7.4
>
> --
> _______________________________________________
> meta-virtualization mailing list
> meta-virtualization at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/meta-virtualization
>



-- 
"Thou shalt not follow the NULL pointer, for chaos and madness await thee
at its end"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/meta-virtualization/attachments/20170619/10207b56/attachment.html>


More information about the meta-virtualization mailing list