Testnative: undefined reference to `XDestroyWindow' and others

Building the official SDL2 release on Xubuntu and the ‘testnative’ test
fails to build. Some other tests do build and run, it just fails at this
point in the build

Tried on 12.10 (virtual machine) and 13.10 (alpha) live CD.–
simon at simon-virtual-machine:~/SDL2-2.0.0/test$ make
gcc -o testnative testnative.c testnativex11.c -g -O2 -D_REENTRANT
-I/usr/include/SDL2 -DHAVE_OPENGLES -lSDL2_test -Wl,-rpath,/usr/lib
-lSDL2 -lpthread
/tmp/cc8JHdx5.o: In function DestroyWindowX11': /home/simon/SDL2-2.0.0/test/testnativex11.c:48: undefined reference toXDestroyWindow’
/tmp/cc8JHdx5.o: In function CreateWindowX11': /home/simon/SDL2-2.0.0/test/testnativex11.c:33: undefined reference toXOpenDisplay’
/home/simon/SDL2-2.0.0/test/testnativex11.c:35: undefined reference to
XCreateSimpleWindow' /home/simon/SDL2-2.0.0/test/testnativex11.c:38: undefined reference toXMapRaised’
/home/simon/SDL2-2.0.0/test/testnativex11.c:39: undefined reference to
XSync' /tmp/cc8JHdx5.o: In functionDestroyWindowX11’:
/home/simon/SDL2-2.0.0/test/testnativex11.c:49: undefined reference to
`XCloseDisplay’
collect2: error: ld returned 1 exit status
make: *** [testnative] Error 1

Cheers,
Simon