-fPIC is for position independent code, which should not be necessary when building an executable program (or at least, not explicitly). Also, for GCC, I used "gcc -static"
Patrick On Mon, Dec 3, 2012 at 4:55 AM, Yasir I. Al-Dosary - zgzg2020™ < yasiraldos...@yahoo.com> wrote: > Hi > > I would like to cross-compile ioquake3 with static libraries. I tried > -static and -fPIC, but got an error: > relocation R_X86_64_32 can not be used when making a shared object; > recompile with -fPIC > Then, I also tried -Bstatic, and NOSHARED=0, which didn't do anything. > What are the correct flags? > Mine: > make USE_LOCAL_HEADERS=0 CFLAGS='-fopenmp -Wall -D_GNU_SOURCE=1 > -D_REENTRANT' USE_VOIP=0 BUILD_CLIENT=0 BUILD_MISSIONPACK=0 BUILD_GAME_QVM=0 > > The story: > > After doing the cross-compiling, the library versions were different > between the cross-compiling machine, and the executing machine. > I don't have authority to up/downgrade any of the libraries. Furthermore, > I tried to build the glibc library, which took FOREVER. But, kept failing > because the GCC was too old. > Anyway to make a long story short, someone suggested that I should try to > statically cross-compile ioquake3, so that it would run regardless of the > version discrepancies. > Version error: > ./ioq3ded.sh4a: /lib/libc.so.6: version `GLIBC_2.11' not found (required > by ./ioq3ded.sh4a) > _______________________________________________ > ioquake3 mailing list > ioquake3@lists.ioquake.org > http://lists.ioquake.org/listinfo.cgi/ioquake3-ioquake.org > By sending this message I agree to love ioquake3 and libsdl. >
_______________________________________________ ioquake3 mailing list ioquake3@lists.ioquake.org http://lists.ioquake.org/listinfo.cgi/ioquake3-ioquake.org By sending this message I agree to love ioquake3 and libsdl.