Hello everyone, I will state right from the beginning I am not a trained programmer and I am trying my best to learn as I go. Anyway, I have an application that I am trying to compile for distribution across a few distributions of Linux. I am running into problems with dependencies on particular libraries. If I compile the application normally it links (forgive me if I mix up the terms) against the libraries on the system I am compiling on. For instance here is an ldd of the application on the compiler system:
ldd vtpos
libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x4002e000)
libXm.so.2 => /usr/X11R6/lib/libXm.so.2 (0x400f8000)
libXt.so.6 => /usr/X11R6/lib/libXt.so.6 (0x40274000)
libXft.so.2 => /usr/X11R6/lib/libXft.so.2 (0x402c5000)
libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0x402d7000)
libz.so.1 => /usr/lib/libz.so.1 (0x40341000)
libXrender.so.1 => /usr/X11R6/lib/libXrender.so.1 (0x40352000)
libm.so.6 => /lib/libm.so.6 (0x4035a000)
libc.so.6 => /lib/libc.so.6 (0x4037e000)
libdl.so.2 => /lib/libdl.so.2 (0x4049b000)
libSM.so.6 => /usr/X11R6/lib/libSM.so.6 (0x4049f000)
libICE.so.6 => /usr/X11R6/lib/libICE.so.6 (0x404a7000)
libXp.so.6 => /usr/X11R6/lib/libXp.so.6 (0x404bf000)
libXext.so.6 => /usr/X11R6/lib/libXext.so.6 (0x404c7000)
libfontconfig.so.1 => /usr/X11R6/lib/libfontconfig.so.1 (0x404d6000)
libexpat.so.0 => /usr/lib/libexpat.so.0 (0x404fd000)
/lib/ld-linux.so.2 (0x40000000)
In particular the box I want to distribute this to lacks libXft.so.2, it has libxft.so.1 on it. Initially when I tried to distribute this to the other system there was an issue with libstdc++.so.5, but I was able to solve that by statically linking the binary by adding the following to my "LINK" line in the Makefile after creating a symlink for libstdc++.a "-static-libgcc -L.". Now the box that I am compiling on has libxft.so.1 and libxft.so.2, so my question is how do I get this application to either link against .so.1 or statically compile it? I have tried a bunch of methods but I am just so lost. I know this application can be compiled without the need for libxft.so.2 since I have a pre-compiled version from the same source code that does not depend on it that was created by a former programmer that we no longer employ. Please help?