Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 930058 - Unable to compile qtlocation
Summary: Unable to compile qtlocation
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-04-15 08:39 UTC by manu
Modified: 2024-04-16 15:24 UTC (History)
3 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description manu 2024-04-15 08:39:49 UTC
Unable to compile qtlocation

Hi,

I've recently moved to LLVM in my laptop and everything went pretty smooth...except por qtlocation, which I'm not able to compile neither with gcc


g++ -c -O2 -pipe -march=native -floop-interchange -floop-strip-mine -floop-block -ftree-loop-distribution -O3 -std=c++1z -fvisibility=hidden -fvisibility-inlines-hidden -fno-exceptions -Wall -Wextra -Wdate-time -Winconsistent-missing-override -D_REENTRANT -fPIC -DQT_NO_LINKED_LIST -DQT_NO_JAVA_STYLE_ITERATORS -DQT_NO_LINKED_LIST -DQT_NO_NARROWING_CONVERSIONS_IN_CONNECT -DQT_BUILD_LOCATION_LIB -DQT_BUILDING_QT -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER -DQT_DEPRECATED_WARNINGS -DQT_DISABLE_DEPRECATED_BEFORE=0x050000 -DQT_DEPRECATED_WARNINGS_SINCE=0x060000 -DQT_NO_EXCEPTIONS -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -DQT_NO_DEBUG -DQT_POSITIONINGQUICK_LIB -DQT_POSITIONING_LIB -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QMLMODELS_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/location -I. -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/3rdparty/earcut -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/3rdparty/poly2tri -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/3rdparty/clipper -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/3rdparty/clip2tri -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/positioning -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/imports/positioning -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/location -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/location/maps -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/location/places -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/location/declarativemaps -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/location/declarativeplaces -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/include -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/include/QtLocation -I../../include -I../../include/QtLocation -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/include/QtLocation/5.15.13 -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/include/QtLocation/5.15.13/QtLocation -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13_build/include/QtLocation/5.15.13 -I/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13_build/include/QtLocation/5.15.13/QtLocation -I/usr/include/qt5/QtPositioningQuick/5.15.13 -I/usr/include/qt5/QtPositioningQuick/5.15.13/QtPositioningQuick -I/usr/include/qt5/QtPositioning/5.15.13 -I/usr/include/qt5/QtPositioning/5.15.13/QtPositioning -I/usr/include/qt5/QtQuick/5.15.13 -I/usr/include/qt5/QtQuick/5.15.13/QtQuick -I/usr/include/qt5/QtGui/5.15.13 -I/usr/include/qt5/QtGui/5.15.13/QtGui -I/usr/include/qt5/QtQmlModels/5.15.13 -I/usr/include/qt5/QtQmlModels/5.15.13/QtQmlModels -I/usr/include/qt5/QtQml/5.15.13 -I/usr/include/qt5/QtQml/5.15.13/QtQml -I/usr/include/qt5/QtCore/5.15.13 -I/usr/include/qt5/QtCore/5.15.13/QtCore -I/usr/include/qt5 -I/usr/include/qt5/QtPositioningQuick -I/usr/include/qt5/QtPositioning -I/usr/include/qt5/QtQuick -I/usr/include/qt5/QtGui -I/usr/include/qt5/QtQmlModels -I/usr/include/qt5/QtQml -I/usr/include/qt5/QtNetwork -I/usr/include/qt5/QtCore -I.moc -I/usr/lib64/qt5/mkspecs/linux-clang -o .obj/qlocation.o /var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/location/qlocation.cpp
g++: error: unrecognized command-line option ‘-Winconsistent-missing-override’
make: *** [Makefile:4110: .obj/qlocation.o] Error 1

and more like this when it's crashing

nor clang

In file included from /var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/3rdparty/mapbox-gl-native/deps/boost/1.65.1/include/boost/mpl/integral_c.hpp:32:
/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/3rdparty/mapbox-gl-native/deps/boost/1.65.1/include/boost/mpl/aux_/integral_wrapper.hpp:73:31: error: integer value -1 is outside the valid range of values [0, 3] for the enumeration type 'udt_builtin_mixture_enum' [-Wenum-constexpr-conversion]
   73 |     typedef AUX_WRAPPER_INST( BOOST_MPL_AUX_STATIC_CAST(AUX_WRAPPER_VALUE_TYPE, (value - 1)) ) prior;
      |                               ^
