Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#55577 - [lxc] unable to build in a clean chroot

Attached to Project: Community Packages
Opened by John (graysky) - Sunday, 10 September 2017, 17:36 GMT
Last edited by Doug Newgard (Scimmia) - Sunday, 05 November 2017, 19:16 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Sergej Pupykin (sergej)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

I am unable to build in a freshly created clean chroot. Can others confirm? The key error seems to be:
...
storage/overlay.c: In function ‘ovl_mkdir’:
storage/overlay.c:808:13: error: ‘dirlen’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
else if (!strncmp(workdir, lxcpath, dirlen) &&
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
mv -f storage/.deps/liblxc_la-btrfs.Tpo storage/.deps/liblxc_la-btrfs.Plo

Build log attached.

Additional info:
* package version(s) 1:2.1.0-1

Steps to reproduce:
1) Create a new clean chroot
2) Attempt to build.
   build.log (171.2 KiB)
This task depends upon

Closed by  Doug Newgard (Scimmia)
Sunday, 05 November 2017, 19:16 GMT
Reason for closing:  Fixed
Additional comments about closing:  lxc 1:2.1.0-2
Comment by Eli Schwartz (eschwartz) - Sunday, 10 September 2017, 17:40 GMT
  • Field changed: Status (Unconfirmed → Assigned)
  • Field changed: Severity (High → Low)
  • Task assigned to Sergej Pupykin (sergej)
Why do they use -Werror outside of a development environment? :(
Comment by John (graysky) - Sunday, 10 September 2017, 19:16 GMT
One of the upstream developers fixed this in the following patch which also fixes another bug relating to lxc-copy so it might be worth merging and bumping until upstream releases 2.1.1 or whatever bugfix version is likely: https://github.com/brauner/lxc/commit/180c477a326ce85632249ff16990e8c29db1b6fa

Attached is a patch for the PKGBUILD that incorporates the fix.
Comment by John (graysky) - Sunday, 10 September 2017, 19:48 GMT
Should have added to my previous comment that not only does that patch fix the build issue, it also addresses a critical bug introduced with the 2.1.0 release that is relating to the use of lxc-copy for snapshots. Two reasons to consider inclusion ahead of 2.1.1. Link to bug I referenced: https://github.com/lxc/lxc/issues/1802
Comment by Eli Schwartz (eschwartz) - Sunday, 10 September 2017, 20:02 GMT
Does it fix a second bug in addition to the one that you did in fact mention?
Comment by John (graysky) - Sunday, 10 September 2017, 22:37 GMT
@Eli - Yes, both the coredump in lxc-copy and the inability to build using our latest toolchain.
Comment by John (graysky) - Monday, 11 September 2017, 19:03 GMT
@sergej - Since the configure flags have changes in this release, do you feel it is important enough to mention in an post_install message or an Arch News item that existing configs will need to be updated by-hand in order to work in many cases? I updated the wiki, but perhaps that isn't enough. We have seen at least one forum post on this topic. Thoughts?

Here is what I put in the pre_upgrade of lxc-snapshots in the AUR:

pre_upgrade() {
# version 1.10 expects changes to container config due to upstream flags
if [ $(vercmp $2 1.10) -lt 0 ]; then
echo '-> LXC made changes to the internal configuration keys with v2.1.'
echo '-> You MUST update the flags in your base container, see:'
echo '-> https://discuss.linuxcontainers.org/t/lxc-2-1-has-been-released/487';
fi
}
Comment by John (graysky) - Thursday, 14 September 2017, 22:42 GMT
@sergej and @eschwartz - I saw upstream's comments about the larger issue surrounding -Werror, but currently, without this patch, one cannot build lxc at all. What are your thoughts about including it and bumping to 1:2.1.0-2?

Loading...