# Ati-drivers 39.4 error

## Grilo

I have the latest mm-sources install and went to compile the ati-drivers against it as if i do not do this i get pink lines and dots after a couple days. so i go to compile and it fails. I search on here that it has to do with ioctl.h and ioctl32.h. so i do the ln-s and link the two only to have it fail. I search the bugs and go to apply the patch. it says reverse the patch? i say no.  here is the whole error.

```

 [32;01m*[0m Determining the location of the kernel source code

 [32;01m*[0m Found kernel source directory:

 [32;01m*[0m     /usr/src/linux

 [32;01m*[0m Found kernel object directory:

 [32;01m*[0m     /lib/modules/2.6.23-rc2-mm1/build

 [32;01m*[0m Found sources for kernel version:

 [32;01m*[0m     2.6.23-rc2-mm1

>>> Unpacking source...

 [32;01m*[0m Converting 2.6.x/Makefile to use M= instead of SUBDIRS= ...

[A[168C  [34;01m[ [32;01mok[34;01m ][0m

>>> Unpacking ./../common/usr/src/ati/fglrx_sample_source.tgz to /var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/extra

>>> Source unpacked.

>>> Compiling source in /var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work ...

 [32;01m*[0m Preparing fglrx module

make -C /usr/src/linux M=/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x modules

make[1]: Entering directory `/usr/src/linux-2.6.23-rc2-mm1'

  CC [M]  /var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.o

In file included from /var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/drm_proc.h:41,

                 from /var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:366:

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/drmP.h:126:1: warning: "DRM_DEBUG_CODE" redefined

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:179:1: warning: this is the location of the previous definition

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:484: warning: initialization from incompatible pointer type

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function 'firegl_stub_open':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:607: warning: assignment discards qualifiers from pointer target type

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function 'firegl_put_user_ptr':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1471: warning: cast from pointer to integer of different size

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1471: warning: cast from pointer to integer of different size

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1471: warning: cast from pointer to integer of different size

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1471: warning: cast from pointer to integer of different size

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_check_pci':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1834: warning: 'pci_find_slot' is deprecated (declared at include/linux/pci.h:483)

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_pci_find_device':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1863: warning: 'pci_find_device' is deprecated (declared at include/linux/pci.h:482)

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_do_mmap':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1968: warning: assignment makes pointer from integer without a cast

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_vm_test_and_clear_dirty':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:2388: error: implicit declaration of function 'ptep_test_and_clear_dirty'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_pci_find_slot':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:2696: warning: 'pci_find_slot' is deprecated (declared at include/linux/pci.h:483)

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_request_irq':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:2806: warning: 'deprecated_irq_flag' is deprecated (declared at include/linux/interrupt.h:64)

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:2806: warning: passing argument 2 of 'request_irq' from incompatible pointer type

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_unregister_ioctl32_conversion':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:2829: warning: 'return' with a value, in function returning void

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function '__ke_pte_phys_addr_str':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:3380: error: implicit declaration of function 'pte_read'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:3382: error: implicit declaration of function 'pte_exec'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: At top level:

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5280: error: expected specifier-qualifier-list before 'kmem_cache_t'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function 'KAS_SlabCache_Initialize':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5319: error: 'kasSlabCache_t' has no member named 'routine_type'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5320: error: 'kasSlabCache_t' has no member named 'lock'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5321: error: 'kasSlabCache_t' has no member named 'name'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5321: warning: cast from pointer to integer of different size

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5325: error: 'kasSlabCache_t' has no member named 'cache'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5326: error: 'kasSlabCache_t' has no member named 'name'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5326: error: too many arguments to function 'kmem_cache_create'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function 'KAS_SlabCache_Destroy':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5349: error: 'kasSlabCache_t' has no member named 'cache'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5359: error: 'kasSlabCache_t' has no member named 'cache'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5361: error: 'kasSlabCache_t' has no member named 'cache'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function 'KAS_SlabCache_AllocEntry':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5396: error: 'kasSlabCache_t' has no member named 'routine_type'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5397: error: 'kasSlabCache_t' has no member named 'lock'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5421: error: 'kasSlabCache_t' has no member named 'cache'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5424: error: 'kasSlabCache_t' has no member named 'lock'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5432: error: 'kasSlabCache_t' has no member named 'cache'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function 'KAS_SlabCache_FreeEntry':

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5460: error: 'kasSlabCache_t' has no member named 'routine_type'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5461: error: 'kasSlabCache_t' has no member named 'lock'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5473: error: 'kasSlabCache_t' has no member named 'cache'

