qmake error: sible braces mismatch %s:%d

I’ve just received this error with qmake on windows. Googling for it showed no results so after i’ve solved the problem i decided to put it here.

The error was near a conditional block like:

  1.  
  2. unix{
  3. }
  4. win32{
  5.   QMAKE_UIC+ = -L ../bin/plugin
  6. }
  7.  

…after searching for unclosed/missing braces for a while without any result and comparing svn versions i’ve finally found the problem. On the QMAKE_UIC linke instead of “+=” somehow ( probably kdevelop’s qmake parser/generator ) got saved as “+ =” (notice the space). The problem would have been much easier to solve if the error message wasn’t so misleading.

  1.  
  2. #bad version
  3. QMAKE_UIC + = -L ../bin/plugin
  4. #good version
  5. QMAKE_UIC += -L ../bin/plugin
  6.  

So if you see this error look for operators that might have a space inserted in the middle. Hope this will save somebody’s time.

Tags:, , , ,

Related:

Topics: Qt & boost


Leave a Reply