我尝试在没有 X11 和 Wayland 支持的情况下为香蕉 Pro 构建图像。但在 Mali 测试二进制编译期间出现以下错误:
make: Leaving directory '/home/yusuf/yocto/poky/bananaProHf/tmp/work/cortexa7hf-vfp-vfpv4-neon-poky-linux-gnueabi/sunxi-mali/git-r0/git/include'
make -C test test
make[1]: Entering directory '/home/yusuf/yocto/poky/bananaProHf/tmp/work/cortexa7hf-vfp-vfpv4-neon-poky-linux-gnueabi/sunxi-mali/git-r0/git/test'
arm-poky-linux-gnueabi-gcc -march=armv7-a -mfloat-abi=hard -mfpu=neon-vfpv4 -mtune=cortex-a7 --sysroot=/home/yusuf/yocto/poky/bananaProHf/tmp/sysroots/bananapro -O2 -pipe -g -feliminate-unused-debug-types -I../include -L../../image/usr/lib -o test test.c -lEGL -lGLESv2 -lX11
In file included from ../include/EGL/egl.h:36:0,
from test.c:32:
../include/EGL/eglplatform.h:89:22: fatal error: X11/Xlib.h: No such file or directory
compilation terminated.
Makefile:8: recipe for target 'test' failed
当我查看0001-fix-test-build.patch
文件时,我看到以下几行
test: ../config.mk test.c
-$(CC) $(CFLAGS) -o $@ test.c -lEGL -lGLESv2
+$(CC) $(CFLAGS) -I../include -L../../image/usr/lib -o $@ test.c -lEGL -lGLESv2 -lX11
由于图像不支持 X11,我认为不应包含 X11 库。这不是真的吗?我怎么解决这个问题?