Build fail - libx11.so not found

Hi,
I tried building root via cmake on a x86-Xubuntu; the build fails at around 80% done and states that it didn’t find ‘libx11.so’:

...
[ 87%] Linking CXX shared library ../../lib/libASImage.so
/usr/bin/ld: cannot find -l/usr/lib/i386-linux-gnu/libX11.so
collect2: error: ld returned 1 exit status
graf2d/asimage/CMakeFiles/ASImage.dir/build.make:175: recipe for target 'lib/libASImage.so' failed
make[2]: *** [lib/libASImage.so] Error 1
CMakeFiles/Makefile2:17473: recipe for target 'graf2d/asimage/CMakeFiles/ASImage.dir/all' failed
make[1]: *** [graf2d/asimage/CMakeFiles/ASImage.dir/all] Error 2
Makefile:149: recipe for target 'all' failed
make: *** [all] Error 2

As Xubuntu missed some libraies in advance of the build during the ccmake-configure-process I checked the folder for the missing library and it is there:

hviemann@knecht:~$ ls /usr/lib/i386-linux-gnu/ | grep libX11
libX11.a
libX11.so
libX11.so.6
libX11.so.6.3.0
libX11-xcb.so.1
libX11-xcb.so.1.0.0

So I asked ‘Google’, didn’t find anything and later realized that there seems to be a ‘blank’ missing in the statement of the missing lib: (between ‘-l’ and the path to the lib)

/usr/bin/ld: cannot find -l/usr/lib/i386-linux-gnu/libX11.so

However on the one hand this might be only a format-issue of the output to the console but on the other hand this might be a bug. If it’s a bug I cannot post it in jira as it seems that I dont have the permission to do so.
Does anybody have a guess or might be able to proof it being a bug on a x86-system?

Thanks

Maybe this could help (it looks similar): Cannot setup root / libASImage.so

Cheers, Bertrand.

Ahh, yes… I missed that. There are some packages missing. Hope this does the job.

Thanks