Skip to content
Snippets Groups Projects
Commit 484496ce authored by Erwan Jahier's avatar Erwan Jahier
Browse files

The entete was included twice in generated files.

parent 1407d8a2
No related branches found
No related tags found
No related merge requests found
......@@ -163,7 +163,7 @@ lus2lic:
# TEST, NON REGR. ETC...
TESTDIR=./tests
TESTDIR=./test
.PHONY: diff test log
......@@ -184,9 +184,9 @@ Clean:
rm -rf $(OBJDIR)
test:
pushd $(TESTDIR)
cd $(TESTDIR)
make
popd
cd ..
ci: $(OBJDIR)/version.ml
......@@ -200,8 +200,6 @@ amend:
git commit -a -F log --amend && rm -f $(OBJDIR)/version.ml
push:
git push git+ssh://jahier@scm.forge.imag.fr/var/lib/gforge/chroot/scmrepos/git/lustre/lustre.git
git push git+ssh://jahier@scm.forge.imag.fr/var/lib/gforge/chroot/scmrepos/git/lustre/lus2lic.git
xxx:
remote add --track master origin git+ssh://jahier@scm.forge.imag.fr/var/lib/gforge/chroot/scmrepos/git/lustre/lustre.git
......@@ -116,10 +116,10 @@ let dump_entete oc =
("",0)
Sys.argv
and
date = Printf.sprintf "%d/%02d/%02d"
(1900+time.Unix.tm_year)
(time.Unix.tm_mon+1)
date = Printf.sprintf "%02d/%02d/%d"
(time.Unix.tm_mday)
(time.Unix.tm_mon+1)
(1900+time.Unix.tm_year)
and
time_str = Printf.sprintf "%02d:%02d:%02d"
(time.Unix.tm_hour)
......
(* Time-stamp: <modified the 11/12/2012 (at 15:30) by Erwan Jahier> *)
(* Time-stamp: <modified the 11/01/2013 (at 16:51) by Erwan Jahier> *)
(** Common to lus2lic and lic2loc *)
......@@ -32,7 +32,8 @@ let pragma x = x._pragma
(* affichage standard: *)
let details lxm = (
let file = if !Global.nonreg_test then
(* during non-regression test, having absolute paths printed complicate the perusal. *)
(* during non-regression test, having absolute paths printed
complicate the perusal (because of the diff output). *)
Filename.basename lxm._file
else
lxm._file
......
(* Time-stamp: <modified the 10/01/2013 (at 15:09) by Erwan Jahier> *)
(* Time-stamp: <modified the 11/01/2013 (at 17:02) by Erwan Jahier> *)
......@@ -140,44 +140,6 @@ let (get_source_list : string list -> AstV6.pack_or_model list) =
p::packed_list
let dump_entete oc =
let time = Unix.localtime (Unix.time ()) in
let sys_call, _ = Array.fold_left
(fun (acc,i) x ->
if 70 < i + (String.length x) then
acc ^ "\n--\t\t" ^ x, String.length ("\n--\t\t" ^ x)
else
acc ^ " " ^ x , (i+1+(String.length x))
)
("",0)
Sys.argv
and
date = (
(string_of_int time.Unix.tm_mday) ^ "/" ^
(string_of_int (time.Unix.tm_mon+1)) ^ "/" ^
(string_of_int (1900+time.Unix.tm_year))
)
and time_str = (
(string_of_int time.Unix.tm_hour) ^ ":" ^
(if time.Unix.tm_min < 10 then "0" else "") ^
(string_of_int time.Unix.tm_min) ^ ":" ^
(if time.Unix.tm_sec < 10 then "0" else "") ^
(string_of_int time.Unix.tm_sec)
)
(* and user = Unix.getlogin () *)
and hostname = Unix.gethostname ()
in
output_string oc
("-- This file was generated by lus2lic version " ^ Version.str ^
".\n--\t" ^ sys_call ^ "
-- on " ^ hostname ^
(* "by "^ user ^ *)
" the " ^ date ^ " at " ^ time_str ^ "\n\n");
flush oc
let my_exit i =
close_out !Global.oc;
if Sys.file_exists !Global.outfile then Sys.remove !Global.outfile;
......@@ -206,7 +168,6 @@ let main = (
in
if !Global.outfile <> "" then Global.oc := open_out !Global.outfile;
let lic_prg = Compile.doit nsl main_node in
dump_entete !Global.oc;
LicPrg.to_file !Global.oc lic_prg;
Verbose.exe ~level:3 (fun () ->
Gc.print_stat stdout
......
......@@ -62,8 +62,8 @@ let help opt ()= (
)
let full_usage os opt = (
Printf.fprintf os "%s\n" usage_msg;
let l = List.rev opt._user_man in
List.iter (pspec os opt) l;
(* let l = List.rev opt._user_man in *)
(* List.iter (pspec os opt) l; *)
let l = List.rev (opt._hidden_man) in
List.iter (pspec os opt) l
)
......@@ -225,12 +225,12 @@ let mkoptab (opt:t) : unit = (
mkopt opt ~hide:true
["-unit"]
(Arg.Set Global.run_unit_test)
["Run some (internal) unit tests"]
["Run embedded unit tests"]
;
mkopt opt ~hide:true
["--nonreg-test"]
(Arg.Set Global.nonreg_test)
["(internal)"]
["Avoid printing full path error msgs to ease non-reg test decision"]
;
(* misc debug flag *)
mkopt opt ~hide:true
......
This diff is collapsed.
Test Run By jahier on Fri Jan 11 16:13:34 2013
Test Run By jahier on Fri Jan 11 17:02:48 2013
Native configuration is i686-pc-linux-gnu
=== lus2lic tests ===
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment