diff --git a/Makefile.am b/Makefile.am index d63ef632cb..30f37578ce 100644 --- a/Makefile.am +++ b/Makefile.am @@ -222,3 +222,6 @@ checksrc: tidy: (cd src && $(MAKE) tidy) (cd lib && $(MAKE) tidy) + +clean-local: + (cd tests && $(MAKE) clean) diff --git a/tests/libtest/Makefile.am b/tests/libtest/Makefile.am index d3d7860afa..a4f6edb7a0 100644 --- a/tests/libtest/Makefile.am +++ b/tests/libtest/Makefile.am @@ -96,11 +96,13 @@ libstubgss_la_LIBADD = libstubgss_la_DEPENDENCIES = endif +BUNDLE=libtests + if USE_TEST_BUNDLES libtest_bundle.c: $(top_srcdir)/tests/mk-bundle.pl Makefile.inc $(FIRSTFILES) lib1521.c @PERL@ $(top_srcdir)/tests/mk-bundle.pl $(srcdir) > libtest_bundle.c -noinst_PROGRAMS = libtests +noinst_PROGRAMS = $(BUNDLE) nodist_libtests_SOURCES = libtest_bundle.c libtests_SOURCES = $(TESTUTIL) $(TSTTRACE) libtests_LDADD = $(TESTUTIL_LIBS) @@ -133,3 +135,6 @@ if DEBUGBUILD # for debug builds, we scan the sources on all regular make invokes all-local: checksrc endif + +clean-local: + rm -f $(BUNDLE) diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am index 0e7605e7ee..3b4495c49e 100644 --- a/tests/unit/Makefile.am +++ b/tests/unit/Makefile.am @@ -58,12 +58,14 @@ if CURLDEBUG AM_CPPFLAGS += -DCURLDEBUG endif +BUNDLE=units + if BUILD_UNITTESTS if USE_TEST_BUNDLES unit_bundle.c: $(top_srcdir)/tests/mk-bundle.pl Makefile.inc @PERL@ $(top_srcdir)/tests/mk-bundle.pl $(srcdir) > unit_bundle.c -noinst_PROGRAMS = units +noinst_PROGRAMS = $(BUNDLE) nodist_units_SOURCES = unit_bundle.c CLEANFILES = unit_bundle.c else @@ -85,3 +87,6 @@ checksrc: $(CHECKSRC)(@PERL@ $(top_srcdir)/scripts/checksrc.pl -D$(srcdir) \ -W$(srcdir)/unit_bundle.c \ $(srcdir)/*.[ch]) + +clean-local: + rm -f $(BUNDLE)