From: Emil Velikov Date: Thu, 8 Dec 2016 17:58:21 +0000 (+0000) Subject: gallium: correctly manage libsensors link flags X-Git-Tag: upstream/17.1.0~3025 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4380a2098b61cfa0dd3855bd63d3c8b70ce25dd5;p=platform%2Fupstream%2Fmesa.git gallium: correctly manage libsensors link flags We should be using LIBS rather than the LDFLAGS variable. Furthermore try to keep the linking to the final stage, rather than intermetent static library. Cc: Steven Toth Signed-off-by: Emil Velikov Reviewed-by: Nicolai Hähnle --- diff --git a/configure.ac b/configure.ac index b68b51e..450fca1 100644 --- a/configure.ac +++ b/configure.ac @@ -1127,11 +1127,11 @@ AC_ARG_ENABLE([lmsensors], AM_CONDITIONAL(HAVE_LIBSENSORS, test "x$enable_lmsensors" = xyes) if test "x$enable_lmsensors" = xyes ; then DEFINES="${DEFINES} -DHAVE_LIBSENSORS=1" - LIBSENSORS_LDFLAGS="-lsensors" + LIBSENSORS_LIBS="-lsensors" else - LIBSENSORS_LDFLAGS="" + LIBSENSORS_LIBS="" fi -AC_SUBST(LIBSENSORS_LDFLAGS) +AC_SUBST(LIBSENSORS_LIBS) case "$host_os" in linux*) diff --git a/src/gallium/Automake.inc b/src/gallium/Automake.inc index 6aadcb9..a01fa54 100644 --- a/src/gallium/Automake.inc +++ b/src/gallium/Automake.inc @@ -46,6 +46,7 @@ GALLIUM_TARGET_CFLAGS = \ GALLIUM_COMMON_LIB_DEPS = \ -lm \ + $(LIBSENSORS_LIBS) \ $(CLOCK_LIB) \ $(PTHREAD_LIBS) \ $(DLOPEN_LIBS) diff --git a/src/gallium/auxiliary/Makefile.am b/src/gallium/auxiliary/Makefile.am index 1154c79..def0098 100644 --- a/src/gallium/auxiliary/Makefile.am +++ b/src/gallium/auxiliary/Makefile.am @@ -44,8 +44,6 @@ libgallium_la_SOURCES += \ endif -libgallium_la_LDFLAGS = $(LIBSENSORS_LDFLAGS) - MKDIR_GEN = $(AM_V_at)$(MKDIR_P) $(@D) PYTHON_GEN = $(AM_V_GEN)$(PYTHON2) $(PYTHON_FLAGS)