mesa_glthread breaks wine tests
Enabling mesa_glthread by default with d6fabe49 broke Wine's d3d tests. Among the tests that used to work before and are broken now are the lighting and fog tests in ddraw{2, 4, 7}, d3d8 and d3d9.
The failing lines, in the ddraw2 test:
ddraw2.c:8047: Test failed: Unlit quad without normals has color 0x00ffffff.
ddraw2.c:8049: Test failed: Lit quad without normals has color 0x00ffffff.
ddraw2.c:8432: Test failed: Expected color 0x003c3c3c at location (160, 120), got 0x00ffffff, case 0.
ddraw2.c:8432: Test failed: Expected color 0x00717171 at location (320, 120), got 0x00ffffff, case 0.
ddraw2.c:8432: Test failed: Expected color 0x003c3c3c at location (480, 120), got 0x00ffffff, case 0.
ddraw2.c:8432: Test failed: Expected color 0x00717171 at location (160, 240), got 0x00ffffff, case 0.
ddraw2.c:8432: Test failed: Expected color 0x00717171 at location (480, 240), got 0x00ffffff, case 0.
ddraw2.c:8432: Test failed: Expected color 0x003c3c3c at location (160, 360), got 0x00ffffff, case 0.
ddraw2.c:8432: Test failed: Expected color 0x00717171 at location (320, 360), got 0x00ffffff, case 0.
ddraw2.c:8432: Test failed: Expected color 0x003c3c3c at location (480, 360), got 0x00ffffff, case 0.
How to run the test? Build wine, run 'make test' in e.g. dlls/ddraw/tests. I can post more if necessary. Note that the ddraw test files are huge, but each function is an individual, stand alone test. You can cut down run time and remove annoying screen switching by #if 0'ing tests at the bottom of the file.