出于某种原因,我想构建mesa3d源代码。我按照指南https://mesa3d.org/install.html构建环境是fedora31和gcc9.2,但当我试图通过运行ninja install
来构建代码时,出现了一些构建错误。
失败:src/mesa/drivers/dri/r100/58cd8d4@@r200@sta/radeon_buffer_objects.c.occ-Isrc/mesa/drivers/dri/r2000/58cd8d4@@r200@sta-Isrc/mesa/drivers/dri/r200-I/src/mesa/drivers/dri/r200-包含-I/包括-Isrc-I/src-Isrc/mapi-I/src/mapi-Isrc/mesa-I/src/mesa-I/src/镓/包括-Isrc/氮化镓/辅助-I/src/镓/辅助-Isrc/mesa/drivers/dri/common-I/src/mesa/drivers/dri/common-Isrc/util-I/src/util-I/src/mesa/drivers/dri/r200/server-Isrc/util/xmlpool-I/usr/include/libdrm-fdiagnostics color=始终-pipe-D_FILE_OFFSET_BITS=64-Wall-Winvalid pch-std=c99-O2-g-D_STDC_CONSTANT_MACROS-D_STDC_FORMAT_MACROS/D_STDC_LIMIT_MACROS'-DPACKAGE_VERSION="20.0.0-devel"'-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/issues"'-DUSE_ELF_TLS-DHAVE_ST_VDPAU-danable_ST_OMX_BELLAGIO=0-danable-ST_OMX_TIZONIA=0-DHAVE_X11_平台-DGLX_INDIRECT_RENDERING-DGLX_DIRECT_RENDERING-DGLX_USE_DRM-DHAVE_DRM_平台-DHAVE_surfacless_平台-danable_SHADER_CACHE-DHAVE__BUILTIN_BSWAP32-DHAVE___BUILTIN_BSWAP64-DHAVE__ BUILTIN_CLZ-DHAVE___ BUILTIN_Clll-DHAVE____ BUILTIN-CTZ-DHAVE_ _BUILTIN_EXPECT-DHAVE___BUILTIN.fs-DHAVE___BUILTIN_FFSLL-DHAVE__BUILTIN_POPCOUNT-DHAVE__ BUILTIN_UNREACHABLE-DHAVE_FUNC_ATTRIBUTE_CONST-DHAVE_FUNC_attrib te_FLATTEN-DHAVE _FUNC_aattribute_MALLOC-DHAVE_filc_ATTRIBUTE_PURE-DHAVE.FUNC_attribte_UNUSED-DHAVE-FUNC_aattrib te_WARN_UNUSED_RESULT-DHAVE_FUNC_atribute_WEAK已分页(_P)-DHAVE_FUNC_ATTRIBUTE_RETURNS_nunll-DHAVE_FUNC_ATTRIBUTE_VISIBILITY-DHAVE_FUNC_attribte_ALIAS-DHAVE_FUNC_ATTRIBUTE _NORETURN-DHAVE_UINT128-D_gn_SOURCE-DUSE_se41-DUSE_GCC_ATOMIC_buildins-DUSE_X86_64_ASM-DMAJOR_IN_SYSMACROS-DHAVE_SYS_SYSCTL_H-DHAVE_LINUX_FUTEX_H-DHAVE_ENDIAN-H-DHAVE _DLFCN_H-deve_EXECINFO_H-DHAVE_SYS_SHM_H-DHAVE_CET _H-DHAVE_STRTOF-DHAVE_MKOSTEMP-DHAVE_TIMESPEC_GET-DHAVE_MEMFD_CREATE-DHAVE_RANDOM-R-DHAVE_FLOCK-DHAVE_strto_R-DHAVE_PROGRAM_INVOCATION_NAME-DHAVE_POSIX_MEMALIGN-DHAVE-strto_L-DHAVE_DLADDR-DHAVE_DL_ITERATE_PHDR-DHAVE _ZLIB-DHAVE_thread-DHAVE_PTHREAD-taffinity-DHAVE_LIBDRM-DLLVM_AVAILABLE'-DMESA_LLVM_VERSION_STRING="9.0.0"'-DHAVE_VALGRIND-DHAVE_WAYLAND_PLATFORM-DWL_HIDE_DEPRECATED-DHAVE_DRI3-DHAVE_DRI3_MODIFIERS-Weror=隐式函数声明-Werror=缺少原型-Werrr=返回类型-Werrer=空正文-Werrar=不兼容的指针类型-Wno缺少字段初始值设定项-Wno格式截断-fno math errno-fno trapping math-Werror=format-Wformat security-fPIC-fvisibility=hidden-DRADEON_R200-MD-MQ'src/mesa/drivers/dri/R200/58cd8d4@@r200@sta/rade_buffer_objects.co'-MF'src/mesa/drivers/dri/r200/58cd8d4@@r200@sta/radeon_buffer_objects.c.o.d'-o'src/mesa/drivers/dri/r2000/58cd8d4@@r200@sta/radeon_buffer_objects.c.o'-c/src/mesa/drivers/dri/r2000/rade_buffer_objects.c../src/mesa/drivers/dri/r100/rade_buffer_objects.c:1:错误:应为标识符或'.'标记之前的"(">
1 | ../radeon/radeon_buffer_objects.c
| ^
然后我检查radeon_buffer_objects.c,这个文件中只有一个文件路径
/radeon/radeon_ffer_objects.c
我不太熟悉gcc和clang。这是什么意思?如何解决此生成错误?
我尝试从mesa3d.org克隆repo,问题得到了解决。
谢谢你们的帮助,伙计们。