/var/tmp/portage/dev-qt/qtlocation-5.15.13/work/qtlocation-everywhere-src-5.15.13/src/3rdparty/mapbox-gl-native/deps/boost/1.65.1/include/boost/mpl/aux_/static_cast.hpp:24:47: note: expanded from macro 'BOOST_MPL_AUX_STATIC_CAST'
   24 | #   define BOOST_MPL_AUX_STATIC_CAST(T, expr) static_cast<T>(expr)
      |          

and more like this.

I read somewhere that other packages compiled with gcc might be an issue. I did

emerge --emptytree kate

to enforce that most (all?) Qt stuff was recompiled with clang.

Any clue?


====================

Portage 3.0.61 (python 3.11.8-final-0, default/linux/amd64/23.0/desktop/plasma/systemd, gcc-13, glibc-2.38-r10, 6.6.21-gentoo x86_64)
=================================================================
System uname: Linux-6.6.21-gentoo-x86_64-AMD_Ryzen_7_5700U_with_Radeon_Graphics-with-glibc2.38
KiB Mem:    15667232 total,   9254336 free
KiB Swap:   16383996 total,  16086012 free
Timestamp of repository gentoo: Thu, 11 Apr 2024 15:00:00 +0000
Head commit of repository gentoo: 4297f482d5da54c368798b41df7fa296558c0153
Timestamp of repository amano-kenji: Mon, 08 Apr 2024 13:03:20 +0000
Head commit of repository amano-kenji: 6aaf145a02e060e5d54e3c45343d5283342fa480

Timestamp of repository guru: Thu, 11 Apr 2024 11:18:10 +0000
Head commit of repository guru: d40f125ce399073121d29b80cad25183fcc1820c

Timestamp of repository lab-overlay: Mon, 01 Apr 2024 09:52:58 +0000
Head commit of repository lab-overlay: 9fd94032edc5124bd82d521e8b6df9f196960938

Timestamp of repository steam-overlay: Thu, 04 Apr 2024 01:22:27 +0000
Head commit of repository steam-overlay: aca6eb772e0d5474b6d44072998af0082f36d08a

Head commit of repository qq-gentoo: c454eeeb65beb21f8e96c53f0a39b87958286abd

sh bash 5.1_p16-r6
ld GNU ld (Gentoo 2.41 p5) 2.41.0
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.1_p16-r6::gentoo
dev-build/autoconf:        2.13-r8::gentoo, 2.71-r6::gentoo
dev-build/automake:        1.16.5-r2::gentoo
dev-build/cmake:           3.28.3::gentoo
dev-build/libtool:         2.4.7-r4::gentoo
dev-build/make:            4.4.1-r1::gentoo
dev-build/meson:           1.3.2::gentoo
dev-java/java-config:      2.3.3-r1::gentoo
dev-lang/perl:             5.38.2-r2::gentoo
dev-lang/python:           3.11.8_p1::gentoo, 3.12.2_p1::gentoo
dev-lang/rust-bin:         1.75.0::gentoo
sys-apps/baselayout:       2.14-r2::gentoo
sys-apps/sandbox:          2.38::gentoo
sys-apps/systemd:          255.3-r1::gentoo
sys-devel/binutils:        2.41-r5::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           17.0.6::gentoo
sys-devel/gcc:             13.2.1_p20240210::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/lld:             17.0.6::gentoo
sys-devel/llvm:            17.0.6::gentoo
sys-kernel/linux-headers:  6.6-r1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.38-r10::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    volatile: False
    sync-rsync-verify-jobs: 1
    sync-rsync-extra-opts: 
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-max-age: 3

amano-kenji
    location: /var/db/repos/amano-kenji
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/amano-kenji.git
    masters: gentoo
    volatile: False

guru
    location: /var/db/repos/guru
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/guru.git
    masters: gentoo
    volatile: False

lab-overlay
    location: /var/db/repos/lab-overlay
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/lab-overlay.git
    masters: gentoo
    volatile: False

local
    location: /var/db/repos/local
    masters: gentoo
    volatile: False

steam-overlay
    location: /var/db/repos/steam-overlay
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/steam-overlay.git
    masters: gentoo
    volatile: False

qq-gentoo
    location: /var/db/repos/qq-gentoo
    sync-type: git
    sync-uri: https://gitlab.com/quilosaq/qq-gentoo.git
    masters: gentoo
    priority: 40
    volatile: False

Binary Repositories:

binhost
    priority: 9999
    sync-uri: https://distfiles.gentoo.org/releases/amd64/binpackages/23.0/x86-64

