Ben Guthro <bguthro(a)virtualiron.com> wrote:
...
Nice work.
I spotted no problems in review, and noticed only one when testing:
In the new file, examples/domain-events/events-c/Makefile.am
diff --git a/examples/domain-events/events-c/Makefile.am
b/examples/domain-events/events-c/Makefile.am
...
@@ -0,0 +1,5 @@
+INCLUDES = -I@top_srcdir@/include
+bin_PROGRAMS = event-test
+event_test_CFLAGS = $(WARN_CFLAGS)
+event_test_SOURCES = event-test.c
+event_test_LDADD = -L@top_srcdir(a)/src/.libs -lvirt
that would fail with a non-srcdir build (i.e., when the
build_dir != srcdir), because then @top_srcdir(a)/src/.libs
doesn't exist, and that causes "make distcheck" to fail.
Also, it is best not to reference libtool's .libs/ directories
directly, so you can use this instead:
diff --git a/examples/domain-events/events-c/Makefile.am
b/examples/domain-events/events-c/Makefile.am
index 1788dac..3c63ca3 100644
--- a/examples/domain-events/events-c/Makefile.am
+++ b/examples/domain-events/events-c/Makefile.am
@@ -2,4 +2,4 @@ INCLUDES = -I@top_srcdir@/include
bin_PROGRAMS = event-test
event_test_CFLAGS = $(WARN_CFLAGS)
event_test_SOURCES = event-test.c
-event_test_LDADD = -L@top_srcdir(a)/src/.libs -lvirt
+event_test_LDADD = @top_builddir(a)/src/libvirt.la
Finally, I noticed that "make check" does not run the new
event-test program that's built there. Should it?