[libvirt] [libvirt-designer][PATCH] Makefile: Build tests at the same time as the rest

From my libvirt development experience, I'm used to just run make from my text editor. For instance, when changing some function
Currently, since we were using check_PROGRAMS in the Makefile template, the test program build was postponed until 'make check' was run. That's not optimal. Lets build (not run!) test program in the 'make all' phase. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- header, I just run make and let the compiler catch all the places that need fixing. I think it's common practice. libvirt-designer/Makefile.am | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libvirt-designer/Makefile.am b/libvirt-designer/Makefile.am index bda4240..fd7627d 100644 --- a/libvirt-designer/Makefile.am +++ b/libvirt-designer/Makefile.am @@ -82,9 +82,9 @@ libvirt-designer-enum-types.c: $(DESIGNER_HEADER_FILES) libvirt-designer-enum-ty $(AM_V_GEN) ( $(GLIB_MKENUMS) --template $(srcdir)/libvirt-designer-enum-types.c.template $(DESIGNER_HEADER_FILES:%=$(srcdir)/%) ) | \ sed -e "s/G_TYPE_VIR_CONFIG/GVIR_CONFIG_TYPE/" -e "s/g_vir/gvir/" > libvirt-designer-enum-types.c -check_PROGRAMS = test-designer-domain +noinst_PROGRAMS = test-designer-domain -TESTS = $(check_PROGRAMS) +TESTS = $(noinst_PROGRAMS) test_designer_domain_CFLAGS = \ -I$(top_srcdir) \ -- 2.0.5

Hey, On Wed, Mar 04, 2015 at 02:05:07PM +0100, Michal Privoznik wrote:
Currently, since we were using check_PROGRAMS in the Makefile template, the test program build was postponed until 'make check' was run. That's not optimal. Lets build (not run!) test program in the 'make all' phase.
Looks good to me as make check still triggers running of the test program, ACK. Christophe

On 04.03.2015 14:54, Christophe Fergeau wrote:
Hey,
On Wed, Mar 04, 2015 at 02:05:07PM +0100, Michal Privoznik wrote:
Currently, since we were using check_PROGRAMS in the Makefile template, the test program build was postponed until 'make check' was run. That's not optimal. Lets build (not run!) test program in the 'make all' phase.
Looks good to me as make check still triggers running of the test program, ACK.
Yep. That's my intention. Now that I pushed this one, it works the same way as libvirt does. Awesome! Thanks. Michal
participants (2)
-
Christophe Fergeau
-
Michal Privoznik