[Mesa-dev] [PATCH] glsl: Link tests with CLOCK_LIB.

Timothy Arceri tarceri at itsqueeze.com
Wed Mar 22 23:17:03 UTC 2017


On 23/03/17 09:29, Vinson Lee wrote:
> Fix 'make check' linking errors on CentOS 6.

Hi Vinson,

Red Hat Enterprise Linux 6 enters Production Phase 3 on May 10, 2017. 
I've confirmed with Dave this means no more Mesa backports. Perhaps you
might want to consider moving to testing CentOS 7?

 From what I can tell this should also fix the zlib min version problem.

>
>   CXXLD  glsl/glsl_test
> glsl/.libs/libglsl.a(libmesautil_la-u_queue.o): In function `u_thread_get_time_nano':
> src/util/../../src/util/u_thread.h:84: undefined reference to `clock_gettime'
>
> Signed-off-by: Vinson Lee <vlee at freedesktop.org>
> ---
>  src/compiler/Makefile.glsl.am |    9 ++++++---
>  1 files changed, 6 insertions(+), 3 deletions(-)
>
> diff --git a/src/compiler/Makefile.glsl.am b/src/compiler/Makefile.glsl.am
> index 761fb93..43fd6a9 100644
> --- a/src/compiler/Makefile.glsl.am
> +++ b/src/compiler/Makefile.glsl.am
> @@ -66,7 +66,8 @@ glsl_tests_cache_test_CFLAGS =				\
>  	$(PTHREAD_CFLAGS)
>  glsl_tests_cache_test_LDADD =				\
>  	glsl/libglsl.la					\
> -	$(PTHREAD_LIBS)
> +	$(PTHREAD_LIBS)					\
> +	$(CLOCK_LIB)
>
>  glsl_tests_general_ir_test_SOURCES =			\
>  	glsl/tests/array_refcount_test.cpp 		\
> @@ -83,7 +84,8 @@ glsl_tests_general_ir_test_LDADD =			\
>  	glsl/libglsl.la		\
>  	glsl/libstandalone.la				\
>  	$(top_builddir)/src/libglsl_util.la		\
> -	$(PTHREAD_LIBS)
> +	$(PTHREAD_LIBS)					\
> +	$(CLOCK_LIB)
>
>  glsl_tests_uniform_initializer_test_SOURCES =		\
>  	glsl/tests/copy_constant_to_storage_tests.cpp	\
> @@ -159,7 +161,8 @@ glsl_glsl_test_LDADD =					\
>  	glsl/libglsl.la					\
>  	glsl/libstandalone.la				\
>  	$(top_builddir)/src/libglsl_util.la		\
> -	$(PTHREAD_LIBS)
> +	$(PTHREAD_LIBS)					\
> +	$(CLOCK_LIB)
>
>  # We write our own rules for yacc and lex below. We'd rather use automake,
>  # but automake makes it especially difficult for a number of reasons:
>


More information about the mesa-dev mailing list