[PATCH xf86-video-xgi] Modify search for drm include.
Trevor Woerner
twoerner at gmail.com
Wed Jul 28 14:18:02 PDT 2010
On Wed, Jul 28, 2010 at 5:04 PM, Gaetan Nadon <memsize at videotron.ca> wrote:
> On Wed, 2010-07-28 at 16:34 -0400, Trevor Woerner wrote:
>
> -#include <drm/drm.h>
> +#include "drm.h"
>
> The xgi driver is built regularly on http://tinderbox.freedesktop.org/
> so I don't see why you would need this. It also builds fine on my system
> where I have all current git packages.
>
> You did not mention what problems you are having.
I was following the instructions at:
http://xorg.freedesktop.org/wiki/ModularDevelopersGuide
and it failed when trying to build this module:
xgi_dri.c:69:21: fatal error: drm/drm.h: No such file or directory
compilation terminated.
make[2]: *** [xgi_dri.lo] Error 1
make[2]: Leaving directory
`/home/trevor/devel/code/xorg.modular/driver/xf86-video-xgi/src'
So at that point I looked into the sources of the
driver/xf86-video-radeonhd module to find an example where the same
file was included in a module which compiled successfully for me and I
found that it simply included the drm.h header in the way which my
patch modifies. I then tried a build of xf86-video-xgi using "make
V=1" and verified that one of the "-I" directories included in the
build was the libdrm directory at the install location.
If I look at the install location of my build I find:
$ ls -l
total 92
drwxr-xr-x 2 trevor users 4096 Jul 27 11:50 EGL
drwxr-xr-x 3 trevor users 4096 Jul 27 11:50 GL
drwxr-xr-x 2 trevor users 4096 Jul 27 11:50 KHR
drwxr-xr-x 13 trevor users 4096 Jul 27 11:51 X11
drwxr-xr-x 2 trevor users 4096 Jul 27 11:37 libdrm
drwxr-xr-x 2 trevor users 4096 Jul 27 11:36 libkms
-rw-r--r-- 1 trevor users 0 Jul 28 17:14 out
-rw-r--r-- 1 trevor users 14828 Jul 27 11:34 pciaccess.h
drwxr-xr-x 2 trevor users 4096 Jul 27 11:36 pixman-1
drwxr-xr-x 2 trevor users 4096 Jul 26 17:49 xcb
-rw-r--r-- 1 trevor users 27798 Jul 27 11:36 xf86drm.h
-rw-r--r-- 1 trevor users 11603 Jul 27 11:36 xf86drmMode.h
drwxr-xr-x 2 trevor users 4096 Jul 27 12:29 xorg
There is no "drm" directory, but there is a "libdrm". So for my build
I either have to modify the #include to say <libdrm/drm.h> or simply
"drm.h". Seeing that the radeonhd uses "drm.h" that's what I
submitted.
My build system is a fresh install of openSUSE 11.3 (recently released).
> Have you configured the driver with --disable-dri?
No, I've looked through my build output log and no such option
appears. I just followed the directions from the xorg website.
More information about the xorg-devel
mailing list