Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 885763 - x11-drivers/xf86-video-nouveau-1.0.17 - nv_driver.c: error: call to undeclared function wfbScreenInit; ISO C99
Summary: x11-drivers/xf86-video-nouveau-1.0.17 - nv_driver.c: error: call to undeclare...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks: c99-porting
  Show dependency tree
 
Reported: 2022-12-13 10:44 UTC by Toralf Förster
Modified: 2023-12-14 15:59 UTC (History)
0 users

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


Attachments
emerge-info.txt (emerge-info.txt,18.56 KB, text/plain)
2022-12-13 10:44 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,171.43 KB, text/plain)
2022-12-13 10:44 UTC, Toralf Förster
Details
environment (environment,107.50 KB, text/plain)
2022-12-13 10:44 UTC, Toralf Förster
Details
etc.clang.tar.bz2 (etc.clang.tar.bz2,699 bytes, application/x-bzip)
2022-12-13 10:44 UTC, Toralf Förster
Details
etc.portage.tar.bz2 (etc.portage.tar.bz2,31.45 KB, application/x-bzip)
2022-12-13 10:44 UTC, Toralf Förster
Details
logs.tar.bz2 (logs.tar.bz2,9.56 KB, application/x-bzip)
2022-12-13 10:44 UTC, Toralf Förster
Details
temp.tar.bz2 (temp.tar.bz2,374.51 KB, application/x-bzip)
2022-12-13 10:44 UTC, Toralf Förster
Details
var.tmp.clang.tar.bz2 (var.tmp.clang.tar.bz2,1.46 KB, application/x-bzip)
2022-12-13 10:44 UTC, Toralf Förster
Details
x11-drivers:xf86-video-nouveau-1.0.17:20221213-101903.log (x11-drivers:xf86-video-nouveau-1.0.17:20221213-101903.log,23.84 KB, text/plain)
2022-12-13 10:44 UTC, Toralf Förster
Details
build log (nouveau-build.log,25.97 KB, text/x-log)
2023-11-06 20:04 UTC, Pascal Jäger
Details
patch updated for 21.1.9 (xorg-server-21.1.9-wfb.patch,1.33 KB, patch)
2023-11-06 20:49 UTC, Pascal Jäger
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2022-12-13 10:44:02 UTC
too long lines were shrinked:

/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -I/usr/include/xorg -fvisibility=hidden -I/usr/include/pixman-1   -I/usr/include/libdrm -I/usr/include/libdrm/nouveau  -I/usr/include/libdrm  -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-decla
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -I/usr/include/xorg -fvisibility=hidden -I/usr/include/pixman-1   -I/usr/include/libdrm -I/usr/include/libdrm/nouveau  -I/usr/include/libdrm  -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-decla
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -I/usr/include/xorg -fvisibility=hidden -I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libdrm/nouveau -I/usr/include/libdrm -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-declaration -Werror=implicit-int -Wall 
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -I/usr/include/xorg -fvisibility=hidden -I/usr/include/pixman-1   -I/usr/include/libdrm -I/usr/include/libdrm/nouveau  -I/usr/include/libdrm  -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-decla
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -I/usr/include/xorg -fvisibility=hidden -I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libdrm/nouveau -I/usr/include/libdrm -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-declaration -Werror=implicit-int -Wall 
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -I/usr/include/xorg -fvisibility=hidden -I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libdrm/nouveau -I/usr/include/libdrm -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-declaration -Werror=implicit-int -Wall 
nv_driver.c:1451:9: error: call to undeclared function 'wfbScreenInit'; ISO C99
      and later do not support implicit function declarations
      [-Werror,-Wimplicit-function-declaration]

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_desktop_plasma_systemd-j4-20221211-150005

  -------------------------------------------------------------------

CC=clang
CXX=clang++
gcc-config -l:
 [1] x86_64-pc-linux-gnu-12 *
clang/llvm (if any):
clang version 15.0.6
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/15/bin
Configuration file: /etc/clang/clang.cfg
/usr/lib/llvm/15
15.0.6
Python 3.10.9
Available Rust versions:
  [1]   rust-bin-1.65.0 *
The following VMs are available for generation-2:
1)	OpenJDK 17.0.5_p8 [openjdk-17]
2)	Eclipse Temurin JDK 11.0.17_p8 [openjdk-bin-11]
*)	Eclipse Temurin JDK 17.0.5_p8 [openjdk-bin-17]
4)	Eclipse Temurin JDK 8.352_p08 [openjdk-bin-8]
5)	Eclipse Temurin JRE 8.352_p08 [openjdk-jre-bin-8]
Available Java Virtual Machines:
  [1]   openjdk-17 
  [2]   openjdk-bin-8 
  [3]   openjdk-bin-11 
  [4]   openjdk-bin-17  system-vm
  [5]   openjdk-jre-bin-8 

