Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 710272 - dev-db/mysql-connector-c-8.0.19 - ninja: FAILED: include/mysqld_error.h share/mysql-8.0/english/errmsg.sys
Summary: dev-db/mysql-connector-c-8.0.19 - ninja: FAILED: include/mysqld_error.h share...
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux MySQL bugs team
URL:
Whiteboard:
Keywords:
: 775845 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-02-20 06:52 UTC by Vasilis Lourdas
Modified: 2021-03-26 07:10 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,349.10 KB, text/plain)
2020-02-20 06:55 UTC, Vasilis Lourdas
Details
new build.log (build2.log,448.53 KB, text/x-log)
2020-03-27 13:55 UTC, Vasilis Lourdas
Details
find files output (output.txt,8.17 KB, text/plain)
2020-03-27 14:21 UTC, Vasilis Lourdas
Details
build3.log (build3.log,333.44 KB, text/x-log)
2020-03-27 14:41 UTC, Vasilis Lourdas
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vasilis Lourdas 2020-02-20 06:52:26 UTC
Portage 2.3.84 (python 3.6.9-final-0, default/linux/amd64/17.1/desktop/plasma/systemd, gcc-9.2.0, glibc-2.29-r7, 5.5.3-gentoo x86_64)
=================================================================
System uname: Linux-5.5.3-gentoo-x86_64-Intel-R-_Core-TM-_i5-8600_CPU_@_3.10GHz-with-gentoo-2.6
KiB Mem:    16264060 total,   7434800 free
KiB Swap:    8388600 total,   8388600 free
Timestamp of repository gentoo: Thu, 20 Feb 2020 05:30:01 +0000
Head commit of repository gentoo: be655cb34af29811e96fdb4f6e41a8cfe28f8a19
sh bash 4.4_p23-r1
ld GNU ld (Gentoo 2.32 p2) 2.32.0
app-shells/bash:          4.4_p23-r1::gentoo
dev-java/java-config:     2.2.0-r4::gentoo
dev-lang/perl:            5.30.1::gentoo
dev-lang/python:          2.7.17::gentoo, 3.6.9::gentoo, 3.7.5-r1::gentoo
dev-util/cmake:           3.14.6::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.6-r1::gentoo
sys-apps/sandbox:         2.13::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r4::gentoo
sys-devel/automake:       1.11.6-r3::gentoo, 1.15.1-r2::gentoo, 1.16.1-r1::gentoo
sys-devel/binutils:       2.32-r1::gentoo
sys-devel/gcc:            9.2.0-r2::gentoo
sys-devel/gcc-config:     2.2::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.2.1-r4::gentoo
sys-kernel/linux-headers: 4.19::gentoo (virtual/os-headers)
sys-libs/glibc:           2.29-r7::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    sync-rsync-verify-max-age: 24
    sync-rsync-extra-opts: 
    sync-rsync-verify-metamanifest: no
    sync-rsync-verify-jobs: 1

Local-overlay-Vasilis
    location: /usr/local/portage
    masters: gentoo
    priority: 0

jorgicio
    location: /var/lib/layman/jorgicio
    masters: gentoo
    priority: 50

