third_party/waf: upgrade to waf 2.0.8
[bbaumbach/samba-autobuild/.git] / third_party / waf / waflib / Tools / qt5.py
index f4842a9ac5589c3eb7dc8a6fe8188f4f87cd6f77..709dd5161e37ba10dc956cc087c8ac043daed95c 100644 (file)
@@ -1,7 +1,3 @@
-#! /usr/bin/env python
-# encoding: utf-8
-# WARNING! Do not edit! https://waf.io/book/index.html#_obtaining_the_waf_file
-
 #!/usr/bin/env python
 # encoding: utf-8
 # Thomas Nagy, 2006-2018 (ita)
@@ -399,6 +395,19 @@ class rcc(Task.Task):
                                names.append(x)
                return (nodes, names)
 
+       def quote_flag(self, x):
+               """
+               Override Task.quote_flag. QT parses the argument files
+               differently than cl.exe and link.exe
+
+               :param x: flag
+               :type x: string
+               :return: quoted flag
+               :rtype: string
+               """
+               return x
+
+
 class moc(Task.Task):
        """
        Creates ``.moc`` files
@@ -406,6 +415,19 @@ class moc(Task.Task):
        color   = 'BLUE'
        run_str = '${QT_MOC} ${MOC_FLAGS} ${MOCCPPPATH_ST:INCPATHS} ${MOCDEFINES_ST:DEFINES} ${SRC} ${MOC_ST} ${TGT}'
 
+       def quote_flag(self, x):
+               """
+               Override Task.quote_flag. QT parses the argument files
+               differently than cl.exe and link.exe
+
+               :param x: flag
+               :type x: string
+               :return: quoted flag
+               :rtype: string
+               """
+               return x
+
+
 class ui5(Task.Task):
        """
        Processes ``.ui`` files
@@ -629,7 +651,6 @@ def find_single_qt5_lib(self, name, uselib, qtlibs, qtincludes, force_static):
                        for k in ('', '5') if Utils.is_win32 else ['']:
                                for p in ('lib', ''):
                                        yield (p, name, k, x)
-               raise StopIteration
 
        for tup in lib_names():
                k = ''.join(tup)