# [solved]Wine, Intel G965, "»intel->locked« nicht erfüllt"

## Mr. Anderson

Hallo,

seit einigen Stunden bastel ich nun an diesem Problem:

nachdem ich nun ein System zusammengesetzt habe aus dem AMD64-Zweig und Wine installiere, bekomme ich vom configure-Skript von Wine diese Zeile:

```
checking for glXCreateContext in -lGL... no
```

Bei einem Blick in die config.log ergibt sich dieses Bild:

```
configure:8333: checking for glXCreateContext in -lGL

configure:8368: gcc -m32 -o conftest -g -O2    conftest.c -lGL  -lXext -lX11 -lm   >&5

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

/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/../../../../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.1.2/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find -lGL

collect2: ld returned 1 exit status
```

also habe ich das probiert:

```
rm /usr/lib/libGL.so

ln -s /usr/lib32/opengl/xorg-x11/lib/libGL.so /usr/lib/libGL.so
```

Daraufhin lässt sich wine auch mit diesen OpenGL-libs emergen. Wenn ich dann allerdings Wine starte, bekomme ich das:

```
bufmgr_fake.c:1245: bmReleaseBuffers: Zusicherung »intel->locked« nicht erfüllt.

wine: Assertion failed at address 0xffffe410 (thread 0009), starting debugger...

Unhandled exception: assertion failed in 32-bit code (0xffffe410).

...

Backtrace:

=>1 0xffffe410 (0x0034eb60)

  2 0x00000006 (0x0034eb78)

  3 0xf7d6317e abort+0xfe() in libc.so.6 (0x0034eca4)

  4 0xf7d5aecd __assert_fail+0xfd() in libc.so.6 (0x0034ece8)

  5 0x7e2c3c7d in i965_dri.so (+0x29c7d) (0x0034ed28)

  6 0x7e2f79bc in i965_dri.so (+0x5d9bc) (0x0034ed48)

  7 0x7e2f8c96 brw_destroy_state+0x46() in i965_dri.so (0x0034ed68)

  8 0x7e304732 in i965_dri.so (+0x6a732) (0x0034ed88)

  9 0x7e2ca09d intelDestroyContext+0x2d() in i965_dri.so (0x0034edb8)

  10 0x7e2bff97 in i965_dri.so (+0x25f97) (0x0034edd8)

  11 0x7e4f732c in libgl.so.1 (+0x1432c) (0x0034ee08)

  12 0x7e6c1828 in winex11 (+0x41828) (0x0034ee88)

  13 0x7e6c1e8d X11DRV_setup_opengl_visual+0x12e() in winex11 (0x0034ef68)

  14 0x7e6d6125 in winex11 (+0x56125) (0x0034f0c8)

  15 0x7e6e65e7 in winex11 (+0x665e7) (0x0034f0e8)

  16 0x7bc37eb5 call_dll_entry_point+0x15() in ntdll (0x0034f108)

  17 0x7bc396d2 in ntdll (+0x296d2) (0x0034f198)

  18 0x7bc39cab in ntdll (+0x29cab) (0x0034f1d8)

  19 0x7bc3b4dc LdrLoadDll+0x77() in ntdll (0x0034f208)

  20 0x7b860a6e in kernel32 (+0x40a6e) (0x0034f468)

  21 0x7b860c77 LoadLibraryExW+0x4f() in kernel32 (0x0034f498)

  22 0x7b860d89 LoadLibraryExA+0x41() in kernel32 (0x0034f4b8)

  23 0x7b860dc9 LoadLibraryA+0x2d() in kernel32 (0x0034f4d8)

  24 0x7eb5bc47 DRIVER_load_driver+0x1b6() in gdi32 (0x0034f648)

  25 0x7eb57722 CreateDCW+0x60() in gdi32 (0x0034f8f8)

  26 0x7ebff946 CreateIconFromResourceEx+0x406() in user32 (0x0034f998)

  27 0x7ec003a3 in user32 (+0x303a3) (0x0034fa18)

  28 0x7ec0166f LoadImageW+0x433() in user32 (0x0034fad8)

  29 0x7ec01c00 LoadImageA+0x4d() in user32 (0x0034fbb8)

  30 0x7ec020b4 LoadCursorA+0x91() in user32 (0x0034fbe8)

  31 0x7ebf70b3 in user32 (+0x270b3) (0x0034fc08)

  32 0x7ebf70f8 CLASS_RegisterBuiltinClasses+0x1d() in user32 (0x0034fc18)

  33 0x7ec6a8ef in user32 (+0x9a8ef) (0x0034fc98)

  34 0x7ec7f6f3 in user32 (+0xaf6f3) (0x0034fcb8)

  35 0x7bc37eb5 call_dll_entry_point+0x15() in ntdll (0x0034fcd8)

  36 0x7bc396d2 in ntdll (+0x296d2) (0x0034fd68)

  37 0x7bc39cab in ntdll (+0x29cab) (0x0034fda8)

  38 0x7bc39bf6 in ntdll (+0x29bf6) (0x0034fde8)

  39 0x7bc39bf6 in ntdll (+0x29bf6) (0x0034fe28)

  40 0x7bc39bf6 in ntdll (+0x29bf6) (0x0034fe68)

  41 0x7bc39bf6 in ntdll (+0x29bf6) (0x0034fea8)

  42 0x7bc3c0de LdrInitializeThunk+0x2b9() in ntdll (0x0034ff08)

  43 0x7b86f044 in kernel32 (+0x4f044) (0x0034ffe8)

  44 0xf7e9a78f wine_switch_to_stack+0x17() in libwine.so.1 (0x00000000)

0xffffe410: popl        %ebp

Modules:

Module  Address                 Debug info      Name (61 modules)

ELF     7b800000-7b921000       Export          kernel32<elf>

  \-PE  7b820000-7b921000       \               kernel32

ELF     7bc00000-7bc94000       Export          ntdll<elf>

  \-PE  7bc10000-7bc94000       \               ntdll

ELF     7bf00000-7bf03000       Deferred        <wine-loader>

ELF     7e29a000-7e4dc000       Export          i965_dri.so

ELF     7e4dc000-7e4e3000       Deferred        libdrm.so.2

ELF     7e4e3000-7e53b000       Export          libgl.so.1

ELF     7e53b000-7e540000       Deferred        libxdmcp.so.6

ELF     7e540000-7e62b000       Deferred        libx11.so.6

ELF     7e62b000-7e639000       Deferred        libxext.so.6

ELF     7e639000-7e650000       Deferred        libice.so.6

ELF     7e650000-7e659000       Deferred        libsm.so.6

ELF     7e675000-7e702000       Export          winex11<elf>

  \-PE  7e680000-7e702000       \               winex11

ELF     7e738000-7e757000       Deferred        libexpat.so.0

ELF     7e757000-7e781000       Deferred        libfontconfig.so.1

ELF     7e781000-7e793000       Deferred        libz.so.1

ELF     7e793000-7e7f8000       Deferred        libfreetype.so.6

ELF     7e7f8000-7e82a000       Deferred        uxtheme<elf>

  \-PE  7e800000-7e82a000       \               uxtheme

ELF     7e82a000-7e8b8000       Deferred        winmm<elf>

  \-PE  7e840000-7e8b8000       \               winmm

ELF     7e8b8000-7e8ca000       Deferred        libresolv.so.2

ELF     7e8ce000-7e8d3000       Deferred        libxxf86vm.so.1

ELF     7e8e6000-7e904000       Deferred        iphlpapi<elf>

  \-PE  7e8f0000-7e904000       \               iphlpapi

ELF     7e904000-7e958000       Deferred        rpcrt4<elf>

  \-PE  7e910000-7e958000       \               rpcrt4

ELF     7e958000-7e9f3000       Deferred        ole32<elf>

  \-PE  7e970000-7e9f3000       \               ole32

ELF     7e9f3000-7ea26000       Deferred        winspool<elf>

  \-PE  7ea00000-7ea26000       \               winspool

ELF     7ea26000-7eae0000       Deferred        comctl32<elf>

  \-PE  7ea30000-7eae0000       \               comctl32

ELF     7eae0000-7eb26000       Deferred        advapi32<elf>

  \-PE  7eaf0000-7eb26000       \               advapi32

ELF     7eb26000-7ebb8000       Export          gdi32<elf>

  \-PE  7eb40000-7ebb8000       \               gdi32

ELF     7ebb8000-7eced000       Export          user32<elf>

  \-PE  7ebd0000-7eced000       \               user32

ELF     7eced000-7ed44000       Deferred        shlwapi<elf>

  \-PE  7ed00000-7ed44000       \               shlwapi

ELF     7ed44000-7ee3e000       Deferred        shell32<elf>

  \-PE  7ed60000-7ee3e000       \               shell32

ELF     7ee3e000-7eede000       Deferred        comdlg32<elf>

  \-PE  7ee50000-7eede000       \               comdlg32

ELF     7eefd000-7ef61000       Deferred        winecfg<elf>

  \-PE  7ef00000-7ef61000       \               winecfg

ELF     7ef94000-7ef9e000       Deferred        libnss_files.so.2

ELF     7ef9e000-7efa8000       Deferred        libnss_nis.so.2

ELF     7efa8000-7efbe000       Deferred        libnsl.so.1

ELF     7efbe000-7efe4000       Deferred        libm.so.6

ELF     7efec000-7eff0000       Deferred        iso8859-15.so

ELF     f7d35000-f7d39000       Deferred        libdl.so.2

ELF     f7d39000-f7e60000       Export          libc.so.6

ELF     f7e60000-f7e77000       Deferred        libpthread.so.0

ELF     f7e78000-f7e80000       Deferred        libnss_compat.so.2

ELF     f7e90000-f7e93000       Deferred        libxau.so.6

ELF     f7e93000-f7fa7000       Export          libwine.so.1

ELF     f7fa8000-f7fc4000       Deferred        ld-linux.so.2

Threads:

process  tid      prio (all id:s are in hex)

00000008 (D) c:\windows\system32\winecfg.exe

        00000009    0 <==
```

Hat jemand eine Idee? Habe die neueste Mesa-Version installiert, ebenso die emul-linux-x86-xlibs und den neuesten xf86-video-i810.Last edited by Mr. Anderson on Sat Aug 18, 2007 4:53 pm; edited 1 time in total

----------

## tgurr

Normalerweise ist 

```
eselect opengl
```

 dafür zuständig. Ich würde den Symlink mal wieder löschen und eselect opengl list bzw. eselect opengl set x ausprobieren.

----------

## Mr. Anderson

Danke. Leider hilft das nicht. Der Symlink zeigt jetzt auf

/usr/lib64/opengl/xorg-x11/lib/libGL.so

aber der Fehler bleibt. Seit letzter Nacht läuft nun auch ein emerge -e world.

----------

## Mr. Anderson

So weit ich das nun sehe, ist die libGL.so.1.2 von mesa in der 32-Bit-Variante aus dem Paket emul-linux-x86-xlibs inkompatibel mit dem G965-Chipsatz, da im gcc 4.x ein Bug ist (oder seit 4.2 vielleicht auch war?). Jedenfalls habe ich nach dem Gentoo Guide für "Emulation Packages" ein neues Paket erstellt, in dem ich mesa und libdrm auf die aktuelle Version im stable-Zweig gebracht und mit -fno-strict-aliasing kompiliert habe.

