Having trouble getting KMS mode to work on Slackware-Current (SOLVED)

Kernel: 3.10.7 Mesa: 9.1.6 libdrm: 2.4.46

Using i915 driver on Intel HD3000 graphics

Slackware’s mesa package didn’t ship with libgbm, so I recompiled it with ‘–enable-gbm’. That worked fine, then I compiled RetroArch

retroarch --features shows:


Features:
    SDL:
        SDL drivers: yes
    Threads:
        Threading support: yes
    OpenGL:
        OpenGL driver: yes
    KMS:
        KMS/EGL context support: yes
    EGL:
        EGL context support: yes
    OpenVG:
        OpenVG output support: no
    XVideo:
        XVideo output: yes
    ALSA:
        audio driver: yes
    OSS:
        audio driver: yes
    Jack:
        audio driver: no
    RSound:
        audio driver: no
    RoarAudio:
        audio driver: no
    PulseAudio:
        audio driver: no
    DirectSound:
        audio driver: no
    XAudio2:
        audio driver: no
    zlib:
        PNG encode/decode and .zip extraction: yes
    OpenAL:
        audio driver: no
    External:
        External filter and plugin support: yes
    Cg:
        Cg pixel shaders: yes
    libxml2:
        libxml2 XML parsing: yes
    SDL_image:
        SDL_image image loading: yes
    FBO:
        OpenGL render-to-texture (multi-pass shaders): yes
    Dynamic:
        Dynamic run-time loading of libretro library: yes
    FFmpeg:
        On-the-fly recording of gameplay with libavcodec: no
    FreeType:
        TTF font rendering with FreeType: yes
    Netplay:
        Peer-to-peer netplay: yes
    Python:
        Script support in shaders: no

but when I run it outside of X it segfaults. dmesg shows this:


[ 3992.329197] retroarch[26718]: segfault at 0 ip 00007fcfe7e036a7 sp 00007fff19a309e8 error 4 in libX11-xcb.so.1.0.0[7fcfe7e03000+1000]

Any idea what I’m doing wrong?

Thanks

Your libX11 might be broken, because it tried GLX before KMS. You can force the context you want with:

video_gl_context = kms-egl

in config.

Managed to get it working.

Mesa had to be compiled with ‘–with-egl-platforms=x11,drm’ I guess before it was building with just the X11 driver and that’s why it was failing.

Thanks for the help