Commit 452e17d5 authored by erwan's avatar erwan

Build: rationalisation of version files handling

parent 8c7123e7
......@@ -13,7 +13,7 @@ lutin-utils/src/lutinUtils.ml: lutin-utils/src/lutinUtils.idl
cd lutin-utils/src/; make
###################################################
build: setup.data
build: setup.data lutin/src/version.ml
ocaml setup.ml -build
setup.ml:_oasis lutin/src/version.ml polka/vector.ml lutin-utils/src/lutinUtils.ml
......
#
SHA:=`git log -1 --pretty=format:"%h"`
VERSION=$(shell git describe --tags)
echover:
echo "VERSION=$(VERSION)"
echo "PRE_VERSION=$(PRE_VERSION)"
lutin/src/version.ml:
cd $(LURETTE_PATH) ; \
echo "let str=\"$(VERSION)\"" > lutin/src/version.ml ; \
echo "let sha=\"$(SHA)\"" >> lutin/src/version.ml ; \
rm -f version.tex ; \
date +VERSION_DATE=%d-%m-%y > version.tex ; \
echo "\\\newcommand{\\\version}{$(VERSION)}" > doc/version.tex ; \
echo "\\\newcommand{\\\sha}{$(SHA)}" >> doc/version.tex ; \
echo "\\\newcommand{\\\versionname}{Trilby}" >> doc/version.tex ; \
echo "\\\newcommand{\\\versiondate}{`date +%d-%m-%y`}" >> doc/version.tex ;\
[ -d doc/lutin-man/objs ] || mkdir doc/lutin-man/objs; \
cp doc/version.tex doc/lutin-man/objs/ ;\
cp doc/version.tex doc/lutin-man/
......@@ -41,7 +41,7 @@ Library lutin
Install:true
CompiledObject: native
XMETAEnable: true
InternalModules: Auto2Lucky,AutoGen,Bddd,CheckEnv,CheckType,CkIdentInfo,CkTypeEff,CoAlgExp,CoIdent,CoTraceExp,Constraint,Draw,Exp,ExpEval,Expand,ExprUtil,FGen,Fair_bddd,Formula_to_bdd,GenOcamlGlue,Glue,Gne,Guard,Lexeme,LoopWeights,Luc2alice,Luc2c,LucFGen,Lucky,LutErrors,LutExe,LutLexer,LutParser,LutPredef,LutProg,LutVersion,MainArg,Ne,Parsers,Poly_draw,Polyhedron,Prevar,Prog,Reactive,Rif,Sol_nb,Solver,Store,Syntaxe,SyntaxeDump,Thickness,Type,Util,Utils,Value,Var,Verbose,Version
InternalModules: Auto2Lucky,AutoGen,Bddd,CheckEnv,CheckType,CkIdentInfo,CkTypeEff,CoAlgExp,CoIdent,CoTraceExp,Constraint,Draw,Exp,ExpEval,Expand,ExprUtil,FGen,Fair_bddd,Formula_to_bdd,GenOcamlGlue,Glue,Gne,Guard,Lexeme,LoopWeights,Luc2alice,Luc2c,LucFGen,Lucky,LutErrors,LutExe,LutLexer,LutParser,LutPredef,LutProg,Version,MainArg,Ne,Parsers,Poly_draw,Polyhedron,Prevar,Prog,Reactive,Rif,Sol_nb,Solver,Store,Syntaxe,SyntaxeDump,Thickness,Type,Util,Utils,Value,Var,Verbose
DllLib: libgmp.so dllcamlidl.so
Library bddrand
......
......@@ -22,7 +22,7 @@ let print_header
(auto : AutoGen.t) =
(
fprintf os
"-- generated by lutin2 %s.%s\n" LutVersion.number LutVersion.release;
"-- generated by lutin2 %s\n" Version.str ;
fprintf os
"-- file: %s node: %s\n"
srcname
......
(*
"imp"
Trilby (ou le Lutin d'Argail, Charles Nodier 1822)
Puck (the imp from A Midsummer Night's Dream, Shakespeare, 1594~1596)
? BUG et ARACH
*)
let number = "Trilby"
let release = "0"
......@@ -2,9 +2,7 @@ open Version
open Arg
let version =
Printf.sprintf "lang: %s.%s, tool: %s (\"%s\")\n"
LutVersion.number
LutVersion.release
Printf.sprintf "%s (\"%s\")\n"
Version.str
Version.sha
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment