freeglut-gles: Add symbol link to fix opencl-cts compile error

opencl-cts depends on freeglut-gles which will cause can't find so file error when using freeglut-gles as:
opencl-cts/2026.05.05/recipe-sysroot-native/usr/bin/aarch64-oe-linux/aarch64-oe-linux-ld: cannot find -lglut: No such file or directory

It was caused by the CMake definition in opencl-cts

In test_conformance/gl/CMakeLists.txt, it will always find glut file to link but the realname is libfreeglut-gles.so or libfreeglut.so.
  if(WIN32)
  ......
      list(APPEND CLConform_LIBRARIES opengl32 freeglut glew32)
  else(WIN32)
      list(APPEND CLConform_LIBRARIES  GL glut GLEW GLU)
  endif(WIN32)

So add symbol link for so file in freeglut-gles.

Signed-off-by: Zheng Ruoqin <zhengrq.fnst@fujitsu.com>
Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
This commit is contained in:
Zheng Ruoqin
2026-06-25 10:04:33 +08:00
committed by Khem Raj
parent e81e092583
commit 461c78e631
@@ -36,4 +36,7 @@ UPSTREAM_CHECK_URI = "https://github.com/${BPN}/${BPN}/releases"
do_install:append() {
# Remove buildpaths
sed -i "s#${RECIPE_SYSROOT}##g" ${D}${libdir}/cmake/FreeGLUT/FreeGLUTTargets.cmake
if [ -f "${D}${libdir}/libfreeglut-gles.so" ]; then
ln -sf libfreeglut-gles.so ${D}${libdir}/libglut.so
fi
}