Mac M1 `make` command fail on release 5.7.8
FraBomba6 opened this issue · comments
Environment
Mar 6 Dic 2022 14:22:37 CET
radare2 5.7.9 29658 @ darwin-arm-64 git.5.7.8-650-g4b769417e2
commit: 4b769417e2b42ca79cb9797d5c00a89fa2a6c21f build: 2022-12-06__13:52:49
Darwin arm64
QMake version 3.1
Using Qt version 5.15.7 in /opt/homebrew/Cellar/qt@5/5.15.7/lib
Description
I can't build last release (5.7.8) on macOs 13.1 M1.
As you can show from my environment I've installed the last version of radare2 from GitHub and Qt 5 using brew.
When I run the make
command I get the following output
/Library/Developer/CommandLineTools/usr/bin/make -C build -j4
/Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -g -O0 -mmacosx-version-min=10.7 -std=c++17 -stdlib=libc++ -g -O2 -std=gnu++11 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=10.13 -Wall -Wextra -fPIC -DIAITO_SOURCE_BUILD -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS -DQT_NO_DEBUG -DQT_SVG_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I../src -I. -I../src -I../src/core -I../src/widgets -I../src/dialogs -I../src/common -I../src/plugins -I../src/menus -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtSvg.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtWidgets.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtGui.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtNetwork.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/AGL.framework/Headers -I. -I/opt/homebrew/Cellar/qt@5/5.15.7/mkspecs/macx-clang-arm64 -F/opt/homebrew/Cellar/qt@5/5.15.7/lib -o Iaito.o ../src/core/Iaito.cpp
/Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -g -O0 -mmacosx-version-min=10.7 -std=c++17 -stdlib=libc++ -g -O2 -std=gnu++11 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=10.13 -Wall -Wextra -fPIC -DIAITO_SOURCE_BUILD -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS -DQT_NO_DEBUG -DQT_SVG_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I../src -I. -I../src -I../src/core -I../src/widgets -I../src/dialogs -I../src/common -I../src/plugins -I../src/menus -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtSvg.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtWidgets.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtGui.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtNetwork.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/AGL.framework/Headers -I. -I/opt/homebrew/Cellar/qt@5/5.15.7/mkspecs/macx-clang-arm64 -F/opt/homebrew/Cellar/qt@5/5.15.7/lib -o NewFileDialog.o ../src/dialogs/NewFileDialog.cpp
/Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -g -O0 -mmacosx-version-min=10.7 -std=c++17 -stdlib=libc++ -g -O2 -std=gnu++11 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=10.13 -Wall -Wextra -fPIC -DIAITO_SOURCE_BUILD -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS -DQT_NO_DEBUG -DQT_SVG_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I../src -I. -I../src -I../src/core -I../src/widgets -I../src/dialogs -I../src/common -I../src/plugins -I../src/menus -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtSvg.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtWidgets.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtGui.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtNetwork.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/AGL.framework/Headers -I. -I/opt/homebrew/Cellar/qt@5/5.15.7/mkspecs/macx-clang-arm64 -F/opt/homebrew/Cellar/qt@5/5.15.7/lib -o AnalTask.o ../src/common/AnalTask.cpp
/Library/Developer/CommandLineTools/usr/bin/clang++ -c -pipe -stdlib=libc++ -g -O0 -mmacosx-version-min=10.7 -std=c++17 -stdlib=libc++ -g -O2 -std=gnu++11 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -mmacosx-version-min=10.13 -Wall -Wextra -fPIC -DIAITO_SOURCE_BUILD -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS -DQT_NO_DEBUG -DQT_SVG_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I../src -I. -I../src -I../src/core -I../src/widgets -I../src/dialogs -I../src/common -I../src/plugins -I../src/menus -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/usr/local/include/libr -I/usr/local/include/libr/sdb -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtSvg.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtWidgets.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtGui.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtNetwork.framework/Headers -I/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtCore.framework/Headers -I. -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/AGL.framework/Headers -I. -I/opt/homebrew/Cellar/qt@5/5.15.7/mkspecs/macx-clang-arm64 -F/opt/homebrew/Cellar/qt@5/5.15.7/lib -o CommentsWidget.o ../src/widgets/CommentsWidget.cpp
In file included from ../src/widgets/CommentsWidget.cpp:2:
In file included from ./ui_ListDockWidget.h:18:
../src/widgets/AddressableItemList.h:36:10: warning: 'AddressableItemList<>::setModel' hides overloaded virtual function [-Woverloaded-virtual]
void setModel(AddressableItemModelI *model)
^
./ui_ListDockWidget.h:42:24: note: in instantiation of template class 'AddressableItemList<>' requested here
treeView = new AddressableItemList<>(dockWidgetContents);
^
/opt/homebrew/Cellar/qt@5/5.15.7/lib/QtWidgets.framework/Headers/qtreeview.h:74:10: note: hidden overloaded virtual function 'QTreeView::setModel' declared here: type mismatch at 1st parameter ('QAbstractItemModel *' vs 'AddressableItemModelI *')
void setModel(QAbstractItemModel *model) override;
^
../src/core/Iaito.cpp:582:15: error: use of undeclared identifier 'r_pvector_len'; did you mean 'r_pvector_new'?
r.reserve(r_pvector_len(&completion.args));
^~~~~~~~~~~~~
r_pvector_new
/usr/local/include/libr/r_vector.h:198:17: note: 'r_pvector_new' declared here
R_API RPVector *r_pvector_new(RPVectorFree free);
^
../src/core/Iaito.cpp:582:29: error: cannot initialize a parameter of type 'RPVectorFree' (aka 'void (*)(void *)') with an rvalue of type 'RPVector *' (aka 'r_pvector_t *')
r.reserve(r_pvector_len(&completion.args));
^~~~~~~~~~~~~~~~
/usr/local/include/libr/r_vector.h:198:44: note: passing argument to parameter 'free' here
R_API RPVector *r_pvector_new(RPVectorFree free);
^
../src/core/Iaito.cpp:583:28: error: use of undeclared identifier 'r_pvector_len'; did you mean 'r_pvector_new'?
for (size_t i = 0; i < r_pvector_len(&completion.args); i++) {
^~~~~~~~~~~~~
r_pvector_new
/usr/local/include/libr/r_vector.h:198:17: note: 'r_pvector_new' declared here
R_API RPVector *r_pvector_new(RPVectorFree free);
^
../src/core/Iaito.cpp:583:42: error: cannot initialize a parameter of type 'RPVectorFree' (aka 'void (*)(void *)') with an rvalue of type 'RPVector *' (aka 'r_pvector_t *')
for (size_t i = 0; i < r_pvector_len(&completion.args); i++) {
^~~~~~~~~~~~~~~~
/usr/local/include/libr/r_vector.h:198:44: note: passing argument to parameter 'free' here
R_API RPVector *r_pvector_new(RPVectorFree free);
^
../src/core/Iaito.cpp:2435:5: error: unknown type name 'RAsmPlugin'
RAsmPlugin *ap;
^
../src/core/Iaito.cpp:2436:48: error: unknown type name 'RAsmPlugin'
IaitoRListForeach(core->rasm->plugins, it, RAsmPlugin, ap) {
^
../src/core/Iaito.cpp:2552:5: error: unknown type name 'RAsmPlugin'
RAsmPlugin *ap;
^
../src/core/Iaito.cpp:2553:48: error: unknown type name 'RAsmPlugin'
IaitoRListForeach(core->rasm->plugins, it, RAsmPlugin, ap) {
^
../src/core/Iaito.cpp:3444:20: error: use of undeclared identifier 'r_parse_c_string'
char *parsed = r_parse_c_string(core->anal, str, &error_msg);
^
9 errors generated.
make[1]: *** [Iaito.o] Error 1
make[1]: *** Waiting for unfinished jobs....
1 warning generated.
make: *** [iaito] Error 2
You have multiple installations of r2 and iaito is picking the wrong one. Rhe make install fails because you have a precious symlinked installation. Run make purge and everything shojld work
Tried your solution multiple times but didn't work.
I managed to fix this by installing the .pkg release of Radare2 and then running the commands to install iaito