Created attachment 582746 [details] build.log In file included from dumb_bo.c:40: /usr/include/xf86drm.h:40:10: fatal error: drm.h: No such file or directory #include <drm.h> ^~~~~~~ compilation terminated. make[5]: *** [Makefile:755: dumb_bo.lo] Error 1 make[5]: *** Waiting for unfinished jobs.... drmmode_display.c:42:10: fatal error: drm_fourcc.h: No such file or directory #include <drm_fourcc.h> ^~~~~~~~~~~~~~ compilation terminated. In file included from dri2.c:42: driver.h:31:10: fatal error: drm.h: No such file or directory #include <drm.h> ^~~~~~~ compilation terminated. make[5]: *** [Makefile:755: drmmode_display.lo] Error 1 make[5]: *** [Makefile:755: dri2.lo] Error 1 In file included from driver.c:63: driver.h:31:10: fatal error: drm.h: No such file or directory #include <drm.h> ^~~~~~~ compilation terminated. Portage 2.3.62 (python 3.6.5-final-0, default/linux/hppa/17.0, gcc-8.3.0, glibc-2.28-r6, 5.0.10 parisc64) ================================================================= System uname: Linux-5.0.10-parisc64-PA8800_-Mako-with-gentoo-2.6 KiB Mem: 8231368 total, 268420 free KiB Swap: 4194300 total, 4187132 free Timestamp of repository gentoo: Sat, 13 Jul 2019 00:15:01 +0000 Head commit of repository gentoo: b071a044059b008fea94b5af02326ef2b0d28992 sh bash 4.4_p23-r1 ld GNU ld (Gentoo 2.31.1 p7) 2.31.1 app-shells/bash: 4.4_p23-r1::gentoo dev-lang/perl: 5.26.2::gentoo dev-lang/python: 2.7.15::gentoo, 3.5.4-r1::gentoo, 3.6.5::gentoo dev-util/cmake: 3.14.3::gentoo dev-util/pkgconfig: 0.29.2::gentoo sys-apps/baselayout: 2.6-r1::gentoo sys-apps/openrc: 0.38.3-r1::gentoo sys-apps/sandbox: 2.13::gentoo sys-devel/autoconf: 2.13-r1::gentoo, 2.69-r4::gentoo sys-devel/automake: 1.16.1-r1::gentoo sys-devel/binutils: 2.31.1-r6::gentoo sys-devel/gcc: 8.3.0-r1::gentoo sys-devel/gcc-config: 2.0::gentoo sys-devel/libtool: 2.4.6-r3::gentoo sys-devel/make: 4.2.1-r4::gentoo sys-kernel/linux-headers: 4.14-r1::gentoo (virtual/os-headers) sys-libs/glibc: 2.28-r6::gentoo Repositories: gentoo location: /usr/portage sync-type: rsync sync-uri: rsync://rsync.gentoo.org/gentoo-portage priority: -1000 sync-rsync-verify-jobs: 1 sync-rsync-verify-metamanifest: no sync-rsync-verify-max-age: 24 sync-rsync-extra-opts: ACCEPT_KEYWORDS="hppa" ACCEPT_LICENSE="@FREE" CBUILD="hppa2.0-unknown-linux-gnu" CFLAGS="-O2 -pipe -march=2.0" CHOST="hppa2.0-unknown-linux-gnu" CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/qmail/alias /var/qmail/control /var/spool/torque" 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/terminfo" CXXFLAGS="-O2 -pipe -march=2.0" 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="" FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr" FFLAGS="" GENTOO_MIRRORS="ftp://castor.sf-tec.de/ ftp://ftp.join.uni-muenster.de/pub/linux/distributions/gentoo ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo " LANG="en_US.UTF-8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" 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="acl berkdb big-endian bzip2 cli crypt cups cxx firefox foomaticdb fortran gdbm gpm hppa iconv imlib ipv6 libwww ncurses nls nptl openmp pam pcre readline spell ssl tcpd unicode xattr zlib" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache 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" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" NETBEANS_MODULES="apisupport cnd groovy gsf harness ide identity j2ee java mobility nb php profiler soa visualweb webcommon websvccommon xml" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-2" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_6" PYTHON_TARGETS="python2_7 python3_6" RUBY_TARGETS="ruby24" USERLAND="GNU" VIDEO_CARDS="fbdev dummy v4l" 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, LC_ALL, LINGUAS, MAKEOPTS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
drm.h and drm_fourcc.h are provided by sys-kernel/linux-headers. Does your linux-headers installation not have these files?
The files are there: /usr/include/libdrm/drm.h /usr/include/libdrm/drm_fourcc.h /usr/include/drm/drm.h /usr/include/drm/drm_fourcc.h But the compile command did not include any of the subdirectories in the include paths.
I can reproduce this with USE="minimal -udev". Compile command doesn't include "-I/usr/include/libdrm" in this case. From configure.ac: if test "x$DRI" = xyes || test "x$DRI2" = xyes || test "x$DRI3" = xyes || test "x$CONFIG_UDEV_KMS" = xyes; then if test "x$DRM" = xyes; then AC_DEFINE(WITH_LIBDRM, 1, [Building with libdrm support]) PKG_CHECK_MODULES([LIBDRM], $LIBDRM) fi fi $ pkg-config --cflags libdrm -I/usr/include/libdrm
(In reply to Alexander Tsoy from comment #3) ... > if test "x$DRI" = xyes || test "x$DRI2" = xyes || test "x$DRI3" = xyes || > test "x$CONFIG_UDEV_KMS" = xyes; then > if test "x$DRM" = xyes; then > AC_DEFINE(WITH_LIBDRM, 1, [Building with libdrm support]) > PKG_CHECK_MODULES([LIBDRM], $LIBDRM) > fi > fi and later: if test "x$DRM" = xyes; then XORG_DRIVER_MODESETTING=yes fi So we are building modesetting driver (which needs drm headers) even with USE=minimal, because ebuild pass --enable-libdrm to configure unconditionally.
And USE="minimal -udev -xorg" builds fine, because modesetting driver is not built in this case.
This is more like a oxrg-server build system issue. You cannot really build xorg-server without libdrm, as it includes xf86drm.h in lnx_platform.c and the header is part of x11-libs/libdrm. Looks to me like the autotools should use pkg-config to find libdrm even if there's no UDEV enabled.
(In reply to Piotr Karbowski from comment #6) > You cannot really build xorg-server without libdrm, as it includes xf86drm.h > in lnx_platform.c and the header is part of x11-libs/libdrm. The code in lnx_platform.c depends on udev support (XSERVER_PLATFORM_BUS macro).
So I think the real problem here is modesetting driver which cannot be disabled separetely from libdrm and xorg.
Created attachment 590686 [details] 0001-configure-Set-libdrm-flags-correctly-for-modesetting.patch Attached patch fixed this issue for me.
Would you kindly send that upstream? Ideally they will pull it in and we will get it with new release.
https://gitlab.freedesktop.org/xorg/xserver/merge_requests/293
Thank you! I poked upstream and got this merged into master, and then I merged it into the 1.20 branch, so it'll be in 1.20.6.
This is in the 1.20 branch as well.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c38af1852d41380a9758c092ffb0df8362dec256 commit c38af1852d41380a9758c092ffb0df8362dec256 Author: Matt Turner <mattst88@gentoo.org> AuthorDate: 2019-11-23 00:12:49 +0000 Commit: Matt Turner <mattst88@gentoo.org> CommitDate: 2019-11-23 00:20:59 +0000 x11-base/xorg-server: Version bump to 1.20.6 Closes: https://bugs.gentoo.org/689768 Closes: https://bugs.gentoo.org/700052 Closes: https://bugs.gentoo.org/700120 Closes: https://bugs.gentoo.org/700838 Signed-off-by: Matt Turner <mattst88@gentoo.org> x11-base/xorg-server/Manifest | 1 + x11-base/xorg-server/xorg-server-1.20.6.ebuild | 232 +++++++++++++++++++++++++ 2 files changed, 233 insertions(+)