在基于docker 编译Starrocks源码时,FE异常信息如下
Starrocks 源码版本是3.2.4
docker 镜像版本是:
starrocks/dev-env-centos7 3.2.4
FE 编译报错信息如下:
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /root/starrocks/fe/fe-core/target/generated-sources/antlr4/com/starrocks/sql/parser/StarRocksParser.java:[13,8] duplicate class: com.starrocks.sql.parser.StarRocksParser
[ERROR] /root/starrocks/fe/fe-core/src/main/java/com/starrocks/sql/parser/gen/StarRocksLex.java:[331,34] cannot access StarRocksParser
bad source file: /root/starrocks/fe/fe-core/target/generated-sources/antlr4/com/starrocks/sql/parser/StarRocksParser.java
file does not contain class StarRocksParser
Please remove or make sure it appears in the correct subdirectory of the sourcepath.
[INFO] 2 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] starrocks-fe 3.4.0 … SUCCESS [ 0.001 s]
[INFO] plugin-common 1.0.0 … SUCCESS [ 2.200 s]
[INFO] fe-common 1.0.0 … SUCCESS [ 0.899 s]
[INFO] spark-dpp 1.0.0 … SUCCESS [ 28.671 s]
[INFO] fe-core 3.4.0 … FAILURE [ 52.195 s]
[INFO] hive-udf 1.0.0 … SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:24 min
[INFO] Finished at: 2024-03-20T14:58:01Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project fe-core: Compilation failure: Compilation failure:
[ERROR] /root/starrocks/fe/fe-core/target/generated-sources/antlr4/com/starrocks/sql/parser/StarRocksParser.java:[13,8] duplicate class: com.starrocks.sql.parser.StarRocksParser
[ERROR] /root/starrocks/fe/fe-core/src/main/java/com/starrocks/sql/parser/gen/StarRocksLex.java:[331,34] cannot access StarRocksParser
[ERROR] bad source file: /root/starrocks/fe/fe-core/target/generated-sources/antlr4/com/starrocks/sql/parser/StarRocksParser.java
[ERROR] file does not contain class StarRocksParser
[ERROR] Please remove or make sure it appears in the correct subdirectory of the sourcepath.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn -rf :fe-core
编译BE报销信息如下:
Consolidate compiler generated dependencies of target build_version
[ 1%] Built target build_version
[ 2%] Building CXX object src/common/CMakeFiles/Common.dir/daemon.cpp.o
Consolidate compiler generated dependencies of target Agent
In file included from /root/starrocks/be/src/block_cache/block_cache.h:17,
from /root/starrocks/be/src/common/daemon.cpp:39:
/root/starrocks/be/src/block_cache/kv_cache.h:21:10: fatal error: starcache/star_cache.h: No such file or directory
21 | #include “starcache/star_cache.h”
| ^~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [src/common/CMakeFiles/Common.dir/daemon.cpp.o] Error 1
make[1]: *** [src/common/CMakeFiles/Common.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs…
[ 3%] Built target Agent
make: *** [all] Error 2