Das dann mit nem Overlay installiert und siehe da: das Problem ist verschwunden. Dafür habe ich nun ernsthafte Probleme mit Grafikfehlern und Abstürzen.  :Laughing: 

Wen's interessiert, konkret lief das so:

Wie beschrieben alle 7 Punkte des Howtos durchgehen

beim 7. Punkt (emerge -e world) gibt es ne Menge Fehler wegen inkompatibler Libs wie ncurses, die erst später emerged werden. Kann man in der Regel getrost ignorieren, und mit emerge --resume --skipfirst überspringen.

FEATURES="buildpkg" nicht vergessen, und wer, wie ich, noch nie vorkompilierte Pakete erstellt hat, sollte wissen, dass sich diese in /usr/portage/packages befinden.

in den CFLAGS in der /etc/make.conf "-fno-strict-aliasing" und ggf. andere Optionen eintragen (aber mit Vorsicht).

emerge mesa ausführen

chroot kann verlassen werden

Das ebuild app-emulation/emul-linux-x86-libs-10.0.ebuild ins overlay-Verzeichnis kopieren als emul-linux-x86-libs-10.1.ebuild und die Einträge für mesa und libdrm aktualisieren. Die beiden Dateien aus /usr/portage/packages/All nach /usr/portage/distfiles kopieren. digest erstellen, emergen, fertig.

