From: lbessard Date: Fri, 22 Aug 2008 12:17:31 +0000 (+0000) Subject: Bug with x86_64 and gcc without -fPIC cflags fixed X-Git-Url: https://rtime.felk.cvut.cz/gitweb/CanFestival-3.git/commitdiff_plain/c1dcde98f5a8a4cf26069a04c183012c8f9cc0f7?ds=sidebyside Bug with x86_64 and gcc without -fPIC cflags fixed --- diff --git a/configure b/configure index 0c62ce3..983391f 100755 --- a/configure +++ b/configure @@ -246,12 +246,6 @@ fi echo "Host OS: ${SUB_OS_NAME}" echo "Host arch: ${SUB_ARCH_NAME}" -if [ "$SUB_ARCH_NAME" = "x86_64" -a "$CC" = "gcc" ]; then - # Only if we are on x86_64 and using gcc - # For shared library generation, it needs this - SUB_PROG_CFLAGS=-fPIC -fi - if [ "$SUB_ARCH_NAME" = "ppc" -o "$SUB_ARCH_NAME" = "powerpc" ]; then # PowerPC uses big endian format CANOPEN_BIG_ENDIAN=1 @@ -516,6 +510,12 @@ fi echo "Using ${CC} as a C compiler" +if [ "$SUB_ARCH_NAME" = "x86_64" -a "$CC" = "gcc" ]; then + # Only if we are on x86_64 and using gcc + # For shared library generation, it needs this + SUB_PROG_CFLAGS=-fPIC +fi + if [ "$BINUTILS_PREFIX" = "" ]; then SUB_BINUTILS_PREFIX=`echo "$CC" | sed 's/gcc$//'` else