X Keyboard Extension version mismatch

I want to use calls from the X Keyboard Extension, but get "library version mismatch" error.

First one is XkbLibraryVersion(..). This one already returns false.
Then I call XkbOpenDisplay(...) which does not return a valid display; return value is XkbOD_NonXkbServer. If I open the display with XOpenDisplay and then call XkbQueryExtension(...) the return value is false and the major and minor are 0. The error code then is XkbOD_BadLibraryVersion.

Who can help???

How can I specify the version of the installed X keyboard extension? Where do I get a correct version to use? I can use the code on Linux (FC3) but not on HP-UX, Solaris or AIX!!

Thanks!