Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

在编译第三方库3rdparty时报AutoMoc error #7

Open
gwlee920 opened this issue Jul 31, 2024 · 1 comment
Open

在编译第三方库3rdparty时报AutoMoc error #7

gwlee920 opened this issue Jul 31, 2024 · 1 comment

Comments

@gwlee920
Copy link

Qt版本:6.5.3 mingw-w64
代码分支:master

按照how-to-build.md中的“使用Qt Creator基于CMake构建所有第三方库”步骤构建3rdparty时报错:

17:09:33: 为项目DAWorkBench-3rdparty-build执行步骤 ...
17:09:33: 正在启动 "C:\Qt\Tools\CMake_64\bin\cmake.exe" --build E:/work/test/src/3rdparty/build/Desktop_Qt_6_5_3_MinGW_64_bit-Debug --target all install

[1/176 3.5/sec] Automatic MOC and UIC for target QtPropertyBrowser
FAILED: QtPropertyBrowser/src/QtPropertyBrowser_autogen/timestamp QtPropertyBrowser/src/QtPropertyBrowser_autogen/mocs_compilation.cpp ...

AutoMoc error
-------------
"SRC:/QtPropertyBrowser/src/qt6editorfactory.cpp"
contains a "Q_OBJECT" macro, but does not include "qt6editorfactory.moc"!
Consider to
  - add #include "qt6editorfactory.moc"
  - enable SKIP_AUTOMOC for this file

[2/176 2.4/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_curve_fitter.cpp.obj
[3/176 3.5/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_transform.cpp.obj
[4/176 2.3/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_spline_curve_fitter.cpp.obj
[5/176 2.2/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_weeding_curve_fitter.cpp.obj
[6/176 2.4/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_abstract_legend.cpp.obj
[7/176 2.6/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_widget_overlay.cpp.obj
[8/176 2.9/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_text.cpp.obj
[9/176 3.1/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_legend_data.cpp.obj
[10/176 3.4/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_legend_label.cpp.obj
[11/176 3.6/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_text_engine.cpp.obj
[12/176 3.9/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_text_label.cpp.obj
[13/176 4.1/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_legend.cpp.obj
[14/176 4.3/sec] Building CXX object qwt/src/CMakeFiles/qwt.dir/qwt_plot.cpp.obj
ninja: build stopped: subcommand failed.
17:09:36: 进程"C:\Qt\Tools\CMake_64\bin\cmake.exe"退出,退出代码 1 。
Error while building/deploying project DAWorkBench-3rdparty-build (kit: Desktop Qt 6.5.3 MinGW 64-bit)
When executing step "构建"
17:09:36: Elapsed time: 00:03.

@czyt1988
Copy link
Owner

czyt1988 commented Aug 1, 2024

用git bash进入QtPropertyBrowser,执行git pull origin master拉取最新的代码即可

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants