wgois / OIS

Official OIS repository. Object oriented Input System

Home Page:https://wgois.github.io/OIS/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Build fail on multilib systems without LDFLAGS

orbea opened this issue · comments

commented

OS: Slackware64-current

When building the OIS master on a multilib Slackware64-current it will fail to build during the linking stage because it is trying to use /usr/lib/libX11.so instead of the correct /usr/lib64/libX11.so.

This can be worked around by adding LDFLAGS="-L/usr/lib${LIBDIRSUFFIX}" \ to the slackbuild, but is there a more complete solution so that this will not happen?

/bin/sh ../libtool  --tag=CXX   --mode=link g++  -g -O2 -release 1.4.0   -o libOIS.la -rpath /usr/lib64 OISInputManager.lo OISObject.lo OISEffect.lo OISJoyStick.lo OISKeyboard.lo OISForceFeedback.lo OISException.lo EventHelpers.lo LinuxInputManager.lo LinuxJoyStickEvents.lo LinuxForceFeedback.lo LinuxKeyboard.lo LinuxMouse.lo  -L/usr/X11R6/lib -lX11 
libtool: link: g++  -fPIC -DPIC -shared -nostdlib /usr/lib64/gcc/x86_64-slackware-linux/5.4.0/../../../../lib64/crti.o /usr/lib64/gcc/x86_64-slackware-linux/5.4.0/crtbeginS.o  .libs/OISInputManager.o .libs/OISObject.o .libs/OISEffect.o .libs/OISJoyStick.o .libs/OISKeyboard.o .libs/OISForceFeedback.o .libs/OISException.o .libs/EventHelpers.o .libs/LinuxInputManager.o .libs/LinuxJoyStickEvents.o .libs/LinuxForceFeedback.o .libs/LinuxKeyboard.o .libs/LinuxMouse.o   -Wl,-rpath -Wl,/usr/lib64/../lib -Wl,-rpath -Wl,/usr/lib64/../lib -L/usr/X11R6/lib /usr/lib/libX11.so /usr/lib/libxcb.so /usr/lib/libXau.so /usr/lib/libXdmcp.so -ldl -L/usr/lib64/gcc/x86_64-slackware-linux/5.4.0 -L/usr/lib64/gcc/x86_64-slackware-linux/5.4.0/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/lib64/gcc/x86_64-slackware-linux/5.4.0/../../../../x86_64-slackware-linux/lib -L/usr/lib64/gcc/x86_64-slackware-linux/5.4.0/../../.. /usr/lib64/../lib/libstdc++.so -lm -lc -lgcc_s /usr/lib64/gcc/x86_64-slackware-linux/5.4.0/crtendS.o /usr/lib64/gcc/x86_64-slackware-linux/5.4.0/../../../../lib64/crtn.o  -g -O2   -Wl,-soname -Wl,libOIS-1.4.0.so -o .libs/libOIS-1.4.0.so
/usr/lib/libX11.so: error adding symbols: File in wrong format
collect2: error: ld returned 1 exit status
Makefile:424: recipe for target 'libOIS.la' failed
make[1]: *** [libOIS.la] Error 1
make[1]: Leaving directory '/tmp/SBo/ois-v1-3/src'
Makefile:440: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

CMake now takes care of this. Closing.

commented

Cheers, its good to have this issue and the associated PR not sitting around collecting dust anymore. :)