Run jobs with 'set -e' so that they exit on error.
[whenjobs.git] / lib / Makefile.am
index 898f204..31d6ec0 100644 (file)
@@ -15,6 +15,8 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 
+EXTRA_DIST = whenproto.x pa_when.ml $(SOURCES)
+
 libwhenjobsdir = $(libdir)/$(PACKAGE_NAME)
 libwhenjobs_SCRIPTS = whenlib.cma pa_when.cmo
 
@@ -55,9 +57,12 @@ whenproto_aux.ml whenproto_aux.mli: whenproto.x
        $(OCAMLRPCGEN) -int int32 -hyper int64 -aux $<
 
 # Preprocessor for whenjobs files.
-pa_when.cmo: pa_when.ml whenlib.cma
-       $(OCAMLFIND) c $(OCAMLCFLAGS) \
-         -linkpkg whenlib.cma -pp $(CAMLP4OF) -c $< -o $@
+# Note that we intentionally don't want this to depend on any
+# libraries except for camlp4.lib.
+pa_when.cmo: pa_when.ml
+       $(OCAMLFIND) c -g -warn-error CDEFLMPSUVYZX \
+         -package camlp4.lib -linkpkg \
+         -pp $(CAMLP4OF) -c $< -o $@
 
 # Rules for all OCaml files.
 %.cmi: %.mli