stefantalpalaru
    location: /var/lib/layman/stefantalpalaru
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE @FREE bh-luxi Skype-TOS intel-ucode free-noncomm MSttfEULA vmware unRAR IUPAC-InChi MPEG-4 MagentaMgOpen CCPL-ShareAlike-1.0 skype-eula Google-TOS AdobeFlash-11.x Oracle-BCLA-JavaSE skype-4.0.0.7-copyright TeamViewer PUEL google-chrome OPERA-2014 RAR Vivaldi NVIDIA-r2 VIGRA as-is XMAME"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -mmmx -msse -msse2 -msse3 -mssse3 -mcx16 -msahf -mmovbe -maes -mpclmul -mpopcnt -mabm -mfma -mbmi -msgx -mbmi2 -mavx -mavx2 -msse4.2 -msse4.1 -mlzcnt -mrtm -mhle -mrdrnd -mf16c -mfsgsbase -mrdseed -mprfchw -madx -mfxsr -mxsave -mxsaveopt -mclflushopt -mxsavec -mxsaves --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=9216"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.6/ext-active/ /etc/php/apache2-php7.1/ext-active/ /etc/php/apache2-php7.2/ext-active/ /etc/php/apache2-php7.3/ext-active/ /etc/php/cgi-php5.6/ext-active/ /etc/php/cgi-php7.1/ext-active/ /etc/php/cgi-php7.2/ext-active/ /etc/php/cgi-php7.3/ext-active/ /etc/php/cli-php5.6/ext-active/ /etc/php/cli-php7.1/ext-active/ /etc/php/cli-php7.2/ext-active/ /etc/php/cli-php7.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/vmware-installer"
CXXFLAGS="-O2 -pipe -mmmx -msse -msse2 -msse3 -mssse3 -mcx16 -msahf -mmovbe -maes -mpclmul -mpopcnt -mabm -mfma -mbmi -msgx -mbmi2 -mavx -mavx2 -msse4.2 -msse4.1 -mlzcnt -mrtm -mhle -mrdrnd -mf16c -mfsgsbase -mrdseed -mprfchw -madx -mfxsr -mxsave -mxsaveopt -mclflushopt -mxsavec -mxsaves --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=9216"
DISTDIR="/usr/portage/distfiles"
ENV_UNSET="DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs candy cgroup config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://mirrors.evowise.com/gentoo/ https://mirrors.evowise.com/gentoo/ http://gentoo.wheel.sk/ http://mirror.dkm.cz/gentoo/ http://ftp.ntua.gr/pub/linux/gentoo/ http://mirror.netcologne.de/gentoo/ http://gentoo.mirror.web4u.cz/ http://ftp.romnet.org/gentoo/ http://ftp.linux.org.tr/gentoo/ http://tux.rainside.sk/gentoo/"
LDFLAGS="-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed"
LINGUAS="en en_GB en_US el"
MAKEOPTS="-j6"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="256-color X a52 aac acl acpi activities additions admin aio alsa amd64 apache2 apng archive argon2 asf bash-completion bcmath berkdb branding bzip2 bzlib cairo calendar caps cdr cgmanager cgroups charconv chm chromium cleartype_hinting cli contrast corefonts crypt cryptsetup css ctype cups cupsddk curl cxx dba dbus dcc_video declarative device-mapper dia dmi dri dri3 dts dvd dvdr dvdread ebook effects efi emboss encode epub exif expat extended extensions extras faac faad fam fastcgi fat fbcon ffmpeg fftw filecaps filter firefox3 flac fontconfig foomaticdb fpm freerdp ftp g3dvl gallium gd gdbm gif gimp gimpprint git glib glx gmp gnome-keyring gnomedb gocr gold gphoto2 gpm graphviz gs gstreamer gtk hddtemp hotpixels howl http2 hwaccel iconv icu id3tag imagemagick imap imlib innodb inotify intl ipv6 iso14755 jabber java java6 javascript jemalloc jpeg jpeg2k json kde kipi kwallet lame lcdfilter lcms leaps-timezone lensfun libass libkms libnotify libtirpc libwww lm-sensors lzma mad madwifi maildir mailwrapper maps matroska mdadm melt mime minizip mmap mmx mmxext motif mozbranding mozdevelop mozilla mozsvg mp3 mp4 mpeg mplayer mpm-worker multilib multiuser mysql mysqli mysqlnd ncurses newspr nlpsolver nls no-old-linux nodrm nomalloccheck nptl ntfs ntfsprogs nvidia objc offensive ofx ogg oldpim opcache opengl openmp openssl optimization oqgraph osmesa pam pango pcmcia pcntl pcre pdf pdfimport pdo pear pgo phonon php pie plasma plotutils pmu png policykit posix postgres postproc ppds pulseaudio python qml qt4 qt5 quicktime rar raw rdesktop rdoc readline redeyes reports romio rpc sasl scanner script sddm sdl seccomp server sha512 sharedext sharedmem simplexml smp sna sndfile soap sockets sodium sound speex spell sphinx split-usr spreadsheet sqlite sqlite3 srt sse sse2 sse3 sse4_1 ssl ssse3 startup-notification subtitles subversion svg symlink sysfs syslog systemd sysv-utils sysvipc tcltk tcpd templates tetex theora thin-splines threads tiff tokenizer tordns truetype tty-helpers udev udisks unicode upower urandom usb userlocales uuid v4l vda vdpau vhost-net video vmware-tools vmware-tools-linux vmware-tools-windows vncviewer vorbis vpx wddx webm webp widgets windeco wv wxgtk1 wxwidgets x264 x265 xcb xcomposite xetex xft xml xmlreader xmlrpc xmlwriter xmp xorg xpdf-headers xpm xprint xscreensaver xsl xslt xv xvfb xvid xvnc zip zlib" ABI_X86="64" ADA_TARGET="gnat_2018" ALSA_CARDS="hda-intel" APACHE2_MODULES="alias auth_basic authn_core authn_dbm authn_file authz_core authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cgid deflate dir env expires filter headers http2 log_config logio mime mime_magic negotiation proxy proxy_fcgi rewrite setenvif socache_shmcb unixd userdir" APACHE2_MPMS="event" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 f16c fma3 mmx mmxext pclmul popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" ENLIGHTENMENT_MODULES="appmenu backlight battery clock comp conf conf-applications conf-dialogs conf-display conf-edgebindings conf-interaction conf-intl conf-keybindings conf-menus conf-paths conf-performance conf-randr conf-shelves conf-theme conf-window-manipulation conf-window-remembers cpufreq dropshadow everything fileman fileman-opinfo gadman ibar ibox illume2 mixer msgbus notification pager quickaccess start syscon systray tasks temperature tiling winlist wizard xkbswitch" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" L10N="en el" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-minimizer nlpsolver" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-2 php7-3" POSTGRES_TARGETS="postgres9_6" PYTHON_SINGLE_TARGET="python3_6" PYTHON_TARGETS="python2_7 python3_6 python3_7" RUBY_TARGETS="ruby24 ruby25" SANE_BACKENDS="snapscan" USERLAND="GNU" VIDEO_CARDS="intel i965" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

