Without this linking CXX executables (e.g. fbo-blit-stretch) fails
with gold linker:

| libpiglitutil_gl.so.0: error: undefined reference to 'dlsym'
| libpiglitutil_gl.so.0: error: undefined reference to 'dlerror'
| libpiglitutil_gl.so.0: error: undefined reference to 'dlopen'

Signed-off-by: Jussi Kukkonen <[email protected]>
---

Changes since v1:
* Use ${CMAKE_DL_LIBS} as Emil suggested

I'm adding the linker flag for all utils although I'm only seeing
the problem with libpiglitutil_gl.so -- I'm assuming it's because
the issue seems to only show with g++ and maybe the other
libs don't currently have tests that need g++?

Thanks, Jussi


 tests/util/CMakeLists.txt | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tests/util/CMakeLists.txt b/tests/util/CMakeLists.txt
index e1f8073..3d5bef5 100644
--- a/tests/util/CMakeLists.txt
+++ b/tests/util/CMakeLists.txt
@@ -11,6 +11,8 @@ set_source_files_properties(
        PROPERTIES GENERATED 1
        )
 
+link_libraries(${CMAKE_DL_LIBS})
+
 if(HAVE_LIBCACA)
     link_libraries(caca)
 endif()
-- 
2.9.3

_______________________________________________
Piglit mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to