Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-dev: Re: [Wireshark-dev] Build problems with qt

From: Evan Huus <eapache@xxxxxxxxx>
Date: Tue, 23 Jul 2013 09:26:59 -0400
Some of these errors look a bit like the ones I've been fighting,
where the moc and uic binaries are Qt4 but the main include paths are
Qt5 (I also had the opposite problem briefly: moc and uic were Qt5 but
the main include paths were Qt4).

It may be worth checking what paths and versions all of those are to
make sure they line up.

Evan

On Tue, Jul 23, 2013 at 7:03 AM, Joerg Mayer <jmayer@xxxxxxxxx> wrote:
> Hello,
>
> building (with qt5) currently fails (clang++)
>
> Ciao
>       Jörg
>
> [  0%] Building CXX object ui/qt/CMakeFiles/qtui.dir/summary_dialog.cpp.o
> /home/jmayer/work/wireshark/svn/trunk/ui/qt/summary_dialog.cpp:67:5: error: no matching member function for call to 'connect'
>     connect(bRefresh, SIGNAL(clicked()), this, SLOT(RefreshData()));
>     ^~~~~~~
> /usr/include/QtCore/qobject.h:199:36: note: candidate function not viable: cannot convert argument of incomplete type 'QPushButton *' to 'const QObject *'
>     static QMetaObject::Connection connect(const QObject *sender, const char *signal,
>                                    ^
> /usr/include/QtCore/qobject.h:202:36: note: candidate function not viable: cannot convert argument of incomplete type 'QPushButton *' to 'const QObject *'
>     static QMetaObject::Connection connect(const QObject *sender, const QMetaMethod &signal,
>                                    ^
> /usr/include/QtCore/qobject.h:418:41: note: candidate function not viable: cannot convert argument of incomplete type 'QPushButton *' to 'const QObject *'
> inline QMetaObject::Connection QObject::connect(const QObject *asender, const char *asignal,
>                                         ^
> /usr/include/QtCore/qobject.h:215:43: note: candidate template ignored: substitution failure [with Func1 = const char *, Func2 = const char *]: no type named 'Object' in 'QtPrivate::FunctionPointer<const char *>'
>     static inline QMetaObject::Connection connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
>                                           ^                                                         ~~~~~~
> /usr/include/QtCore/qobject.h:245:13: note: candidate function template not viable: requires 3 arguments, but 4 were provided
>             connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal, Func2 slot)
>             ^
> /usr/include/QtCore/qobject.h:268:13: note: candidate function template not viable: requires 3 arguments, but 4 were provided
>             connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal, Func2 slot)
>             ^
> /home/jmayer/work/wireshark/svn/trunk/ui/qt/summary_dialog.cpp:70:5: error: no matching member function for call to 'connect'
>     connect(bCopyComment, SIGNAL(clicked()), this, SLOT(CopyComment()));
>     ^~~~~~~
> /usr/include/QtCore/qobject.h:199:36: note: candidate function not viable: cannot convert argument of incomplete type 'QPushButton *' to 'const QObject *'
>     static QMetaObject::Connection connect(const QObject *sender, const char *signal,
>                                    ^
> /usr/include/QtCore/qobject.h:202:36: note: candidate function not viable: cannot convert argument of incomplete type 'QPushButton *' to 'const QObject *'
>     static QMetaObject::Connection connect(const QObject *sender, const QMetaMethod &signal,
>                                    ^
> /usr/include/QtCore/qobject.h:418:41: note: candidate function not viable: cannot convert argument of incomplete type 'QPushButton *' to 'const QObject *'
> inline QMetaObject::Connection QObject::connect(const QObject *asender, const char *asignal,
>                                         ^
> /usr/include/QtCore/qobject.h:215:43: note: candidate template ignored: substitution failure [with Func1 = const char *, Func2 = const char *]: no type named 'Object' in 'QtPrivate::FunctionPointer<const char *>'
>     static inline QMetaObject::Connection connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
>                                           ^                                                         ~~~~~~
> /usr/include/QtCore/qobject.h:245:13: note: candidate function template not viable: requires 3 arguments, but 4 were provided
>             connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal, Func2 slot)
>             ^
> /usr/include/QtCore/qobject.h:268:13: note: candidate function template not viable: requires 3 arguments, but 4 were provided
>             connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal, Func2 slot)
>             ^
> 2 errors generated.
> make[2]: *** [ui/qt/CMakeFiles/qtui.dir/summary_dialog.cpp.o] Error 1
> [  0%] Building CXX object ui/qt/CMakeFiles/qtui.dir/wireshark_application.cpp.o
> /home/jmayer/work/wireshark/svn/trunk/ui/qt/wireshark_application.cpp:489:59: error: missing sentinel in function call [-Werror,-Wsentinel]
>             new_last_open_dir = g_strconcat(dir_name, NULL);
>                                                           ^
>                                                           , NULL
> /usr/include/glib-2.0/glib/gstrfuncs.h:199:22: note: function has been explicitly marked sentinel here
> gchar*                g_strconcat      (const gchar *string1,
>                       ^
> /home/jmayer/work/wireshark/svn/trunk/ui/qt/wireshark_application.cpp:493:68: error: missing sentinel in function call [-Werror,-Wsentinel]
>                                             G_DIR_SEPARATOR_S, NULL);
>                                                                    ^
>                                                                    , NULL
> /usr/include/glib-2.0/glib/gstrfuncs.h:199:22: note: function has been explicitly marked sentinel here
> gchar*                g_strconcat      (const gchar *string1,
>                       ^
> 2 errors generated.
> make[2]: *** [ui/qt/CMakeFiles/qtui.dir/wireshark_application.cpp.o] Error 1
> make[2]: Target `ui/qt/CMakeFiles/qtui.dir/build' not remade because of errors.
> make[1]: *** [ui/qt/CMakeFiles/qtui.dir/all] Error 2
> make[1]: Target `ui/qt/all' not remade because of errors.
> make: *** [all] Error 2
> make: Target `default_target' not remade because of errors.
> --
> Joerg Mayer                                           <jmayer@xxxxxxxxx>
> We are stuck with technology when what we really want is just stuff that
> works. Some say that should read Microsoft instead of technology.
> ___________________________________________________________________________
> Sent via:    Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx>
> Archives:    http://www.wireshark.org/lists/wireshark-dev
> Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
>              mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe