--- qsampler/trunk/configure.ac 2010/10/06 18:49:54 2144 +++ qsampler/trunk/configure.ac 2013/11/01 17:44:30 2480 @@ -1,5 +1,5 @@ # Process this file with autoconf to produce a configure script. -AC_INIT(Qsampler, 0.2.2.27, rncbc@rncbc.org, qsampler) +AC_INIT(Qsampler, 0.2.2.41, rncbc@rncbc.org, qsampler) AC_CONFIG_SRCDIR(src/qsampler.cpp) AC_CONFIG_HEADERS(src/config.h) @@ -47,7 +47,7 @@ # Some a-la-debian alternatives... for X in /usr/lib /usr/lib64 /usr/share; do - for Y in qt qt4; do + for Y in qt qt4 qt5; do if test -d $X/$Y/bin; then ac_with_paths="$ac_with_paths $X/$Y" fi @@ -87,11 +87,11 @@ if test -d $X/bin; then ac_path="$X/bin:$ac_path" fi - if test -x $X/qmake; then - ac_path="$X:$ac_path" - fi +# if test -x $X/qmake; then +# ac_path="$X:$ac_path" +# fi if test -d $X/include; then - for Y in qt qt4; do + for Y in qt qt4 qt5; do if test -d $X/include/$Y; then CFLAGS="-I$X/include/$Y $CFLAGS" CPPFLAGS="-I$X/include/$Y $CPPFLAGS" @@ -112,15 +112,22 @@ fi done +# Check for proper flags. +ac_arch=`uname -m` +if test "$ac_arch" == "x86_64"; then + CFLAGS="-fPIC $CFLAGS" + CPPFLAGS="-fPIC $CPPFLAGS" +fi + # Check for proper Qt version. -AC_CACHE_CHECK([for Qt library version >= 4.2], +AC_CACHE_CHECK([for Qt library version >= 4.4], ac_cv_qtversion, [ - AC_TRY_LINK([#include "Qt/qglobal.h"], [ -#if QT_VERSION < 0x040200 -#error Qt library 4.2 or greater required. + AC_TRY_LINK([#include "QtCore/qglobal.h"], [ +#if QT_VERSION < 0x040400 +#error Qt library 4.4 or greater required. #endif ], ac_cv_qtversion="yes", [ - echo "no; Qt 4.2 or greater is required" + echo "no; Qt 4.4 or greater is required" exit ]) ])