/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5476: error: 'kasSlabCache_t' has no member named 'lock'

make[2]: *** [/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.o] Error 1

make[1]: *** [_module_/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/work/common/lib/modules/fglrx/build_mod/2.6.x] Error 2

make[1]: Leaving directory `/usr/src/linux-2.6.23-rc2-mm1'

make: *** [kmod_build] Error 2

 [31;01m*[0m 

 [31;01m*[0m ERROR: x11-drivers/ati-drivers-8.39.4 failed.

 [31;01m*[0m Call stack:

 [31;01m*[0m   ebuild.sh, line 1654:   Called dyn_compile

 [31;01m*[0m   ebuild.sh, line 990:   Called qa_call 'src_compile'

 [31;01m*[0m   ebuild.sh, line 44:   Called src_compile

 [31;01m*[0m   ati-drivers-8.39.4.ebuild, line 176:   Called linux-mod_src_compile

 [31;01m*[0m   linux-mod.eclass, line 516:   Called die

 [31;01m*[0m 

 [31;01m*[0m Unable to make  GCC_VER_MAJ=4 KVER=2.6.23-rc2-mm1 KDIR=/usr/src/linux kmod_build.

 [31;01m*[0m If you need support, post the topmost build error, and the call stack if relevant.

 [31;01m*[0m A complete build log is located at '/var/tmp/portage/x11-drivers/ati-drivers-8.39.4/temp/build.log'.

 [31;01m*[0m 

```

I have updated the kernel, i have tried several ati-drivers old and new. i am unsure where to begin. any help is greatly appreciated. and i have thought about trying another kernel but i have read that a few do not have the ioctl32.h that might cause the problem.

thanks

Grilo

----------

## d2_racing

Can you post emerge --info  plz  :Smile: 

----------

## der.gecko

which drivers were installed before? i had some serious problems with uninstalling drivers from the ati homepage...

----------

## swigrid

Hi, I've got same problem but with x11-drivers/ati-drivers-8.40.4

```

 * Building fgl_glxgears

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../lib64/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/../lib64/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib64/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find -lGL

collect2: ld returned 1 exit status

 * 

 * ERROR: x11-drivers/ati-drivers-8.40.4 failed.

 * Call stack:

 *   ebuild.sh, line 1654:   Called dyn_compile

 *   ebuild.sh, line 990:   Called qa_call 'src_compile'

 *   ebuild.sh, line 44:   Called src_compile

 *   ati-drivers-8.40.4.ebuild, line 189:   Called die

 * 

 * fgl_glxgears build failed

 * If you need support, post the topmost build error, and the call stack if relevant.

 * A complete build log is located at '/mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/temp/build.log'.

```

my emerge --info is:

