2007-11-05 Sebastien Pouliot <sebastien@ximian.com>
[mono.git] / eglib / test / Makefile.am
index 0820e9392ec3d44dcf2b0e1fff0a65403f81ba47..1865ff72731b3f9dfd33c53d05f25491cf038d8d 100644 (file)
@@ -1,19 +1,49 @@
-noinst_PROGRAMS = test 
-
-test_SOURCES =    \
-       test.c          \
-       test.h          \
-       tests.h         \
-       driver.c        \
-       hashtable.c     \
+noinst_PROGRAMS = test-eglib test-glib
+
+SOURCES = \
+       test.c          \
+       test.h          \
+       tests.h         \
+       driver.c        \
+       hashtable.c     \
        string-util.c   \
-       string.c        \
-       slist.c
+       string.c        \
+       slist.c         \
+       sizes.c         \
+       ptrarray.c      \
+       list.c          \
+       array.c         \
+       fake.c          \
+       path.c          \
+       queue.c         \
+       shell.c         \
+       spawn.c         \
+       timer.c         \
+       file.c          \
+       pattern.c       \
+       dir.c           \
+       markup.c        \
+       utf8.c          \
+       endian.c        \
+       module.c
+
+test_eglib_SOURCES = $(SOURCES)
+test_glib_SOURCES = $(SOURCES)
 
-test_CFLAGS = -Wall -Werror -D_FORTIFY_SOURCE=2
-INCLUDES = -I../src
+test_eglib_CFLAGS = -Wall -Werror -D_FORTIFY_SOURCE=2 -I$(srcdir)/../src -DDRIVER_NAME=\"EGlib\"
+test_eglib_LDADD = ../src/libeglib.la -ldl
+test_eglib_LDFLAGS = -Wl,--export-dynamic
 
-test_LDADD = -L../src -leglib
+test_glib_CFLAGS = `pkg-config --cflags glib-2.0` -DDRIVER_NAME=\"GLib\"
+test_glib_LDFLAGS = `pkg-config --libs glib-2.0 gmodule-2.0`
 
 MAINTAINERCLEANFILES = Makefile.in
 
+run-glib: all
+       ./test-glib
+
+run-eglib: all
+       ./test-eglib
+
+run-both: run-glib run-eglib
+