[build2] build2 0.9.0 bootstrap build failure

Matthew Krupcale mkrupcale at matthewkrupcale.com
Fri Feb 22 02:23:48 UTC 2019


Hello,

I'm glad to see the latest release of build2. I've started building it
on Fedora[1], and during the final boostrap build of build2 (phase 3
with shared libraries), the configure step fails with output `save
build/config.build`[2] and an assertion due to a std::optional value
not being set and accessed[3]. The line of issue appears to be
libbutl/diagnostics.cxx:137 inside ~diag_stream_lock where diag_term
is accessed but is empty:

(gdb) p    diag_term
$1 = std::optional<bool> [no contained value]

This doesn't appear to be related to the save operation as far as I
can tell because if I use higher verbosity on the command, the same
std::optional access SIGABRT happens immediately after whatever the
first line of terminal diagnostic output is:

<mock-chroot> sh-4.4# build2/b-boot --verbose 6 configure
config.bin.lib=shared config.cxx=g++ 'config.cxx.coptions=-O2 -g -pipe
-Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2
-Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong
-grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
-specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic
-fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection'
'config.cxx.loptions=-Wl,-z,relro   -Wl,-z,now
-specs=/usr/lib/rpm/redhat/redhat-hardened-ld'
config.install.root=/usr config.install.exec_root=/usr
config.install.bin=/usr/bin config.install.sbin=/usr/sbin
config.install.include=/usr/include config.install.lib=/usr/lib64
config.install.man=/usr/share/man
config.install.pkgconfig=/usr/lib64/pkgconfig
config.install.bin.mode=755 config.install.sbin.mode=755
config.install.lib.mode=755
config.install.chroot=/builddir/build/BUILDROOT/build2-0.9.0-1.fc29.x86_64
trace: main: work: /builddir/build/BUILD/build2-toolchain-0.9.0/build2-0.9.0/
/usr/include/c++/8/optional:945: constexpr _Tp&
std::_Optional_base<_Tp, true, true>::_M_get() [with _Tp = bool]:
Assertion 'this->_M_is_engaged()' failed.
Aborted (core dumped)

I'm not entirely sure what the issue here is because it looks like the
libbutl/diagnostics.{c,m}xx files haven't been touched in a while, and
the 0.8.0 builds didn't fail in this way. Any thoughts on what might
be happening? Let me know if I can provide additional information
here.

Best,
Matthew

[1] https://copr.fedorainfracloud.org/coprs/mkrupcale/build2/build/861229/
[2] https://copr-be.cloud.fedoraproject.org/results/mkrupcale/build2/fedora-29-x86_64/00861229-build2/build.log.gz
[3] https://paste.fedoraproject.org/paste/1AqVTYzXhQZUATJSJVERNQ



More information about the users mailing list