Build: Autotools usage improvements
Use libtool defaults.
Define CXXFLAGS rather than CFLAGS.
Add libraries via LIBADD rather than LDFLAGS. This allows
--as-needed to drop unnecessary libs if present.
Don't bother with PIC objects for convenience library.
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Change-Id: I4a6079402a01ad5f6ccfb71ca9fca44c567ec62d
diff --git a/test/Makefile.am b/test/Makefile.am
index 0d7d7a0..2092964 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -3,6 +3,11 @@
phosphor_hwmon_test_SOURCES = \
test.cpp
-phosphor_hwmon_test_LDFLAGS = $(SDBUSPLUS_LIBS) $(PTHREAD_CFLAGS)
-phosphor_hwmon_test_CFLAGS = $(SDBUSPLUS_CFLAGS)
-phosphor_hwmon_test_LDADD = ${top_builddir}/libhwmon.la
+phosphor_hwmon_test_LDADD = \
+ ${top_builddir}/libhwmon.la \
+ $(SDBUSPLUS_LIBS) \
+ $(PTHREAD_LIBS)
+
+phosphor_hwmon_test_CXXFLAGS = \
+ $(SDBUSPLUS_CFLAGS) \
+ $(PTHREAD_CFLAGS)