configure.py
changeset 7 923ff622b8b9
parent 6 c3690ec91ef8
child 8 708db231cf72
child 21 4633027730f5
child 34 ed14f46c0e55
--- a/configure.py	Wed Jun 23 18:33:25 2010 +0300
+++ b/configure.py	Tue Jul 06 14:36:53 2010 +0300
@@ -257,6 +257,7 @@
                          help="Specify the host qmake tool.")
         group.add_option("--host-make-bin", dest="hostmakebin", metavar="path",
                          help="Specify the host make tool (make, nmake, mingw32-make, gmake...).")
+        self.add_option_group(group)
         self.set_defaults(hostqmakebin=None)
         self.set_defaults(hostmakebin=None)
 
@@ -299,8 +300,13 @@
                          help="Assumes that MeeGoTouch UI is available without performing a compilation test.")
         group.add_option("--no-meegotouch", action="store_false", dest="meegotouch",
                          help="Assumes that MeeGoTouch UI is not available without performing a compilation test.")
+        group.add_option("--qt-openvg", action="store_true", dest="qtopenvg",
+                         help="Assumes that OpenVG is available without performing a compilation test.")
+        group.add_option("--no-qt-openvg", action="store_false", dest="qtopenvg",
+                         help="Assumes that OpenVG is not available without performing a compilation test.")
         self.add_option_group(group)
         self.set_defaults(qtmobility=None)
+        self.set_defaults(qtopenvg=None)
 
         group = optparse.OptionGroup(self, "Developer options")
         group.add_option("--developer", action="store_true", dest="developer",
@@ -603,11 +609,16 @@
                         code = -1
             else:
                 # on other platforms, check that the resulting executable exists
-                executable = os.path.join(builddir, "hbconftest_" + basename)
                 if os.name == "nt":
-                    executable.append(".exe")
-                if not os.path.exists(executable) or not os.access(executable, os.X_OK):
-                    code = -1
+                    executable = os.path.join(os.path.join(builddir, "debug"), "hbconftest_" + basename + ".exe")
+                    if not os.path.exists(executable) or not os.access(executable, os.X_OK):
+                        executable = os.path.join(os.path.join(builddir, "release"), "hbconftest_" + basename + ".exe")
+                        if not os.path.exists(executable) or not os.access(executable, os.X_OK):
+                            code = -1
+                else:
+                    executable = os.path.join(builddir, "hbconftest_" + basename)
+                    if not os.path.exists(executable) or not os.access(executable, os.X_OK):
+                        code = -1
 
             # clean
             run_process(MAKE.command("clean"))
@@ -709,6 +720,12 @@
     if options.qtmobility:
         config.add_value("DEFINES", "HB_HAVE_QT_MOBILITY")
     print("INFO: Qt Mobility:\t\t\t%s" % options.qtmobility)
+    if options.qtopenvg == None:
+        options.qtopenvg = test.compile("config.tests/all/openvg")
+    if options.qtopenvg:
+        config.add_value("DEFINES", "HB_EFFECTS_OPENVG")
+        config.add_value("DEFINES", "HB_FILTER_EFFECTS")
+    print("INFO: OpenVG:\t\t\t\t%s" % options.qtopenvg)
     if QMAKE.platform() == "symbian":
         sgimagelite_result = test.compile("config.tests/symbian/sgimagelite")
         if sgimagelite_result: