[libgda] Correction for bug #684583



commit 55226cd1343dd3eef3f697400f7b5fe68194b1c6
Author: Vivien Malerba <malerba gnome-db org>
Date:   Wed Sep 26 21:27:56 2012 +0200

    Correction for bug #684583
    
    Firebird provider is searched for fisrt using pkg-config and if not
    found using the existing tests

 m4/firebird.m4 |   22 +++++++++++++++++++++-
 1 files changed, 21 insertions(+), 1 deletions(-)
---
diff --git a/m4/firebird.m4 b/m4/firebird.m4
index 6a166bd..933962d 100644
--- a/m4/firebird.m4
+++ b/m4/firebird.m4
@@ -82,6 +82,7 @@ m4_define([_FIREBIRD_CHECK_INTERNAL],
     # determine if Firebird should be searched for
     firebird_found=no
     try_firebird=true
+    pkgfirebird=no
     firebird_test_dir="$FIREBIRD_HOME /usr /opt/firebird /local"
     AC_ARG_WITH(firebird,
               AS_HELP_STRING([--with-firebird[=@<:@yes/no/<directory>@:>@]],
@@ -98,9 +99,28 @@ m4_define([_FIREBIRD_CHECK_INTERNAL],
                              [Locate FIREBIRD library file, related to the prefix specified from --with-firebird]),
 			     [firebird_loclibdir=$withval])
 
-    # try to locate files
+    # try with pkgconfig
     if test $try_firebird = true
     then
+        PKG_CHECK_MODULES(FIREBIRD_CLIENT, "fbclient",[pkgfbclient=yes],[pkgfbclient=no])
+        PKG_CHECK_MODULES(FIREBIRD_EMBED, "fbembed",[pkgfbembed=yes],[pkgfbembed=no])
+        if test $pkgfbclient = yes -o $pkgfbembed = yes
+        then
+	    pkgfirebird=yes
+        fi
+	if test $pkgfbclient = yes
+	then
+	    firebird_client_found=yes
+	fi
+	if test $pkgfbembed = yes
+	then
+	    firebird_embed_found=yes
+	fi
+    fi
+
+    # try to locate files
+    if test $try_firebird = true -a $pkgfirebird = no
+    then
 	if test "x$linklibext" = x
 	then
 	    if test $platform_win32 = yes



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]