r7845 - Compile error on OSX + llvm-gcc in Q_gui2_menu.cpp

Started by nibbles, April 03, 2012, 05:11:40 AM

Previous topic - Next topic

nibbles

Thank you for all your work recently.  I am compiling against Qt-4.8.1.
I'm getting a build error in r7845 on OSX that looks minor, but I'm unfamiliar with it.
I think this began in:  http://svn.berlios.de/viewvc/avidemux?view=revision&revision=7824
This is the full build log from stdout: https://raw.github.com/gist/2289398
And here is the specific error I see:

/tmp/homebrew-avidemux3-2.6-G5Re/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp: In member function ââ,¬Ëœvoid MainWindow::addScriptEnginesToFileMenu(std::vector<MenuEntry, std::allocator<MenuEntry> >&)ââ,¬â,,¢:
/tmp/homebrew-avidemux3-2.6-G5Re/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:58: error: expected primary-expression before ââ,¬Ëœ{ââ,¬â,,¢ token
/tmp/homebrew-avidemux3-2.6-G5Re/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:74: error: expected primary-expression before ââ,¬Ëœ{ââ,¬â,,¢ token
/tmp/homebrew-avidemux3-2.6-G5Re/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:75: error: expected primary-expression before ââ,¬Ëœ{ââ,¬â,,¢ token
/tmp/homebrew-avidemux3-2.6-G5Re/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:76: error: expected primary-expression before ââ,¬Ëœ{ââ,¬â,,¢ token
make[2]: *** [ADM_userInterfacesQT4/ADM_gui/CMakeFiles/ADM_guiQt4.dir/Q_gui2_menu.cpp.o] Error 1
make[1]: *** [ADM_userInterfacesQT4/ADM_gui/CMakeFiles/ADM_guiQt4.dir/all] Error 2
make: *** [all] Error 2



If instead I compile with clang, I get a bit more descriptive error analysis:
/tmp/homebrew-avidemux3-2.6-ZAeD/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:58:28: error: unexpected type name 'MenuEntry': expected expression
                                        fileMenu.begin() + i, MenuEntry {MENU_SEPARATOR, "-", NULL, ACT_DUMMY, NULL, NULL});
                                                              ^
/tmp/homebrew-avidemux3-2.6-ZAeD/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:74:30: error: unexpected type name 'MenuEntry': expected expression
                                it = fileMenu.insert(it, MenuEntry {MENU_SUBMENU, itemName, NULL, ACT_DUMMY, NULL, NULL});
                                                         ^
/tmp/homebrew-avidemux3-2.6-ZAeD/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:75:34: error: unexpected type name 'MenuEntry': expected expression
                                it = fileMenu.insert(it + 1, MenuEntry {MENU_SUBACTION, "Run Project...", NULL, firstMenuId, NULL, NULL});
                                                             ^
/tmp/homebrew-avidemux3-2.6-ZAeD/avidemux/qt4/ADM_userInterfaces/ADM_gui/Q_gui2_menu.cpp:76:34: error: unexpected type name 'MenuEntry': expected expression
                                it = fileMenu.insert(it + 1, MenuEntry {MENU_SUBACTION, "Save as Project...", NULL, (Action)(firstMenuId + 2), NULL, NULL});
                                                             ^
1 warning and 4 errors generated.
make[2]: *** [ADM_userInterfacesQT4/ADM_gui/CMakeFiles/ADM_guiQt4.dir/Q_gui2_menu.cpp.o] Error 1


gruntster

Looks like I've used C++11 syntax and Apple mustn't support it yet.  I'll take a look.