# HG changeset patch
# User Sylvain Thénault <sylvain.thenault@logilab.fr>
# Date 1249629395 -7200
#      Fri Aug 07 09:16:35 2009 +0200
# Node ID 66ce4c6261dfd9c7a2a52bea8af724141bbe5de4
# Parent  4811155ef54d4ebaf18db544b0f8e2ca35b94d16
make python-constraint optional

diff --git a/analyze.py b/analyze.py
--- a/analyze.py
+++ b/analyze.py
@@ -1,6 +1,6 @@
 """Analyze of the RQL syntax tree to get possible types for RQL variables.
 
-:copyright: 2003-2008 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
+:copyright: 2003-2009 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
 :contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr
 :license: General Public License version 2 - http://www.gnu.org/licenses
 """
@@ -10,8 +10,6 @@
 import warnings
 warnings.filterwarnings(action='ignore', module='logilab.constraint.propagation')
 
-from logilab.constraint import Repository, Solver, fd
-
 from rql import TypeResolverException, nodes
 from pprint import pprint
 
@@ -22,6 +20,8 @@
     import rql_solve
 except ImportError:
     rql_solve = None
+    from logilab.constraint import Repository, Solver, fd
+
     # Gecode solver not available
 #rql_solve = None # uncomment to force using logilab-constraint
 
@@ -59,7 +59,7 @@
 
     def end_domain_definition(self):
         pass
-    
+
     def get_domains(self):
         return self.domains
 
diff --git a/debian/control b/debian/control
--- a/debian/control
+++ b/debian/control
@@ -12,7 +12,7 @@
 Package: python-rql
 Architecture: any
 XB-Python-Version: ${python:Versions}
-Depends: ${python:Depends}, ${misc:Depends}, ${shlibs:Depends}, python-logilab-common (>= 0.35.3-1), python-constraint (>= 0.4.0-1), yapps2-runtime
+Depends: ${python:Depends}, ${misc:Depends}, ${shlibs:Depends}, python-logilab-common (>= 0.35.3-1), yapps2-runtime
 Provides: ${python:Provides}
 Description: relationship query language (RQL) utilities
  A library providing the base utilities to handle RQL queries,