mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
ocaml: Enable parallel builds.
Commitf75142c577disabled parallel builds in the ocaml subdirectory (which was the correct thing to do). This made building the OCaml tests in particular very slow. Therefore fix things so that parallel builds can be used again. See also discussion here about different approaches: https://www.redhat.com/archives/libguestfs/2014-March/thread.html#00223 This reintroduces commitdce94f3e26.
This commit is contained in:
@@ -54,15 +54,25 @@ noinst_LIBRARIES = libguestfsocaml.a
|
||||
# 'libmlguestfs.a' and if run at the same time, they will stomp on or
|
||||
# corrupt each others copy. Hence we have to serialize the calls.
|
||||
|
||||
mlguestfs.cma: libguestfsocaml.a guestfs.cmo
|
||||
CLEANFILES += stamp-mlguestfs
|
||||
|
||||
mlguestfs.cma mlguestfs.cmxa: stamp-mlguestfs
|
||||
|
||||
guestfs_cmm = guestfs.cmo
|
||||
if HAVE_OCAMLOPT
|
||||
guestfs_cmm += guestfs.cmx
|
||||
endif
|
||||
|
||||
stamp-mlguestfs: libguestfsocaml.a $(guestfs_cmm)
|
||||
$(OCAMLMKLIB) -o mlguestfs \
|
||||
$(libguestfsocaml_a_OBJECTS) guestfs.cmo \
|
||||
-L$(top_builddir)/src/.libs -lguestfs
|
||||
|
||||
mlguestfs.cmxa: libguestfsocaml.a guestfs.cmx
|
||||
if HAVE_OCAMLOPT
|
||||
$(OCAMLMKLIB) -o mlguestfs \
|
||||
$(libguestfsocaml_a_OBJECTS) guestfs.cmx \
|
||||
-L$(top_builddir)/src/.libs -lguestfs
|
||||
endif
|
||||
touch $@
|
||||
|
||||
libguestfsocaml_a_CPPFLAGS = \
|
||||
-DGUESTFS_PRIVATE=1 \
|
||||
@@ -189,7 +199,3 @@ install-data-hook:
|
||||
CLEANFILES += $(noinst_DATA)
|
||||
|
||||
endif
|
||||
|
||||
# Tell version 3.79 and up of GNU make to not build goals in this
|
||||
# directory in parallel.
|
||||
.NOTPARALLEL:
|
||||
|
||||
Reference in New Issue
Block a user