Convert test to automake
authorGeoff Levand <geoff@infradead.org>
Sat, 17 Mar 2012 05:23:35 +0000 (22:23 -0700)
committerGeoff Levand <geoff@infradead.org>
Sat, 17 Mar 2012 05:23:35 +0000 (22:23 -0700)
Signed-off-by: Geoff Levand <geoff@infradead.org>
Makefile.am
configure.ac.in
discover/Makefile.am
test/Makefile.am [new file with mode: 0644]

index a89b0b03fab2aec4d512f3455dc4dc2a2db5ffdf..feff84b824706a1807939a6fc8b2fb48243d85d0 100644 (file)
@@ -12,7 +12,7 @@
 #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 #
 
-SUBDIRS = lib discover ui utils man
+SUBDIRS = lib discover test ui utils man
 
 ACLOCAL_AMFLAGS = -I m4
 
index 28e96d379bb3bb32d18cb8eb21a0e9b172d47503..c62ef56e872ec67cb6455baeea49da24eb1c106c 100644 (file)
@@ -183,6 +183,7 @@ AC_CONFIG_FILES([
        discover/Makefile
        lib/Makefile
        man/Makefile
+       test/Makefile
        ui/Makefile
        ui/common/Makefile
        ui/ncurses/Makefile
index 10d4d65b09a6e5971238ea9d44fa588dcc679303..5ddba1fd74823520e2511165bcbacfa08a44061a 100644 (file)
@@ -29,7 +29,13 @@ libparser_la_SOURCES = \
        parser-utils.c \
        parser-utils.h \
        paths.c \
-       paths.h
+       paths.h \
+       kboot-parser.c \
+       yaboot-parser.c
+
+EXTRA_DIST = native-parser.c
+
+libparser_la_LIBADD = $(top_builddir)/lib/libpbcore.la
 
 sbin_PROGRAMS = pb-discover
 
@@ -41,7 +47,6 @@ pb_discover_SOURCES = \
        event.c \
        event.h \
        event-parser.c \
-       kboot-parser.c \
        message.h \
        params.c \
        params.h \
@@ -50,9 +55,8 @@ pb_discover_SOURCES = \
        udev.c \
        udev.h \
        user-event.c \
-       user-event.h \
-       yaboot-parser.c
+       user-event.h
+
 pb_discover_LDADD = libparser.la $(top_builddir)/lib/libpbcore.la
 
-EXTRA_DIST = native-parser.c
 MAINTAINERCLEANFILES = Makefile.in
diff --git a/test/Makefile.am b/test/Makefile.am
new file mode 100644 (file)
index 0000000..2f0625d
--- /dev/null
@@ -0,0 +1,35 @@
+#  This program is free software; you can redistribute it and/or modify
+#  it under the terms of the GNU General Public License as published by
+#  the Free Software Foundation; version 2 of the License.
+#
+#  This program is distributed in the hope that it will be useful,
+#  but WITHOUT ANY WARRANTY; without even the implied warranty of
+#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#  GNU General Public License for more details.
+#
+#  You should have received a copy of the GNU General Public License
+#  along with this program; if not, write to the Free Software
+#  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+#
+
+AM_CPPFLAGS = \
+       -I$(top_srcdir) \
+       -I$(top_srcdir)/lib \
+       -I$(includedir) \
+       $(DEFAULT_CPPFLAGS)
+
+AM_CFLAGS = \
+       $(DEFAULT_CFLAGS)
+
+common_libs = \
+       $(top_builddir)/lib/libpbcore.la \
+       $(top_builddir)/discover/libparser.la
+
+noinst_SCRIPTS = parser-test.sh hotplug-device.sh
+
+noinst_PROGRAMS = parser-test
+
+parser_test_SOURCES = parser-test.c
+parser_test_LDADD = $(common_libs)
+
+MAINTAINERCLEANFILES = Makefile.in