[213/250] : && /usr/bin/x86_64-pc-linux-gnu-g++ -m32  -O2 -pipe -mmmx -msse -msse2 -msse3 -mssse3 -mcx16 -msahf -mmovbe -maes -mpclmul -mpopcnt -mabm -mfma -mbmi -msgx -mbmi2 -mavx -mavx2 -msse4.2 -msse4.1 -mlzcnt -mrtm -mhle -mrdrnd -mf16c -mfsgsbase -mrdseed -mprfchw -madx -mfxsr -mxsave -mxsaveopt -mclflushopt -mxsavec -mxsaves --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=9216 -Wall -Wextra -Wformat-security -Wvla -Wundef -Woverloaded-virtual -Wcast-qual -Wimplicit-fallthrough=2 -Wstringop-truncation -Wlogical-op  -fuse-ld=lld -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed utilities/CMakeFiles/comp_err.dir/comp_err.cc.o  -o runtime_output_directory/comp_err  -lpthread archive_output_directory/libmysys.a archive_output_directory/libmytime.a archive_output_directory/libstrings.a /usr/lib/libz.so archive_output_directory/libzstd.a -lpthread -lm -lrt /usr/lib/libssl.so /usr/lib/libcrypto.so -ldl && :
[214/250] cd /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/utilities && /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/runtime_output_directory/comp_err --charset=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/charsets --out-dir=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/share/mysql-8.0/ --header_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_error.h --name_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_ername.h --errmsg_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_errmsg.h --in_file_errlog=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_error_log.txt --in_file_toclient=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_clients.txt
FAILED: include/mysqld_error.h share/mysql-8.0/english/errmsg.sys 
cd /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/utilities && /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/runtime_output_directory/comp_err --charset=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/charsets --out-dir=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/share/mysql-8.0/ --header_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_error.h --name_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_ername.h --errmsg_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_errmsg.h --in_file_errlog=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_error_log.txt --in_file_toclient=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_clients.txt
ninja: build stopped: subcommand failed.
 * ERROR: dev-db/mysql-connector-c-8.0.19::gentoo failed (compile phase):
 *   ninja -v -j6 -l0 failed
 * 
 * Call stack:
 *     ebuild.sh, line  125:  Called src_compile
 *   environment, line 2576:  Called cmake-multilib_src_compile
 *   environment, line  759:  Called multilib-minimal_src_compile
 *   environment, line 1901:  Called multilib_foreach_abi 'multilib-minimal_abi_src_compile'
 *   environment, line 2145:  Called multibuild_foreach_variant '_multilib_multibuild_wrapper' 'multilib-minimal_abi_src_compile'
 *   environment, line 1836:  Called _multibuild_run '_multilib_multibuild_wrapper' 'multilib-minimal_abi_src_compile'
 *   environment, line 1834:  Called _multilib_multibuild_wrapper 'multilib-minimal_abi_src_compile'
 *   environment, line  627:  Called multilib-minimal_abi_src_compile
 *   environment, line 1895:  Called multilib_src_compile
 *   environment, line 2365:  Called cmake-utils_src_compile
 *   environment, line  779:  Called cmake-utils_src_make
 *   environment, line  960:  Called _cmake_ninja_src_make
 *   environment, line  473:  Called eninja
 *   environment, line 1265:  Called die
 * The specific snippet of code:
 *       "$@" || die "${nonfatal_args[@]}" "${*} failed"
 * 
 * If you need support, post the output of `emerge --info '=dev-db/mysql-connector-c-8.0.19::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=dev-db/mysql-connector-c-8.0.19::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/temp/environment'.
 * Working directory: '/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86'
 * S: '/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19'

>>> Failed to emerge dev-db/mysql-connector-c-8.0.19, Log file:
Comment 1 Vasilis Lourdas 2020-02-20 06:55:48 UTC
Created attachment 614600 [details]
build.log

Full build.log
Comment 2 Vasilis Lourdas 2020-03-27 08:35:37 UTC
Anyone on this? It's been open for more than a month now.
Comment 3 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 11:24:54 UTC
(In reply to Vasilis Lourdas from comment #2)
> Anyone on this? It's been open for more than a month now.
Nobody I am aware of.

I can't reproduce and haven't seen this before.

Maybe try checking if you have another comp_err on your system which gets into the way and will produce somehow invalid localizations.
Comment 4 Vasilis Lourdas 2020-03-27 11:40:43 UTC
(In reply to Thomas Deutschmann from comment #3)
> (In reply to Vasilis Lourdas from comment #2)
> > Anyone on this? It's been open for more than a month now.
> Nobody I am aware of.
> 
> I can't reproduce and haven't seen this before.
> 
> Maybe try checking if you have another comp_err on your system which gets
> into the way and will produce somehow invalid localizations.

What more information can I provide to help in this direction?
Comment 5 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 11:44:35 UTC
Search your PATH for comp_err, if you find something, maybe from dev-db/mysql, temporarily rename that file and see if it makes any difference.

Also try building with MAKEOPTS=-j1 just in case...
Comment 6 Vasilis Lourdas 2020-03-27 11:54:44 UTC
(In reply to Thomas Deutschmann from comment #5)
> Search your PATH for comp_err, if you find something, maybe from
> dev-db/mysql, temporarily rename that file and see if it makes any
> difference.

No files found with that name.

> Also try building with MAKEOPTS=-j1 just in case...

I did that and still the same error.

I don't have dev-db/mysql installed, but dev-db/mariadb instead. I also have dev-db/mariadb-connector-c installed.
Comment 7 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 12:23:00 UTC
Still unable to reproduce with mariadb-connector-c and mariadb installed. Try doing

> [214/250] cd /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/utilities && /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/runtime_output_directory/comp_err --charset=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/charsets --out-dir=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/share/mysql-8.0/ --header_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_error.h --name_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_ername.h --errmsg_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_errmsg.h --in_file_errlog=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_error_log.txt --in_file_toclient=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_clients.txt

manually. I.e. become portage user, and try to manually run these commands to check if you can reproduce. If you can reproduce, start debugging. Maybe you will find the reason why this is failing.
Comment 8 Vasilis Lourdas 2020-03-27 12:33:08 UTC
(In reply to Thomas Deutschmann from comment #7)
> Still unable to reproduce with mariadb-connector-c and mariadb installed.
> Try doing
> 
> > [214/250] cd /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/utilities && /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/runtime_output_directory/comp_err --charset=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/charsets --out-dir=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/share/mysql-8.0/ --header_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_error.h --name_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_ername.h --errmsg_file=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_errmsg.h --in_file_errlog=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_error_log.txt --in_file_toclient=/var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19/share/messages_to_clients.txt
> 
> manually. I.e. become portage user, and try to manually run these commands
> to check if you can reproduce. If you can reproduce, start debugging. Maybe
> you will find the reason why this is failing.

The command did not produce any output, so I guess it succeeded. All files in the command parameters exist...
Comment 9 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 13:02:16 UTC
Re-run the emerge command. When it failed, check that

> /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_error.h
and
> /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_64.amd64/share/mysql-8.0/english/errmsg.sys
exists. The generated errmsg.sys is a binary file but it should contain a lot of readable English text, things like

> Version: '%s'  socket: '%s'  port: %d.%s: Normal shutdown
> .%s: Got signal %d. Aborting!
> .%s: Shutdown complete

Maybe you see anything suspicious.

But I am running out of ideas. If you aren't in the middle of a toolchain upgrade (upgraded GCC/glibc and haven't rebooted yet), I have no further ideas.
Comment 10 Vasilis Lourdas 2020-03-27 13:09:34 UTC
(In reply to Thomas Deutschmann from comment #9)
> Re-run the emerge command. When it failed, check that
> 
> > /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_error.h
> and
> > /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_64.amd64/share/mysql-8.0/english/errmsg.sys
> exists. The generated errmsg.sys is a binary file but it should contain a
> lot of readable English text, things like
> 
> > Version: '%s'  socket: '%s'  port: %d.%s: Normal shutdown
> > .%s: Got signal %d. Aborting!
> > .%s: Shutdown complete
> 
> Maybe you see anything suspicious.
> 
> But I am running out of ideas. If you aren't in the middle of a toolchain
> upgrade (upgraded GCC/glibc and haven't rebooted yet), I have no further
> ideas.

No, when the build fails, /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_32.x86/include/mysqld_error.h and /var/tmp/portage/dev-db/mysql-connector-c-8.0.19/work/mysql-8.0.19-abi_x86_64.amd64/share/mysql-8.0/english/errmsg.sys do not exist.

Could this somehow be related to my CFLAGS? You can see my CFLAGS variable in the first message.
Comment 11 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 13:46:36 UTC
Wait: When the build failed, these files don't exist? But you are able to run the command from comment #7? That should be impossible..

The missing header file should be generated a few steps before that comp_err call..

Regarding your CFLAGS: Well, you have crazy CFLAGS, I hope you know what you are doing. I was unable to reproduce your problem with these flag. That said, it's still possible that these flags causing problems in dependencies, assuming you have built everything with these flags...

Last idea, try 

> CMAKE_MAKEFILE_GENERATOR=emake emerge -a1 dev-db/mysql-connector-c

to rule out any problem caused by ninja.
Comment 12 Vasilis Lourdas 2020-03-27 13:55:08 UTC
Created attachment 626408 [details]
new build.log

New build log, with the CMAKE_MAKEFILE_GENERATOR=emake emerge -a1 dev-db/mysql-connector-c command
Comment 13 Vasilis Lourdas 2020-03-27 14:21:27 UTC
Created attachment 626410 [details]
find files output

(In reply to Thomas Deutschmann from comment #11)
> Wait: When the build failed, these files don't exist? But you are able to
> run the command from comment #7? That should be impossible..

Check the attached terminal log. Watch the build failure, my find commands and after running the command in 214.
Comment 14 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 14:32:03 UTC
Please disable 32bit ABI and just try to build for your native ABI.
Comment 15 Vasilis Lourdas 2020-03-27 14:41:49 UTC
Created attachment 626412 [details]
build3.log

(In reply to Thomas Deutschmann from comment #14)
> Please disable 32bit ABI and just try to build for your native ABI.

I did that, attached new build.log.
Comment 16 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 19:07:30 UTC
This time it's comp_client_err failing for "include/mysqlclient_ername.h".

Enabling debugging (https://wiki.gentoo.org/wiki/Debugging) for this package through /etc/portage/env & etc/pportage/packages.env. Allow for core dump creation (mkdir /var/tmp/coredumps && chmod 1777 /var/tmp/coredumps && sysctl -w kernel.core_pattern="/var/tmp/coredumps/%e.%p.%t" && ulimit -c unlimited). From that terminal run emerge with CMAKE_MAKEFILE_GENERATOR=emake set but just for native ABI to avoid any multilib complications. It should crash again and this time you will hopefully have a core dump you can analyze with gdb which will give us a clue what's going on. You maybe need to re-install toolchain with debug symbols first to get a meaningful back trace.
Comment 17 Vasilis Lourdas 2020-03-27 21:08:39 UTC
(In reply to Thomas Deutschmann from comment #16)
> This time it's comp_client_err failing for "include/mysqlclient_ername.h".
> 
> Enabling debugging (https://wiki.gentoo.org/wiki/Debugging) for this package
> through /etc/portage/env & etc/pportage/packages.env. Allow for core dump
> creation (mkdir /var/tmp/coredumps && chmod 1777 /var/tmp/coredumps &&
> sysctl -w kernel.core_pattern="/var/tmp/coredumps/%e.%p.%t" && ulimit -c
> unlimited). From that terminal run emerge with
> CMAKE_MAKEFILE_GENERATOR=emake set but just for native ABI to avoid any
> multilib complications. It should crash again and this time you will
> hopefully have a core dump you can analyze with gdb which will give us a
> clue what's going on. You maybe need to re-install toolchain with debug
> symbols first to get a meaningful back trace.

I tried them, but I have no debugging symbols. I guess I'll have to recompile gcc, etc. with debug info.

What I forgot to mention is that the problem exists in my other two machines. The first machine is a i5 8600 (the one I'm writing now and tried all these hacks), the second one is a i5 4590 and the third one is a laptop with i5 7200U. In all three I cannot get mysql-connector-c to build with the same error. If this were a coincidence, I'd better buy a lottery ticket.
Comment 18 Thomas Deutschmann (RETIRED) gentoo-dev 2020-03-27 22:34:52 UTC
(In reply to Vasilis Lourdas from comment #17)
> What I forgot to mention is that the problem exists in my other two
> machines.
Assuming you set them up the same way I am not surprised that you hit this error on all your systems. But try testing a stage3, it will work:

> # Setup Gentoo chroot using stage3
> cd /tmp
> mkdir /tmp/gentoo
> wget http://distfiles.gentoo.org/releases/amd64/autobuilds/20200325T214502Z/stage3-amd64-20200325T214502Z.tar.xz
> tar -xaf stage3-amd64-*.tar.xz -C /tmp/gentoo
> mount -t proc /proc gentoo/proc
> mount --rbind /sys gentoo/sys
> mount --make-rslave gentoo/sys
> mount --rbind /dev gentoo/dev
> mount --make-rslave gentoo/dev
> 
> # Chroot into Gentoo
> env -i HOME=/root TERM=$TERM $(which chroot) /tmp/gentoo /bin/bash --login
> 
> # In Gentoo chroot...
> export PS1="(chroot) $PS1"
> 
> # Make sure name resolution works...
> echo 'nameserver 8.8.8.8' > /etc/resolv.conf
> 
> # Get latest daily portage snapshot
> emerge-webrsync
> 
# emerge -a '>=dev-db/mysql-connector-c-8'
Comment 19 Vasilis Lourdas 2020-03-31 18:32:48 UTC
Luckily another fellow forum user found the solution by comparing his and mine build logs. It turns out that sys-devel/lld was at fault. After removing the package, mysql-connector-c built fine.
Comment 20 Martin Kostolný 2020-04-01 21:09:30 UTC
Hi! Finding source of the issue is certainly a step forward, thanks!

Although this shouldn't be the final solution since lld is required for example by firefox and rust packages. I'm also hit by this issue btw. Is there any way we can instruct mysql-connector-c package compilation not to use lld? Or is it possible to fix the ebuild that way?
Comment 21 Thomas Deutschmann (RETIRED) gentoo-dev 2020-04-01 21:55:38 UTC
gcc is the default compiler. Packages like www-client/firefox will allow you to switch via USE flag but normally you do this via package.env.

I just tried to compile in clean stage3 with lld sitting around. I was unable to reproduce. That means there is no automagic on lld. If you changed your default compiler to clang, you are on your own.

Sure, this package supports "-DUSE_LD_LLD=OFF" but I don't want to block you or anyone else from shooting yourself in the foot. If you want to switch default compiler, that's what you have to deal with. Adding something like

> if tc-is-clang; then
>   mycmakeargs+=( -DUSE_LD_LLD=OFF )
> fi

looks wrong for me.
Comment 22 Pavel Procopiuc 2020-05-04 07:40:10 UTC
I'm experiencing this problem too and my default compiler is still gcc. Building without lld installed fixes the issue. I've compared the cmake output when building with and without lld present and it looks like mysql-connector-c prefers lld to other linkers even when building with gcc. Here are the relevant log lines:

With lld:
...
-- Performing Test C_LD_LLD_RESULT
-- Performing Test C_LD_LLD_RESULT - Success
-- Performing Test CXX_LD_LLD_RESULT
-- Performing Test CXX_LD_LLD_RESULT - Success
...
-- CMAKE_C_LINK_FLAGS:  -fuse-ld=lld
-- CMAKE_CXX_LINK_FLAGS:  -fuse-ld=lld
...

Without lld:
...
-- Performing Test C_LD_LLD_RESULT
-- Performing Test C_LD_LLD_RESULT - Failed
-- Performing Test CXX_LD_LLD_RESULT
-- Performing Test CXX_LD_LLD_RESULT - Failed
-- Performing Test C_LD_GOLD_RESULT
-- Performing Test C_LD_GOLD_RESULT - Success
-- Performing Test CXX_LD_GOLD_RESULT
-- Performing Test CXX_LD_GOLD_RESULT - Success
...
-- CMAKE_C_LINK_FLAGS:  -fuse-ld=gold -Wl,--gc-sections
-- CMAKE_CXX_LINK_FLAGS:  -fuse-ld=gold -Wl,--gc-sections
...
Comment 23 Thomas Deutschmann (RETIRED) gentoo-dev 2020-05-04 10:09:13 UTC
Sure there is some kind of automagic (https://github.com/mysql/mysql-server/blob/mysql-8.0.20/CMakeLists.txt#L803-L841) but I am unable to reproduce any *problem* even on systems where lld, ld.gold... is present.

So in my case, builds with -fuse-ld=gold will succeed like builds with -fuse-ld=lld.

If you can tell me what I need to do to reproduce this in a clean stage3, see comment #18, we maybe able to do something but until then it looks like something is 'broken' (different) on your system causing this.
Comment 24 Kai Krakow 2020-12-06 10:14:35 UTC
I can confirm this issue for version 8.0.22: The build log confirms it's using ld.gold even tho I didn't enable the gold linker by default. I'm now trying with USE="-gold" globally.

I'm not sure why it did work for me in previous versions but looking at other problems with gold, compile failures seem to randomly pop up in multiple packages even when it was not directly linked with gold but one of the depends was.

If I don't report back, please assume that using USE="-gold" fixed the issue for me.
Comment 25 Kai Krakow 2020-12-06 12:50:21 UTC
Works when binutils is compiled with USE="-gold".
Comment 26 Thomas Deutschmann (RETIRED) gentoo-dev 2021-03-23 10:36:47 UTC
*** Bug 775845 has been marked as a duplicate of this bug. ***
Comment 27 Ben 2021-03-26 07:10:34 UTC
Ran into this problem on x86 in normal emerge -u @world

sys-devel/binutils is USE="gold nls plugins"

Was ultimately able to build dev-db/mysql-connector-c-8.0.23-r1 with FEATURES=-distcc.  Seems to not be a very stable ninja?