Commits

camlspotter  committed 22ffd0f

auto update of OMyMakefile

  • Participants
  • Parent commits e2d54c9

Comments (0)

Files changed (1)

 #|Warnings treated as non errors
 OCAMLWARNING_NON_ERROR[] = 4 9
 
+#|If it is false, warnings do not stop the compilation even if they are listed in OCAMLWARNING_NON_ERROR
+#If you are in developing something, turn it ture!
+OCAMLWARNING_STOP_AT_ERROR_WARNING=false
+
 #|The maximum warning value.
 # This is the maximum warning ID NOT of the current OCaml compiler,
 #                                BUT of the OCaml compiler used by the author.
 
 #|Function to build warning switches
 OCAMLWARNING_MAKE()=
-    return -w A-$(concat -,$(OCAMLWARNING_IGNORE)) -warn-error +1..$(OCAMLWARNING_MAX)-$(concat -, $(OCAMLWARNING_NON_ERROR))
+    if $(OCAMLWARNING_STOP_AT_ERROR_WARNING)
+        return -w A-$(concat -,$(OCAMLWARNING_IGNORE)) -warn-error +1..$(OCAMLWARNING_MAX)-$(concat -, $(OCAMLWARNING_NON_ERROR))
+    else
+        return -w A-$(concat -,$(OCAMLWARNING_IGNORE)) -warn-error a
 
 #|OMyMakefile assumes installation with .cmt files
 OCAMLANNOTFLAGS = -annot -bin-annot