【发布时间】:2020-06-19 08:42:45
【问题描述】:
我尝试在我的计算机(macOS Catalina 10.15.5)中编译 OMNeT++ 5.6.2 的源代码。
但是在“make”命令过程中出现了一些错误。
我不知道为什么会出现这个错误。我认为错误可能来自“Qtenv”或“QT”。
我也删除了“命令行工具”并重新安装了它,但仍然出现错误。
我还看到了 OMNeT++ 安装指南那个非常简单的步骤。本书描述通过执行命令“./configure”和“make”或“make -j4”安装方法。
如何解决以下错误?
kimminwoo@Macbook-Pro-2020-13-inch-for-Minwoo omnetpp-5.6.2 % make
/Library/Developer/CommandLineTools/usr/bin/make -s MODE=release
***** Configuration: MODE=release, TOOLCHAIN_NAME=clang, LIB_SUFFIX=.dylib ****
===== Checking environment =====
===== Compiling utils ====
===== Compiling common ====
===== Compiling layout ====
===== Compiling eventlog ====
===== Compiling scave ====
===== Compiling nedxml ====
===== Compiling sim ====
===== Compiling envir ====
===== Compiling cmdenv ====
===== Compiling qtenv ====
animationcontrollerdialog.cc
In file included from animationcontrollerdialog.cc:20:
In file included from ./qtenv.h:33:
In file included from ./inspector.h:22:
In file included from ./qtutil.h:25:
In file included from /Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/QTimer:1:
/Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/qtimer.h:106:50: error: no template named 'is_same' in namespace 'QtPrivate'; did you mean
'std::is_same'?
!QtPrivate::is_same<const char*, Func1>::value, void>::Type
^~~~~~~~~~~
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/type_traits:883:61: note: 'std::is_same' declared here
template <class _Tp, class _Up> struct _LIBCPP_TEMPLATE_VIS is_same : public false_type {};
In file included from animationcontrollerdialog.cc:20:
In file included from ./qtenv.h:33:
In file included from ./inspector.h:22:
In file included from ./qtutil.h:25:
In file included from /Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/QTimer:1:
/Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/qtimer.h:113:50: error: no template named 'is_same' in namespace 'QtPrivate'; did you mean
'std::is_same'?
!QtPrivate::is_same<const char*, Func1>::value, void>::Type
^~~~~~~~~~~
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/type_traits:883:61: note: 'std::is_same' declared here
template <class _Tp, class _Up> struct _LIBCPP_TEMPLATE_VIS is_same : public false_type {};
In file included from animationcontrollerdialog.cc:20:
In file included from ./qtenv.h:33:
In file included from ./inspector.h:22:
In file included from ./qtutil.h:25:
In file included from /Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/QTimer:1:
/Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/qtimer.h:121:50: error: no template named 'is_same' in namespace 'QtPrivate'; did you mean
'std::is_same'?
!QtPrivate::is_same<const char*, Func1>::value, void>::Type
^~~~~~~~~~~
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/type_traits:883:61: note: 'std::is_same' declared here
template <class _Tp, class _Up> struct _LIBCPP_TEMPLATE_VIS is_same : public false_type {};
In file included from animationcontrollerdialog.cc:20:
In file included from ./qtenv.h:33:
In file included from ./inspector.h:22:
In file included from ./qtutil.h:25:
In file included from /Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/QTimer:1:
/Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtCore/qtimer.h:128:50: error: no template named 'is_same' in namespace 'QtPrivate'; did you mean
'std::is_same'?
!QtPrivate::is_same<const char*, Func1>::value, void>::Type
^~~~~~~~~~~
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/type_traits:883:61: note: 'std::is_same' declared here
template <class _Tp, class _Up> struct _LIBCPP_TEMPLATE_VIS is_same : public false_type {};
In file included from animationcontrollerdialog.cc:20:
In file included from ./qtenv.h:33:
In file included from ./inspector.h:25:
In file included from /Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtWidgets/QMenu:1:
/Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtWidgets/qmenu.h:91:43: error: no template named 'is_same' in namespace 'QtPrivate'; did you mean
'std::is_same'?
inline typename QtPrivate::QEnableIf<!QtPrivate::is_same<const char*, Func1>::value
^~~~~~~~~~~
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/type_traits:883:61: note: 'std::is_same' declared here
template <class _Tp, class _Up> struct _LIBCPP_TEMPLATE_VIS is_same : public false_type {};
In file included from animationcontrollerdialog.cc:20:
In file included from ./qtenv.h:33:
In file included from ./inspector.h:25:
In file included from /Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtWidgets/QMenu:1:
/Users/kimminwoo/Desktop/omnetpp-5.6.2/tools/macosx/include/QtWidgets/qmenu.h:119:43: error: no template named 'is_same' in namespace 'QtPrivate'; did you mean
'std::is_same'?
inline typename QtPrivate::QEnableIf<!QtPrivate::is_same<const char*, Func1>::value
^~~~~~~~~~~
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/type_traits:883:61: note: 'std::is_same' declared here
template <class _Tp, class _Up> struct _LIBCPP_TEMPLATE_VIS is_same : public false_type {};
^
6 errors generated.
make[2]: *** [/Users/kimminwoo/Desktop/omnetpp-5.6.2/out/clang-release/src/qtenv/animationcontrollerdialog.o] Error 1
make[1]: *** [qtenv] Error 2
make: *** [allmodes] Error 2
【问题讨论】: