From: Richard W.M. Jones Date: Tue, 17 Sep 2013 11:13:32 +0000 (+0100) Subject: Rename config.ml -> goaljobs_config.ml to avoid conflicting module names. X-Git-Tag: 0.2~37 X-Git-Url: http://git.annexia.org/?p=goaljobs.git;a=commitdiff_plain;h=8fbc663ca72ef0c0a73cfb0f41d363e0c89a510e Rename config.ml -> goaljobs_config.ml to avoid conflicting module names. It would be useful to allow user scripts to use the module name 'Config'. --- diff --git a/.depend b/.depend index 2440c82..e4f3d09 100644 --- a/.depend +++ b/.depend @@ -1,5 +1,5 @@ -config.cmo : -config.cmx : goaljobs.cmi : -goaljobs.cmo : config.cmo goaljobs.cmi -goaljobs.cmx : config.cmx goaljobs.cmi +goaljobs.cmo : goaljobs_config.cmo goaljobs.cmi +goaljobs.cmx : goaljobs_config.cmx goaljobs.cmi +goaljobs_config.cmo : +goaljobs_config.cmx : diff --git a/.gitignore b/.gitignore index 78fe55c..68cd58c 100644 --- a/.gitignore +++ b/.gitignore @@ -17,12 +17,12 @@ Makefile /config.h /config.h.in /config.log -/config.ml /config.status /config.sub /configure /examples/compile-c/compile /examples/compile-c/program +/goaljobs_config.ml /goaljobs.spec /goaljobs-*.tar.gz /install-sh diff --git a/Makefile.am b/Makefile.am index 53f50d3..e752ae5 100644 --- a/Makefile.am +++ b/Makefile.am @@ -20,21 +20,23 @@ include common-rules.mk ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = \ - config.ml.in \ COPYING \ goaljobs \ + goaljobs_config.ml.in \ + goaljobs.ml \ + goaljobs.mli \ goaljobs.spec \ goaljobs.spec.in \ META.in \ NOTES \ + pa_goal.ml \ README \ - $(sources) \ - pa_goal.ml + TODO SUBDIRS = . examples tests sources = \ - config.ml \ + goaljobs_config.ml \ goaljobs.ml \ goaljobs.mli @@ -46,10 +48,10 @@ bin_SCRIPTS = goaljobs noinst_SCRIPTS = goaljobs.cma goaljobs.cmxa pa_goal.cmo # Library. -goaljobs.cma: config.cmo goaljobs.cmo +goaljobs.cma: goaljobs_config.cmo goaljobs.cmo $(OCAMLFIND) ocamlc -a -o $@ $(OCAMLCFLAGS) $(OCAMLCPACKAGES) $^ -goaljobs.cmxa: config.cmx goaljobs.cmx +goaljobs.cmxa: goaljobs_config.cmx goaljobs.cmx $(OCAMLFIND) ocamlopt -a -o $@ $(OCAMLOPTFLAGS) $(OCAMLOPTPACKAGES) $^ # Preprocessor for goaljobs scripts. diff --git a/TODO b/TODO new file mode 100644 index 0000000..50b3c4b --- /dev/null +++ b/TODO @@ -0,0 +1,6 @@ +Enhancements to pa_goal: + + - Include the goal name, source file location in the generated + rule so we can improve error messages. + + - Implement some sort of tracing based on the above. diff --git a/configure.ac b/configure.ac index 3466970..7097795 100644 --- a/configure.ac +++ b/configure.ac @@ -89,7 +89,7 @@ if test "x$PERLDOC" = "x"; then fi AC_CONFIG_HEADERS([config.h]) -AC_CONFIG_FILES([config.ml +AC_CONFIG_FILES([goaljobs_config.ml goaljobs.spec Makefile META diff --git a/goaljobs.ml b/goaljobs.ml index c68bc31..53db37c 100644 --- a/goaljobs.ml +++ b/goaljobs.ml @@ -19,6 +19,8 @@ open Unix open Printf +open Goaljobs_config + type goal_result_t = Goal_OK | Goal_failed of string exception Goal_result of goal_result_t @@ -168,7 +170,7 @@ let init () = let args = ref [] in let display_version () = - printf "%s %s\n" Config.package_name Config.package_version; + printf "%s %s\n" package_name package_version; exit 0 in diff --git a/config.ml.in b/goaljobs_config.ml.in similarity index 100% rename from config.ml.in rename to goaljobs_config.ml.in