```

swigrid ~ # emerge --info

Portage 2.1.3.6 (default-linux/amd64/2007.0, gcc-4.2.0, glibc-2.6.1-r0, 2.6.21-gentoo-r3 x86_64)

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

System uname: 2.6.21-gentoo-r3 x86_64 AMD Sempron(tm) Processor 2800+

Gentoo Base System release 1.12.10

Timestamp of tree: Wed, 22 Aug 2007 00:00:01 +0000

dev-java/java-config: 1.3.7, 2.0.33-r1

dev-lang/python:     2.4.4-r4

dev-python/pycrypto: 2.0.1-r6

sys-apps/sandbox:    1.2.18.1

sys-devel/autoconf:  2.13, 2.61-r1

sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10

sys-devel/binutils:  2.17.50.0.18

sys-devel/gcc-config: 1.3.16

sys-devel/libtool:   1.5.24

virtual/os-headers:  2.6.22-r2

ACCEPT_KEYWORDS="amd64 ~amd64"

AUTOCLEAN="yes"

CBUILD="x86_64-pc-linux-gnu"

CFLAGS="-march=k8 -O2 -pipe"

CHOST="x86_64-pc-linux-gnu"

CONFIG_PROTECT="/etc /usr/share/X11/xkb"

CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo"

CXXFLAGS="-march=k8 -O2 -pipe"

DISTDIR="/usr/portage/distfiles"

FEATURES="distlocks metadata-transfer sandbox sfperms strict unmerge-orphans userfetch"

GENTOO_MIRRORS="http://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/ http://gentoo.mirror.solnet.ch ftp://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/"

LINGUAS="en sk cs"

MAKEOPTS="-j2"

PKGDIR="/usr/portage/packages"

PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

PORTDIR_OVERLAY="/usr/local/portage"

SYNC="rsync://rsync.gentoo.org/gentoo-portage"

USE="3dnow 3dnowext 7zip X a52 aac aalib acl alsa amd64 amr apache2 berkdb bitmap-fonts calendar cli cracklib crypt cups dbus directfb divx divx4linux dri dts dvd dvdr evo fortran ftp gdbm gif gpm gtk iconv icq isdnlog java javascript joystick jpeg jpeg2k live lm_sensors mad midi mmx mmxext mozilla mp3 mpeg mplayer msn mudflap mysql ncurses nls nptl nptlonly nsplugin opengl openmp pam pcre pda perl php png pppd python quicktime readline realmedia reflection samba session slang spell spl sse sse2 ssl tcpd theora tiff truetype truetype-fonts type1 type1-fonts unicode wmp xanim xcomposite xorg xvid zlib" ALSA_CARDS="emu10k1" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en sk cs" USERLAND="GNU" VIDEO_CARDS="fglrx vesa vga vbdev radeon"

Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

```

 *Quote:*   

> 
> 
> which drivers were installed before? i had some serious problems with uninstalling drivers from the ati homepage...
> 
> 

 

and now I've got ati-drivers-8.39.4

----------

## d2_racing

Ok, I think I found your problem :

```

default-linux/amd64/2007.0

```

You need at least a 2007.0-desktop profile I think to compile the ATI driver.

Before reinstalling the ATI, you need do perform a world update

```

# emerge -puDNv world

```

```

# eselect profile list

# eselect profile set (the number of the 2007.0/desktop)

```

----------

## swigrid

 *d2_racing wrote:*   

> Ok, I think I found your problem :
> 
> ```
> 
> default-linux/amd64/2007.0
> ...

 

it didn't help me, it just added many unwanted use flags to my system  :Sad:  Any other idea?

----------

## d2_racing

Can you post var/tmp/portage/x11-drivers/ati-drivers-8.39.4/temp/build.log

----------

## Gentoo Bob

I'm having the same problem!  

I did a emerge -avuDN world the other day and it updated my ati-drivers to the ati-drivers-8.39 since then everything with my video is messed up.

I cant get 3D rendering anymore.  Tells me the following....

Xlib:  extension "GLX" missing on display ":0.0".

Error: couldn't get an RGB, Double-buffered visual

No matter what I do, I cant get it working.  I cant remember what ati-drivers I was on before.    Nothing changed except the drivers being upgraded.

Im not having no luck.   I read an article where the new driver and xinerama are having a conflict, i reemerged everything without xinerama, didnt work.

here is if i do a   # eselect opengl set ati     I get....

name of display: :0.0

Xlib:  extension "GLX" missing on display ":0.0".

Xlib:  extension "GLX" missing on display ":0.0".

Xlib:  extension "GLX" missing on display ":0.0".

Error: couldn't find RGB GLX visual

   visual  x  bf lv rg d st colorbuffer ax dp st accumbuffer  ms  cav

 id dep cl sp sz l  ci b ro  r  g  b  a bf th cl  r  g  b  a ns b eat

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

Xlib:  extension "GLX" missing on display ":0.0".

Xlib:  extension "GLX" missing on display ":0.0".

0x21 24 tc  1  0  0 c  .  .  0  0  0  0  0  0  0  0  0  0  0  0 0 None

Xlib:  extension "GLX" missing on display ":0.0".

Xlib:  extension "GLX" missing on display ":0.0".

0x22 24 dc  1  0  0 c  .  .  0  0  0  0  0  0  0  0  0  0  0  0 0 None

I'm at a loss.  I think these new drivers are crap.   I had this same issue on my other Gentoo box but with Nvidia drivers but was easily fixed by re-emerging the drivers and setting the opengl it fixed it.  This is not working.

----------

## swigrid

```

