From 56187138970c77cf6b219224c0dc510fa786e7cd Mon Sep 17 00:00:00 2001 From: Enrico Tassi Date: Fri, 4 Nov 2005 16:32:06 +0000 Subject: [PATCH] make profiler silent --- helm/matita/matitaInit.ml | 6 ++++++ helm/matita/template_makefile.in | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/helm/matita/matitaInit.ml b/helm/matita/matitaInit.ml index 1e9ebe2dd..d01275308 100644 --- a/helm/matita/matitaInit.ml +++ b/helm/matita/matitaInit.ml @@ -155,6 +155,7 @@ let registry_defaults = "matita.external_editor", "gvim -f -c 'go %p' %f"; "matita.preserve", "false"; "matita.quiet", "false"; + "matita.profile", "true"; ] let set_registry_values = @@ -178,6 +179,9 @@ let parse_cmdline init_status = "-nodb", Arg.Unit (fun () -> Helm_registry.set_bool "db.nodb" true), ("Avoid using external database connection " ^ "(WARNING: disable many features)"); + "-noprofile", + Arg.Unit (fun () -> Helm_registry.set_bool "matita.profile" false), + "Turns off profiling printings"; ] in let debug_arg_spec = if BuildTimeConf.debug then @@ -197,6 +201,8 @@ let parse_cmdline init_status = Arg.parse arg_spec (add_l args) (usage ()); set_list ~key:"matita.includes" includes; set_list ~key:"matita.args" args; + HExtlib.set_profiling_printings + (fun () -> Helm_registry.get_bool "matita.profile"); CmdLine :: init_status end else init_status diff --git a/helm/matita/template_makefile.in b/helm/matita/template_makefile.in index 6079bb4eb..5ae1165bb 100644 --- a/helm/matita/template_makefile.in +++ b/helm/matita/template_makefile.in @@ -1,7 +1,7 @@ SRC=$(shell find @ROOT@ -name "*.ma" -a -type f) TODO=$(SRC:%.ma=%.mo) -MATITA_FLAGS= +MATITA_FLAGS=-noprofile NODB=false ifeq ($(NODB),true) MATITA_FLAGS += -nodb @@ -14,14 +14,14 @@ MATITADEP=@DEP@ all: $(TODO) clean: - $(MATITACLEAN) $(MATITA_FLAGS) $(SRC) + $(MATITACLEAN) $(MATITA_FLAGS) $(SRC) rm -f $(TODO) %.moo: ($(MATITAC) $(MATITA_FLAGS) -q -I @ROOT@ $< | (grep -v "^make" || true)) @DEPFILE@ : $(SRC) - $(MATITADEP) $(MATITA_FLAGS) -I '@ROOT@' $^ > @DEPFILE@ + $(MATITADEP) $(MATITA_FLAGS) -I '@ROOT@' $^ 1> @DEPFILE@ 2>/dev/null # this is the depend for full targets like: # dir/dir/name.moo: dir/dir/name.ma dir/dep.moo -- 2.39.2