Ask Your Question
0

Wireshark build on MacOS fails.

asked 2024-07-01 19:02:45 +0000

joshua gravatar image

updated 2024-07-02 00:26:43 +0000

cmaynard gravatar image

Hi everyone,

I am trying to build Wireshark on a Mac and have successfully installed Qt 6.5.3, run the tools/macos-setup-brew.sh script and run the cmake -G Ninja .. in the build directory which is a subdirectory of the source directory. When I try to run Ninja to build Wireshark, I get the following error message and the build then stops:

[2516/2765] Building CXX object ui/qt/CMakeFiles/qtui.dir/capture_comment_dialog.cpp.o
FAILED: ui/qt/CMakeFiles/qtui.dir/capture_comment_dialog.cpp.o 
/Library/Developer/CommandLineTools/usr/bin/c++ -DCARES_NO_DEPRECATED -DG_DISABLE_DEPRECATED -DG_DISABLE_SINGLE_INCLUDES -DQT_CONCURRENT_LIB -DQT_CORE5COMPAT_LIB -DQT_CORE_LIB -DQT_DBUS_LIB -DQT_GUI_LIB -DQT_MULTIMEDIA_LIB -DQT_NETWORK_LIB -DQT_NO_DEBUG -DQT_PRINTSUPPORT_LIB -DQT_WIDGETS_LIB -I/Users/usr/Downloads/wireshark/build/ui/qt/qtui_autogen/include -I/Users/usr/Downloads/wireshark/build -I/Users/usr/Downloads/wireshark -I/Users/usr/Downloads/wireshark/include -isystem /usr/local/opt/gettext/include -isystem /usr/local/Cellar/glib/2.80.3/include/glib-2.0 -isystem /usr/local/Cellar/glib/2.80.3/lib/glib-2.0/include -isystem /usr/local/include -isystem /usr/local/Cellar/speexdsp/1.2.1/include -isystem /Users/usr/Downloads/wireshark/build/ui/qt -isystem /Users/usr/Downloads/wireshark/ui/qt -isystem /Users/usr/Qt/6.5.3/macos/lib/QtWidgets.framework/Headers -iframework /Users/usr/Qt/6.5.3/macos/lib -isystem /Users/usr/Qt/6.5.3/macos/lib/QtCore.framework/Headers -isystem /Users/usr/Qt/6.5.3/macos/mkspecs/macx-clang -isystem /Users/usr/Qt/6.5.3/macos/include -isystem /Users/usr/Qt/6.5.3/macos/lib/QtGui.framework/Headers -isystem /Users/usr/Qt/6.5.3/macos/lib/QtCore5Compat.framework/Headers -isystem /Users/usr/Qt/6.5.3/macos/lib/QtConcurrent.framework/Headers -isystem /Users/usr/Qt/6.5.3/macos/lib/QtPrintSupport.framework/Headers -isystem /Users/usr/Qt/6.5.3/macos/lib/QtMultimedia.framework/Headers -isystem /Users/usr/Qt/6.5.3/macos/lib/QtNetwork.framework/Headers -isystem /Users/usr/Qt/6.5.3/macos/lib/QtDBus.framework/Headers -Wall -Wextra -Wpointer-arith -Wformat-security -fno-strict-overflow -Wvla -Wattributes -Wpragmas -Wheader-guard -Wcomma -Wshorten-64-to-32 -Wredundant-decls -Wunreachable-code -Wdocumentation -Wno-error=deprecated-declarations -Wframe-larger-than=32768 -fcolor-diagnostics -Wextra-semi  -fmacro-prefix-map="/Users/usr/Downloads/wireshark/"= -fmacro-prefix-map="/Users/usr/Downloads/wireshark/build/"= -fmacro-prefix-map="../"= -O2 -g -DNDEBUG -std=c++17 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX14.4.sdk -fPIC -Werror -MD -MT ui/qt/CMakeFiles/qtui.dir/capture_comment_dialog.cpp.o -MF ui/qt/CMakeFiles/qtui.dir/capture_comment_dialog.cpp.o.d -o ui/qt/CMakeFiles/qtui.dir/capture_comment_dialog.cpp.o -c /Users/usr/Downloads/wireshark/ui/qt/capture_comment_dialog.cpp
In file included from /Users/usr/Downloads/wireshark/ui/qt/capture_comment_dialog.cpp:10:
In file included from /Users/usr/Downloads/wireshark/ui/qt/capture_comment_dialog.h:13:
In file included from /Users/usr/Downloads/wireshark/ui/qt/wireshark_dialog.h:31:
In file included from /Users/usr/Downloads/wireshark/ui/qt/capture_file.h:13:
In file included from /Users/usr/Qt/6.5.3/macos/lib/QtCore.framework/Headers/QObject:1:
/Users/usr/Qt/6.5.3/macos/lib/QtCore.framework/Headers/qobject.h:225:43: error: no template named 'QSlotObject' in ...
(more)
edit retag flag offensive close merge delete

Comments

2.1.1. Build environment setup

Qt 6 needs the "Qt 5 Compatibility Module" to be installed as well.

You didn't mention the extra Qt piece in your setup steps.

Chuckc gravatar imageChuckc ( 2024-07-01 19:40:36 +0000 )edit

Thank you for your response.

When installing Qt I installed Qt 6.5.3 for macOS, Ot 5 Compatibility Module and Qt Debug Information Files under the Qt dropdown as well as Qt Multimedia under the Additional Libraries dropdown. Is there anything else I should have possibly installed? I also set the Qt installation directory in the environment using:

WIRESHARK_QT6_PREFIX_PATH=~/Qt/6.5.3/macosexport WIRESHARK_QT6_PREFIX_PATH

Is there anything I am missing on that front?

joshua gravatar imagejoshua ( 2024-07-01 19:48:14 +0000 )edit

I'm not a Mac developer and don't want to steer you down bad paths. Will have to wait for a Mac person to come along.

Chuckc gravatar imageChuckc ( 2024-07-01 20:10:20 +0000 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2024-07-02 11:37:29 +0000

joshua gravatar image

Thank you. I was able to solve it. Realised I needed to export the package configuration path export PKG_CONFIG_PATH=/usr/local/Cellar/qt@5/5.15.12/lib/pkgconfig/

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2024-07-01 19:02:45 +0000

Seen: 1,099 times

Last updated: Jul 02