From b53c175d61e9cac8e5a95abee9d6c05032d284b5 Mon Sep 17 00:00:00 2001 From: Geoff Levand Date: Fri, 16 Mar 2012 22:23:35 -0700 Subject: [PATCH 1/1] Convert test to automake Signed-off-by: Geoff Levand --- Makefile.am | 2 +- configure.ac.in | 1 + discover/Makefile.am | 14 +++++++++----- test/Makefile.am | 35 +++++++++++++++++++++++++++++++++++ 4 files changed, 46 insertions(+), 6 deletions(-) create mode 100644 test/Makefile.am diff --git a/Makefile.am b/Makefile.am index a89b0b0..feff84b 100644 --- a/Makefile.am +++ b/Makefile.am @@ -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 diff --git a/configure.ac.in b/configure.ac.in index 28e96d3..c62ef56 100644 --- a/configure.ac.in +++ b/configure.ac.in @@ -183,6 +183,7 @@ AC_CONFIG_FILES([ discover/Makefile lib/Makefile man/Makefile + test/Makefile ui/Makefile ui/common/Makefile ui/ncurses/Makefile diff --git a/discover/Makefile.am b/discover/Makefile.am index 10d4d65..5ddba1f 100644 --- a/discover/Makefile.am +++ b/discover/Makefile.am @@ -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 index 0000000..2f0625d --- /dev/null +++ b/test/Makefile.am @@ -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 -- 2.39.2