summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorBill King <bill.king@nokia.com>2009-05-28 01:12:26 (GMT)
committerBill King <bill.king@nokia.com>2009-05-28 01:12:26 (GMT)
commit8aef511877d460e4d7e75c978142f1ca3bd50451 (patch)
tree78362c8a123dce23991f0d6e0200db4e13278650 /configure
parentfcfdccc03b6dd26a82e87a6b6a0ca48d67f78cf6 (diff)
downloadQt-8aef511877d460e4d7e75c978142f1ca3bd50451.zip
Qt-8aef511877d460e4d7e75c978142f1ca3bd50451.tar.gz
Qt-8aef511877d460e4d7e75c978142f1ca3bd50451.tar.bz2
Adds support for linking against iodbc on linux.
If unixodbc detection fails, try and link/detect iodbc libraries and link against them. Reviewed-by: Lincoln Ramsay
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure25
1 files changed, 18 insertions, 7 deletions
diff --git a/configure b/configure
index 85ce3da..764840e 100755
--- a/configure
+++ b/configure
@@ -716,6 +716,7 @@ QT_LFLAGS_MYSQL=
QT_LFLAGS_MYSQL_R=
QT_CFLAGS_SQLITE=
QT_LFLAGS_SQLITE=
+QT_LFLAGS_ODBC="-lodbc"
# flags for libdbus-1
QT_CFLAGS_DBUS=
@@ -4431,14 +4432,21 @@ for _SQLDR in $CFG_SQL_AVAILABLE; do
CFG_SQL_odbc=plugin
fi
else
- if [ "$CFG_SQL_odbc" != "auto" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
- echo "ODBC support cannot be enabled due to functionality tests!"
- echo " Turn on verbose messaging (-v) to $0 to see the final report."
- echo " If you believe this message is in error you may use the continue"
- echo " switch (-continue) to $0 to continue."
- exit 101
+ if "$unixtests/compile.test" "$XQMAKESPEC" "$QMAKE_CONFIG" $OPT_VERBOSE "$relpath" "$outpath" config.tests/unix/iodbc "iODBC" $L_FLAGS $I_FLAGS $l_FLAGS $MAC_ARCHS_COMMANDLINE; then
+ QT_LFLAGS_ODBC="-liodbc"
+ if [ "$CFG_SQL_odbc" = "auto" ]; then
+ CFG_SQL_odbc=plugin
+ fi
else
- CFG_SQL_odbc=no
+ if [ "$CFG_SQL_odbc" != "auto" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
+ echo "ODBC support cannot be enabled due to functionality tests!"
+ echo " Turn on verbose messaging (-v) to $0 to see the final report."
+ echo " If you believe this message is in error you may use the continue"
+ echo " switch (-continue) to $0 to continue."
+ exit 101
+ else
+ CFG_SQL_odbc=no
+ fi
fi
fi
fi
@@ -6684,6 +6692,9 @@ fi
if [ -n "$QT_LFLAGS_SQLITE" ]; then
echo "QT_LFLAGS_SQLITE = $QT_LFLAGS_SQLITE" >> "$CACHEFILE.tmp"
fi
+if [ -n "$QT_LFLAGS_ODBC" ]; then
+ echo "QT_LFLAGS_ODBC = $QT_LFLAGS_ODBC" >> "$CACHEFILE.tmp"
+fi
if [ "$QT_EDITION" != "QT_EDITION_OPENSOURCE" ]; then
echo "DEFINES *= QT_EDITION=QT_EDITION_DESKTOP" >> "$CACHEFILE.tmp"