Installed sets: @esteam
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="@FREE"
AR="llvm-ar"
CBUILD="x86_64-pc-linux-gnu"
CC="clang"
CFLAGS="-O2 -march=native"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /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/revdep-rebuild /etc/sandbox.d /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CPP="clang-cpp"
CXX="clang++"
CXXFLAGS="-O2 -march=native"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-O2 -march=native"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox pkgdir-index-trusted preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -march=native"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="es_ES.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs"
LEX="flex"
LINGUAS="es es_ES"
NM="llvm-nm"
PKGDIR="/var/cache/binpkgs"
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"
RANLIB="llvm-ranlib"
SHELL="/bin/bash"
USE="X a52 aac acl acpi activities alsa amd64 bash-completion bluetooth branding bzip2 cairo cdda cdr cet corefonts crypt cups dbus declarative dri dts dvd dvdr dvi encode eps exif flac gdbm gif google gpm gtk gui homed iconv icu ipv6 jpeg kde kwallet latex lcms libnotify libtirpc luks mad markdown mng mp3 mp4 mpeg mtp multilib ncurses networkmanager nftables nls ogg opengl openmp pam pango pcre pdf pipewire plasma png policykit ppds pulseaudio qml qt5 readline screencast sdl seccomp semantic-desktop sound spell ssl startup-notification svg systemd test-rust tiff truetype udev udisks unicode upower usb vorbis vulkan wayland widgets wxwidgets x264 xattr xcb xft xml xv xvid zlib" ABI_X86="64" ADA_TARGET="gcc_12" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_anon authn_dbm authn_file authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir env expires ext_filter file_cache filter headers include info log_config logio mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 ntrip navcom oceanserver oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 tsip tripmate tnt ublox" INPUT_DEVICES="synaptics libinput" KERNEL="linux" L10N="es es-ES es_ES" LCD_DEVICES="bayrad cfontz glk hd44780 lb216 lcdm001 mtxorb text" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-1" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11" RUBY_TARGETS="ruby31" SANE_BACKENDS="epson2 epkowa" VIDEO_CARDS="amdgpu radeon radeonsi" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipp2p iface geoip fuzzy condition tarpit sysrq proto logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, ARFLAGS, AS, ASFLAGS, CCLD, CONFIG_SHELL, CPPFLAGS, CTARGET, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, MAKEOPTS, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PYTHONPATH, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 1 Alfred Wingate 2024-04-15 10:24:00 UTC
Please include the build.log in full (compressed if necessary).
Comment 2 Alfred Wingate 2024-04-15 10:26:04 UTC
LLVM build error is https://bugs.gentoo.org/895516

GCC build error looks like qt build trying to add clang options, possibly due to qtcore being built with clang.
Comment 3 Ionen Wolkens gentoo-dev 2024-04-15 12:03:50 UTC
(In reply to Alfred Wingate from comment #2)
> LLVM build error is https://bugs.gentoo.org/895516
> 
> GCC build error looks like qt build trying to add clang options, possibly
> due to qtcore being built with clang.
Yes, qtcore and all packages using its qmake should be built with the same compiler -- doing something else is not something we've been supporting at the moment.

So if you're hitting unresolved issues with clang with any dev-qt/* packages and want to use gcc as a workaround, I'd recommend doing them all using "dev-qt/*:5 gcc.conf" in package.env or so and start with rebuilding qtcore.
Comment 4 manu 2024-04-15 12:23:06 UTC
(In reply to Ionen Wolkens from comment #3)
> So if you're hitting unresolved issues with clang with any dev-qt/* packages
> and want to use gcc as a workaround, I'd recommend doing them all using
> "dev-qt/*:5 gcc.conf" in package.env or so and start with rebuilding qtcore.

That did the trick. I thought I could mix freely clang- and gcc-compiled packages. Thank you so much!!
Comment 5 Ionen Wolkens gentoo-dev 2024-04-15 12:57:39 UTC
(In reply to manu from comment #4)
> That did the trick. I thought I could mix freely clang- and gcc-compiled
> packages. Thank you so much!!
It's "typically" fine, but there are a few sensitive "suites" that similarly remember settings -- sometime they may even ignore CC except the one that was set for the main package in the suite.

With Qt6 this is less of an issue because dev-qt/*:6 uses cmake and has no problems with switching compiler. However, qmake still exists with Qt6 and *other* packages that use qmake may still be flaky.

It may be possible to improve the situation in qmake-utils.eclass (detect compiler + pass the right spec file) but not something I looked at.
Comment 6 manu 2024-04-16 15:24:56 UTC
Thanks for the detailed explanation. It'd be nice if clang compiled every qt6 package smoothly but, of course, it's no big deal.