My problem is that the SDK fails to build under SLC5 (Scientific Linux 5.4). SLC is a redhat based distro, so I downloaded the matching red hat SDK and I get the following error while building one of the samples:
g++ -o build/debug/x86_64/Mandelbrot build/debug/x86_64//Mandelbrot.o build/debug/x86_64//MandelbrotDisplay.o -lpthread -ldl -L/usr/X11R6/lib -lOpenCL -lSDKUtil -lglut -lGLEW -L../../../../../lib/x86_64 -L../../../../../TempSDKUtil/lib/x86_64
../../../../../lib/x86_64/libglut.so: undefined reference to `XF86VidModeGetViewPort'
../../../../../lib/x86_64/libglut.so: undefined reference to `XF86VidModeGetAllModeLines'
../../../../../lib/x86_64/libglut.so: undefined reference to `XF86VidModeSwitchToMode'
../../../../../lib/x86_64/libglut.so: undefined reference to `XF86VidModeSetViewPort'
../../../../../lib/x86_64/libglut.so: undefined reference to `XF86VidModeGetModeLine'
The missing references are found in the xf86vmode.h header file which is in the proper place in /usr/include/X11/extensions/xf86vmode.h location. How can I make the SDK aware of these headers?
This issue was reported and fixed internally. You expect this to be resolved in an upcoming release. Meanwhile you can try changing the glut library which comes with the SDK and see if it helps.
Thank you for the tip, I've changed the library and it compiled allright.
Nontheless, I am still unable to build a single openCL program under linux. I tried under Ubuntu 9.10, which is stuck at a point mentioned in the "Radeon 5970 unrecognized under Ubuntu" thread, and now SLC5, where clGetPlatformIDs() fail with errorcode -1001 right at the beggining querying numPlatforms, which wasn't a problem before.
Now I have and now the samples don't find a single CL_DEVICE_TYPE_GPU, and the cal FindNumDevices sample returns 0 devices too. I have the ati driver installed and it gives
[root@opal4 prog1]# aticonfig --list-adapters
* 0. 0e:00.0 ATI Radeon HD 5900 Series
1. 07:00.0 ATI Radeon HD 5900 Series
2. 0a:00.0 ATI Radeon HD 5900 Series
3. 0b:00.0 ATI Radeon HD 5900 Series
4. 06:00.0 ATI Radeon HD 5900 Series
5. 0f:00.0 ATI Radeon HD 5900 Series
* - Default adapter
SLC5 could not use the cards for desktop acceleration, so xserver runs in default software rendered mode. (no Overdrive functions available to get more info from the cards)
I have 3 5970 cards, so the 6 reported adapters by the driver seems fine. I had the same issues under Ubuntu, that no devices were found whatsoever. That was when I tried having a single card and two cards in at a time. The device counts and reports were completely hectic and had little in common with reality. I posted those results in the other thread mentioned above.