The Glorious Glasgow Haskell Compilation System, version 9.0.2
php cli (if any):
  [1]   php8.2 *

  HEAD of ::gentoo
commit 5db9e294831c31ef205e7c58f8056e46b8ac9b6d
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Tue Dec 13 09:46:50 2022 +0000

    2022-12-13 09:46:49 UTC

emerge -qpvO x11-drivers/xf86-video-nouveau
[ebuild  N    ] x11-drivers/xf86-video-nouveau-1.0.17
Comment 1 Toralf Förster gentoo-dev 2022-12-13 10:44:03 UTC
Created attachment 842417 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2022-12-13 10:44:04 UTC
Created attachment 842419 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2022-12-13 10:44:06 UTC
Created attachment 842421 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2022-12-13 10:44:07 UTC
Created attachment 842423 [details]
etc.clang.tar.bz2
Comment 5 Toralf Förster gentoo-dev 2022-12-13 10:44:08 UTC
Created attachment 842425 [details]
etc.portage.tar.bz2
Comment 6 Toralf Förster gentoo-dev 2022-12-13 10:44:09 UTC
Created attachment 842427 [details]
logs.tar.bz2
Comment 7 Toralf Förster gentoo-dev 2022-12-13 10:44:11 UTC
Created attachment 842429 [details]
temp.tar.bz2
Comment 8 Toralf Förster gentoo-dev 2022-12-13 10:44:11 UTC
Created attachment 842431 [details]
var.tmp.clang.tar.bz2
Comment 9 Toralf Förster gentoo-dev 2022-12-13 10:44:12 UTC
Created attachment 842433 [details]
x11-drivers:xf86-video-nouveau-1.0.17:20221213-101903.log
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-14 04:21:43 UTC
This needs a fix in xorg-server.
Comment 11 Larry the Git Cow gentoo-dev 2023-07-22 17:24:25 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=de718a87b2cedfc40155f05af6fd477b14cabcb8

commit de718a87b2cedfc40155f05af6fd477b14cabcb8
Author:     Ahmed Charles <me@ahmedcharles.com>
AuthorDate: 2023-07-20 18:53:12 +0000
Commit:     Matt Turner <mattst88@gentoo.org>
CommitDate: 2023-07-22 17:24:19 +0000

    x11-base/xorg-server: fix xf86-video-nouveau build
    
    Closes: https://bugs.gentoo.org/885763
    Closes: https://github.com/gentoo/gentoo/pull/31985
    Signed-off-by: Ahmed Charles <me@ahmedcharles.com>
    Signed-off-by: Matt Turner <mattst88@gentoo.org>

 .../xorg-server/files/xorg-server-21.1.8-wfb.patch |  43 +++++
 x11-base/xorg-server/xorg-server-21.1.8-r2.ebuild  | 195 +++++++++++++++++++++
 2 files changed, 238 insertions(+)
Comment 12 Pascal Jäger 2023-11-06 20:02:46 UTC
Looks like the this wasn't upstreamed properly or something. Since xorg-21.1.9 this is happening again. And 21.1.9 isn't applying the wfb patch anymore. 

Build log attached.
Comment 13 Pascal Jäger 2023-11-06 20:04:22 UTC
Created attachment 874177 [details]
build log
Comment 14 Pascal Jäger 2023-11-06 20:22:19 UTC
Sorry, apparently this patch is upstreamed indeed, but it isn't fixing the error anymore. 
I compiled with gcc and clang, same result
Comment 15 Pascal Jäger 2023-11-06 20:44:24 UTC
So to sort this out properly: This is not upstreamed in tag 21.1.9 (https://gitlab.freedesktop.org/xorg/xserver/-/blob/xorg-server-21.1.9/fb/fb.h?ref_type=tags#L1030) but it is or later commits. 

Patch attached.
Comment 16 Pascal Jäger 2023-11-06 20:49:18 UTC
Created attachment 874186 [details, diff]
patch updated for 21.1.9
Comment 17 Larry the Git Cow gentoo-dev 2023-12-14 04:12:23 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=702ab503b10f6fe6719564dbc310bd4422f58014

commit 702ab503b10f6fe6719564dbc310bd4422f58014
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-12-14 02:38:35 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-12-14 04:03:40 +0000

    x11-base/xorg-server: fix headers for modern C issue
    
    Otherwise nouveau can't build. These changes are in master already and I've
    sent a PR to backport them too.
    
    Closes: https://bugs.gentoo.org/885763
    Signed-off-by: Sam James <sam@gentoo.org>

 .../files/xorg-server-21.1.10-c99.patch            |  39 +++++
 x11-base/xorg-server/xorg-server-21.1.10-r1.ebuild | 194 +++++++++++++++++++++
 2 files changed, 233 insertions(+)
Comment 18 Matt Turner gentoo-dev 2023-12-14 15:59:44 UTC
Having heard no users complain about this indicates to me that no one uses xf86-video-nouveau...