From c71428e7a3c69f3478c92b8c92918e51aafe311d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Hinderer?= Date: Tue, 31 Aug 2021 18:17:03 +0200 Subject: Transform runtime/caml/version.h into a configured header This means that, before this commit, runtime/caml/version.h was generated during the build process by a recipe found in runtime/Makefile. After this commit, runtime/caml/version.h is generated by the configure script from runtime/caml/version.h.in This commit makes an effort to guarantee that the version.h file generated by configure is as similar as possible to the one produced by the make recipe before, that's why runtime/caml/version.h.in contains no copyright notice at this stage. It will be added in the following commit. At this stage, the only difference between the two versions of version.h (the one generated by make before and the one generated by configure now) is the coment line produced by configure as the first line of version.h, namely: /* runtime/caml/version.h. Generated from version.h.in by configure. */ but this cannot be avoided and is harmless. --- build-aux/ocaml_version.m4 | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'build-aux') diff --git a/build-aux/ocaml_version.m4 b/build-aux/ocaml_version.m4 index 2ed381ef34..04915ae6e9 100644 --- a/build-aux/ocaml_version.m4 +++ b/build-aux/ocaml_version.m4 @@ -29,6 +29,8 @@ m4_define([OCAML__VERSION_MAJOR], [4]) m4_define([OCAML__VERSION_MINOR], [14]) m4_define([OCAML__VERSION_PATCHLEVEL], [0]) +# Note that the OCAML__VERSION_EXTRA string defined below is always empty +# for officially-released versions of OCaml. m4_define([OCAML__VERSION_EXTRA], [dev0-2021-06-03]) # The OCAML__VERSION_EXTRA_PREFIX macro defined below should be a @@ -67,3 +69,12 @@ m4_syscmd([cat > VERSION << END_OF_VERSION_FILE # The version string must be in the format described in stdlib/sys.mli END_OF_VERSION_FILE ]) + +# Other variants of the version needed here and there in the compiler + +m4_define([OCAML__VERSION_NUMBER], + [m4_format( + [%d%02d%02d], + OCAML__VERSION_MAJOR, + OCAML__VERSION_MINOR, + OCAML__VERSION_PATCHLEVEL)]) -- cgit v1.2.1