----------

## Beholders_Eye

 *Quote:*   

> I can't understand dutch; could you explain what you did in English, please? I'm having exactly the same issue with wine

 

EDIT (correcting a misunderstood term: dutch --> deutsch)

I can't understand deutsch; could you explain what you did in English, please? I'm having exactly the same issue with wineLast edited by Beholders_Eye on Fri Jun 29, 2007 1:17 pm; edited 1 time in total

----------

## UTgamer

 *Beholders_Eye wrote:*   

> I can't understand dutch; could you explain what you did in English, please? I'm having exactly the same issue with wine

 

Your excused because your from the other side and in 9/10 hours difference, dutch= netherland (our neighbour), we're german=deutsch.  :Wink:  It's like Spanish and Portuguese.

Until know he coudn't solve it perfect. What he said is that he belief Intels chipset G965 is not compatible to the 32 bit emulated Mesa environment.

He did rebuild the emul-linux-x86-xlibs packages like described in this manual http://www.gentoo.org/proj/en/base/amd64/emul/ together with mesa and libdrm out of the current stable line and did compile with -fno-strict-aliasing.

Then he did note an error at point 7 from the manual.

ncurses has to be emerged later when the build process do stop, use "emerge --resume --skipfirst" to skip these failed packages and emerge them later.

When your emerge is ready do not forget to save your 32 bit binaries with: FEATURES="buildpkg", they're  no located in /usr/portage/packages.

Before emerging mesa, do not forget to set your CFLAGS in /etc/make.conf "-fno-strict-aliasing

Leave the chroot environment.

Copy the ebuild app-emulation/emul-linux-x86-libs-10.0.ebuild into your overlay directory and rename it to another version number like emul-linux-x86-libs-10.1.ebuild

Update there the entries for mesa and libdrm.

Copy the 2 files in /usr/portage/packages/All to /usr/portage/distfiles. Make digest,  emerge and your ready.

At least you can install your new overlay, but its not solved completly, because it will start but he has some not minor problems with graphic and crashes.

Did it help, when I translated it shortly?

----------

## Mr. Anderson

This is already outdated. Better you take also a look at there:

https://bugs.gentoo.org/show_bug.cgi?id=172009

----------

## Beholders_Eye

UTgamer, thanks for the lesson, when I typed I didn't have confidence in the word "dutch"  :Smile:  heheheh. And I was suspicious of the dutch=netherlands association  :Smile: .

Well, thank you two for the fastest reply ever. I'll wait until gentoo dev's do the update, or I'll try to upgrade manually my emul-x86 libs as you described.

Again, thanks a lot!

----------

## Mr. Anderson

Das Problem ist mit emul-linux-x86-xlibs-10.1 nun behoben.

This problem is now fixed with emul-linux-x86-xlibs-10.1.

----------

