[Xcb] [PATCH RESEND image 12/12] test: use automake general variables rather than the specific ones

Gaetan Nadon memsize at videotron.ca
Thu Mar 27 11:38:48 PDT 2014


Specify the source filenames is redundant as automake matches the names
with the program name. You can add test cases without changing the makefile.

Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
---
 test/Makefile.am |   17 +++++------------
 1 file changed, 5 insertions(+), 12 deletions(-)

diff --git a/test/Makefile.am b/test/Makefile.am
index dfe8b3f..711ee1f 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -14,17 +14,10 @@ AM_CPPFLAGS = 			\
 	$(XCB_UTIL_CFLAGS)	\
 	-I$(top_srcdir)/image
 
-test_swap_SOURCES = test_swap.c
-test_swap_LDADD = $(XCB_LIBS) $(XCB_UTIL_LIBS) $(top_builddir)/image/libxcb-image.la
+LDADD = $(XCB_LIBS) $(XCB_UTIL_LIBS) $(top_builddir)/image/libxcb-image.la
 
-test_xcb_image_SOURCES = test_xcb_image.c
-test_xcb_image_LDADD = $(XCB_LIBS) $(XCB_UTIL_LIBS) $(top_builddir)/image/libxcb-image.la
-
-test_xcb_image_shm_SOURCES = test_xcb_image_shm.c
-test_xcb_image_shm_LDADD = $(XCB_LIBS) $(XCB_UTIL_LIBS) $(XCB_SHM_LIBS) $(top_builddir)/image/libxcb-image.la
-
-test_formats_SOURCES = test_formats.c
-test_formats_LDADD = $(XCB_LIBS) $(XCB_UTIL_LIBS) $(top_builddir)/image/libxcb-image.la
+if HAVE_SHM
+test_xcb_image_shm_LDADD = $(LDADD) $(XCB_SHM_LIBS)
+endif
 
-test_bitmap_SOURCES = test_bitmap.c test.xbm
-test_bitmap_LDADD = $(XCB_LIBS) $(XCB_UTIL_LIBS) $(top_builddir)/image/libxcb-image.la
+EXTRA_DIST = test.xbm
-- 
1.7.9.5



More information about the Xcb mailing list