swigrid ~ # cat /mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/temp/build.log

 * Determining the location of the kernel source code

 * Found kernel source directory:

 *     /usr/src/linux

 * Found kernel object directory:

 *     /lib/modules/2.6.21-gentoo-r3/build

 * Found sources for kernel version:

 *     2.6.21-gentoo-r3

>>> Unpacking source...

 * Applying ati-powermode-opt-path.patch ...                                                                         [ ok ]

 * Converting 2.6.x/Makefile to use M= instead of SUBDIRS= ...                                                       [ ok ]

>>> Unpacking ./../common/usr/src/ati/fglrx_sample_source.tgz to /mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work/extra

 * Applying ati-drivers-8.40.4-warnings.patch ...                                                                    [ ok ]

>>> Source unpacked.

>>> Compiling source in /mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work ...

 * Preparing fglrx module

make -C /usr/src/linux M=/mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work/common/lib/modules/fglrx/build_mod/2.6.x modules

make[1]: Entering directory `/usr/src/linux-2.6.21-gentoo-r3'

  CC [M]  /mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.o

/mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:484: warning: 'firegl_smp_func_parameter_wrap' defined but not used

  LD [M]  /mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work/common/lib/modules/fglrx/build_mod/2.6.x/fglrx.o

  Building modules, stage 2.

  MODPOST 1 modules

  CC      /mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work/common/lib/modules/fglrx/build_mod/2.6.x/fglrx.mod.o

  LD [M]  /mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/work/common/lib/modules/fglrx/build_mod/2.6.x/fglrx.ko

make[1]: Leaving directory `/usr/src/linux-2.6.21-gentoo-r3'

 * Building fgl_glxgears

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../lib64/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/../lib64/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib64/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: skipping incompatible /usr/lib/libGL.so when searching for -lGL

/usr/lib/gcc/x86_64-pc-linux-gnu/4.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find -lGL

collect2: ld returned 1 exit status

 * 

 * ERROR: x11-drivers/ati-drivers-8.40.4 failed.

 * Call stack:

 *   ebuild.sh, line 1654:   Called dyn_compile

 *   ebuild.sh, line 990:   Called qa_call 'src_compile'

 *   ebuild.sh, line 44:   Called src_compile

 *   ati-drivers-8.40.4.ebuild, line 189:   Called die

 * 

 * fgl_glxgears build failed

 * If you need support, post the topmost build error, and the call stack if relevant.

 * A complete build log is located at '/mnt/data/tmp/tmp/portage/x11-drivers/ati-drivers-8.40.4/temp/build.log'.

 * 

```

----------

## Gentoo Bob

Swigrig - thats about the same thing I got except with the 8.39 drivers.  

I did find a fix for mine!

the newer drivers use MESA opengl (i dont know if its new or if its a newer version)  and I noticed that fglrx wasnt getting installed, just like your issue.  

so in my /etc/make.conf config file i put  VIDEO_CARDS="fglrx"   

I uninstalled ati-drivers,  I reemerged with  #emerge -avuDN world  doing this re compiled 3 things,

it recompiled MESA, Xorg-server, and something else (mind just went blank).  Then I removed my xorg.conf file and created a new one, then applied the aticonfig --initial --input=/etc/X11/xorg.conf   

I still had an issue with "Screen 0" not being found.  I looked at my xorg.conf   the aticonfig configuration added a few unneeded 0's (zeros) to my screen config in xorg.conf.   I removed them, started X, and it works!!!  

I hope that works for you!

----------

