EGLConfig on linux

I’ve got an existing OpenGL Linux application that I’m trying to port to use OpenGL ES 2 / EGL on a Linux PC emulator. However, it appears that some of the XWindows calls (e.g. XCreateWindow) take XVisualInfo members as arguments (e.g. visual, depth). But since I’m trying to use EGL I thought I was supposed to use eglChooseConfig instead of XGetVisualInfo.

When running on Linux is the void* used for EGLConfig the same as XVisualInfo? In other words, can I take the value returned by eglChooseConfig and type cast it to a XVisualInfo so that I can pass it as an argument to the XWindows calls?

If not, how does I get around this?