Index: /CMT/HEAD/ChangeLog
===================================================================
--- /CMT/HEAD/ChangeLog	(revision 458)
+++ /CMT/HEAD/ChangeLog	(revision 459)
@@ -1,2 +1,64 @@
+2008-05-30    <rybkin@lal.in2p3.fr> 360
+	
+	* source/cmt_log.h: Introduce an enumeration to hold diagnostic messages
+	levels (Debug, Info, Warning, Error, Fatal). Implement a class to hold
+	and manage diagnostic messages prefix, level (default values: #CMT--->,
+	Info), and functions to produce	diagnostic messages
+	* source/cmt_parser.cxx: Implement functions to configure diagnostic
+	messages prefix, and level using the environment variables CMTMSGPREFIX,
+	and CMTDEBUG, CMTINFO, CMTWARNING, CMTERROR, CMTFATAL (in order	of
+	precedence) if set to a non-empty string. Extend functions to configure
+	the diagnostic messages level using the existing command line options
+	-warnings (Warning), -disable_warnings (Error), -quiet (Fatal).
+	Introduce the CMTFLAGS environment variable (set up automatically) in order
+	to contain command line options (currently, to configure the diagnostic
+	messages level and the structuring style) so as to pass the flags to
+	recursive cmt invocations. If CMTFLAGS exists in the environment, the
+	flags from it are processed before the command line options. Implement
+	the CMTFLAGS functionality described above.
+	Use the diagnostic message functions for the messages
+	* source/cmt.h: idem
+	* source/cmt_tag.cxx: Use the diagnostic message functions for the messages
+	* source/cmt_awk.cxx: idem
+	* source/cmt_system.cxx: idem
+	* source/cmt_use.cxx: idem
+	* source/cmt_install_area.cxx: idem
+	* source/cmt_fragment.cxx: idem
+	* source/cmt_generators.cxx: idem
+	* source/cmt_constituent.cxx: idem
+	* source/cmt_syntax.cxx: idem
+	* source/cmt_triggers.cxx: idem
+	* source/cmt_error.cxx: idem
+	* source/cmt_model.cxx: idem
+	* source/cmt_commands.cxx: idem
+	* source/cmt_project.cxx: idem
+	* source/cmt_pattern.cxx: idem
+	* source/cmt_lock.cxx: idem
+	* source/cmt_generator.cxx: idem
+	* source/cmt_cvs.cxx: idem
+	* source/cmt_symbol.cxx: idem
+	* mgr/requirements: Do not use the -quiet command line option
+	* mgr/fragments/constituent:  idem
+	* mgr/fragments/make_setup: idem
+	* mgr/fragments/check_application_header: idem
+	* mgr/fragments/constituents_header: idem
+	* mgr/fragments/constituent_lock: idem
+	* mgr/fragments/generator_header: idem
+	* mgr/fragments/cleanup_header: Improve control of Make verbosity
+	* mgr/fragments/make_setup_nmake: Do not use the -quiet command line option
+	* mgr/fragments/nmake/constituent: idem
+	* mgr/fragments/nmake/check_application_header: idem
+	* mgr/fragments/nmake/constituents_header: idem
+	* mgr/fragments/nmake/yacc: idem
+	* mgr/fragments/nmake/constituent_lock: idem
+	* mgr/fragments/nmake/lex: idem
+	* mgr/fragments/nmake/generator_header: idem
+	* mgr/fragments/nmake/yacc_library: idem
+	* mgr/fragments/nmake/lex_library: idem
+	* src/Makefile.header: idem, improve control of Make verbosity
+	* src/constituents.make: Do not use the -quiet command line option
+	* src/NMakefile.header: idem
+	* src/constituents.nmake: idem
+
 2008-05-14    <rybkin@lal.in2p3.fr> 359
 	
Index: /CMT/HEAD/mgr/cmt_dependencies.make
===================================================================
--- /CMT/HEAD/mgr/cmt_dependencies.make	(revision 458)
+++ /CMT/HEAD/mgr/cmt_dependencies.make	(revision 459)
@@ -1,30 +1,30 @@
 cmt_cxx_dependencies =  ../source/cmt.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h 
-cmt_awk_cxx_dependencies =  ../source/cmt_awk.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_regexp.h   ../source/cmt_awk.h   ../source/cmt_vector.h   ../source/cmt_system.h 
+cmt_awk_cxx_dependencies =  ../source/cmt_awk.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_regexp.h   ../source/cmt_awk.h   ../source/cmt_vector.h   ../source/cmt_system.h   ../source/cmt_log.h 
 cmt_branch_cxx_dependencies =  ../source/cmt_branch.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h 
-cmt_constituent_cxx_dependencies =  ../source/cmt_constituent.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_deps_builder.h   ../source/cmt_generator.h   ../source/cmt_branch.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h 
+cmt_constituent_cxx_dependencies =  ../source/cmt_constituent.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_deps_builder.h   ../source/cmt_generator.h   ../source/cmt_branch.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_log.h 
 cmt_deps_builder_cxx_dependencies =  ../source/cmt_deps_builder.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_deps_builder.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_log.h 
-cmt_fragment_cxx_dependencies =  ../source/cmt_fragment.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_branch.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h 
-cmt_generator_cxx_dependencies =  ../source/cmt_generator.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_deps_builder.h   ../source/cmt_generator.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_generators.h 
+cmt_fragment_cxx_dependencies =  ../source/cmt_fragment.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_branch.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_log.h 
+cmt_generator_cxx_dependencies =  ../source/cmt_generator.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_deps_builder.h   ../source/cmt_generator.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_generators.h   ../source/cmt_log.h 
 cmt_include_cxx_dependencies =  ../source/cmt_include.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_map.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_log.h 
 cmt_parser_cxx_dependencies =  ../source/cmt_parser.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_version.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_deps_builder.h   ../source/cmt_generator.h   ../source/cmt_error.h   ../source/cmt_cvs.h   ../source/cmt_lock.h   ../source/cmt_triggers.h   ../source/cmt_model.h   ../source/cmt_syntax.h   ../source/cmt_install_area.h   ../source/cmt_sequence.h   ../source/cmt_log.h   ../source/cmt_commands.h 
 cmt_script_cxx_dependencies =  ../source/cmt_script.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_script.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h 
 cmt_string_cxx_dependencies =  ../source/cmt_string.cxx   ../source/cmt_std.h   ../source/cmt_string.h 
-cmt_system_cxx_dependencies =  ../source/cmt_system.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_error.h   ../source/cmt_map.h 
+cmt_system_cxx_dependencies =  ../source/cmt_system.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_error.h   ../source/cmt_map.h   ../source/cmt_log.h 
 cmt_tag_cxx_dependencies =  ../source/cmt_tag.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_log.h 
-cmt_use_cxx_dependencies =  ../source/cmt_use.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_error.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_syntax.h 
-cmt_symbol_cxx_dependencies =  ../source/cmt_symbol.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h 
-cmt_error_cxx_dependencies =  ../source/cmt_error.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_error.h   ../source/cmt_vector.h 
-cmt_pattern_cxx_dependencies =  ../source/cmt_pattern.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_error.h   ../source/cmt_syntax.h 
+cmt_use_cxx_dependencies =  ../source/cmt_use.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_error.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_syntax.h   ../source/cmt_log.h 
+cmt_symbol_cxx_dependencies =  ../source/cmt_symbol.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_log.h 
+cmt_error_cxx_dependencies =  ../source/cmt_error.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_error.h   ../source/cmt_vector.h   ../source/cmt_log.h 
+cmt_pattern_cxx_dependencies =  ../source/cmt_pattern.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_error.h   ../source/cmt_syntax.h   ../source/cmt_log.h 
 cmt_language_cxx_dependencies =  ../source/cmt_language.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_language.h   ../source/cmt_branch.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h 
-cmt_cvs_cxx_dependencies =  ../source/cmt_cvs.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_cvs.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_project.h 
+cmt_cvs_cxx_dependencies =  ../source/cmt_cvs.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_cvs.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_project.h   ../source/cmt_log.h 
 cmt_group_cxx_dependencies =  ../source/cmt_group.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_group.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h 
 cmt_database_cxx_dependencies =  ../source/cmt_database.cxx   ../source/cmt_vector.h   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h 
-cmt_lock_cxx_dependencies =  ../source/cmt_lock.cxx   ../source/cmt_std.h   ../source/cmt_lock.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_error.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h 
-cmt_triggers_cxx_dependencies =  ../source/cmt_triggers.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_triggers.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_project.h   ../source/cmt_syntax.h 
+cmt_lock_cxx_dependencies =  ../source/cmt_lock.cxx   ../source/cmt_std.h   ../source/cmt_lock.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_error.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_log.h 
+cmt_triggers_cxx_dependencies =  ../source/cmt_triggers.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_triggers.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_awk.h   ../source/cmt_map.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_project.h   ../source/cmt_syntax.h   ../source/cmt_log.h 
 cmt_regexp_cxx_dependencies =  ../source/cmt_regexp.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_regexp.h   ../source/cmt_vector.h   ../source/cmt_system.h 
-cmt_model_cxx_dependencies =  ../source/cmt_model.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_model.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h 
-cmt_project_cxx_dependencies =  ../source/cmt_project.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_syntax.h   ../source/cmt_error.h 
-cmt_syntax_cxx_dependencies =  ../source/cmt_syntax.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_syntax.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_error.h   ../source/cmt_branch.h   ../source/cmt_language.h   ../source/cmt_cmtpath_pattern.h 
-cmt_install_area_cxx_dependencies =  ../source/cmt_install_area.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_parser.h   ../source/cmt.h   ../source/cmt_install_area.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_syntax.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_cmtpath_pattern.h 
+cmt_model_cxx_dependencies =  ../source/cmt_model.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_model.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_fragment.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_log.h 
+cmt_project_cxx_dependencies =  ../source/cmt_project.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_syntax.h   ../source/cmt_error.h   ../source/cmt_log.h 
+cmt_syntax_cxx_dependencies =  ../source/cmt_syntax.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_syntax.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_error.h   ../source/cmt_branch.h   ../source/cmt_language.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_log.h 
+cmt_install_area_cxx_dependencies =  ../source/cmt_install_area.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt_parser.h   ../source/cmt.h   ../source/cmt_install_area.h   ../source/cmt_map.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_syntax.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_log.h 
 cmt_cmtpath_pattern_cxx_dependencies =  ../source/cmt_cmtpath_pattern.cxx   ../source/cmt_vector.h   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_branch.h   ../source/cmt_fragment.h   ../source/cmt_group.h   ../source/cmt_constituent.h   ../source/cmt_language.h   ../source/cmt_map.h   ../source/cmt_pattern.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_cmtpath_pattern.h   ../source/cmt_database.h   ../source/cmt_syntax.h 
 cmt_sequence_cxx_dependencies =  ../source/cmt_sequence.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_regexp.h   ../source/cmt_awk.h   ../source/cmt_sequence.h   ../source/cmt_vector.h   ../source/cmt_system.h 
@@ -32,3 +32,3 @@
 cmt_scope_section_cxx_dependencies =  ../source/cmt_scope_section.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_parser.h   ../source/cmt_scope_section.h 
 cmt_log_cxx_dependencies =  ../source/cmt_log.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_log.h   ../source/cmt_vector.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h 
-cmt_commands_cxx_dependencies =  ../source/cmt_commands.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_commands.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h 
+cmt_commands_cxx_dependencies =  ../source/cmt_commands.cxx   ../source/cmt_std.h   ../source/cmt_string.h   ../source/cmt_vector.h   ../source/cmt_map.h   ../source/cmt_parser.h   ../source/cmt_regexp.h   ../source/cmt_system.h   ../source/cmt.h   ../source/cmt_commands.h   ../source/cmt_include.h   ../source/cmt_script.h   ../source/cmt_pattern.h   ../source/cmt_scope_section.h   ../source/cmt_use.h   ../source/cmt_tag.h   ../source/cmt_symbol.h   ../source/cmt_awk.h   ../source/cmt_project.h   ../source/cmt_log.h 
Index: /CMT/HEAD/mgr/fragments/check_application_header
===================================================================
--- /CMT/HEAD/mgr/fragments/check_application_header	(revision 458)
+++ /CMT/HEAD/mgr/fragments/check_application_header	(revision 459)
@@ -6,5 +6,5 @@
 ${CONSTITUENT}check ::
 	@echo "------> starting ${CONSTITUENT}check"
-	@$(cmtexe) -quiet build constituent_makefile ${CONSTITUENT}; $(MAKE) -f ${CONSTITUENT}.make build_strategy=keep_makefiles ${CONSTITUENT}check
+	@$(cmtexe) build constituent_makefile ${CONSTITUENT}; $(MAKE) -f ${CONSTITUENT}.make build_strategy=keep_makefiles ${CONSTITUENT}check
 
 #-- end of check_application_header ------
Index: /CMT/HEAD/mgr/fragments/cleanup_header
===================================================================
--- /CMT/HEAD/mgr/fragments/cleanup_header	(revision 458)
+++ /CMT/HEAD/mgr/fragments/cleanup_header	(revision 459)
@@ -6,18 +6,22 @@
 ifndef PEDANTIC
 .DEFAULT::
-	@echo "#CMT> Warning: $@: No rule for such target" >&2; exit
+	$(echo) "(${CONSTITUENT}.make) $@: No rule for such target" >&2
+#	@echo "#CMT> Warning: $@: No rule for such target" >&2; exit
 else
 .DEFAULT::
-	@echo "#CMT> PEDANTIC MODE >> No rule for target $@" >&2
-	@if test $@ = "$(cmt_final_setup)" -o\
+	$(echo) "(${CONSTITUENT}.make) PEDANTIC: $@: No rule for such target" >&2
+	if test $@ = "$(cmt_final_setup)" -o\
 	 $@ = "$(cmt_final_setup_${CONSTITUENT})" ; then\
 	 found=n; for s in 1 2 3 4 5; do\
 	 sleep $$s; test ! -f $@ || { found=y; break; }\
 	 done; if test $$found = n; then\
-	 echo "#CMT> PEDANTIC MODE >> $@ seems to be missing. Ignore it for now" >&2; exit 0 ; fi;\
+	 test -z "$(cmtmsg)" ||\
+	 echo "$(CMTMSGPREFIX)" "(${CONSTITUENT}.make) PEDANTIC: $@: Seems to be missing. Ignore it for now" >&2; exit 0 ; fi;\
 	 elif test `expr index $@ '/'` -ne 0 ; then\
-	 echo "#CMT> PEDANTIC MODE >> $@ seems to be a missing file, please check" >&2; exit -1 ; \
+	 test -z "$(cmtmsg)" ||\
+	 echo "$(CMTMSGPREFIX)" "(${CONSTITUENT}.make) PEDANTIC: $@: Seems to be a missing file. Please check" >&2; exit 2 ; \
 	 else\
-	 echo "#CMT> PEDANTIC MODE >> $@ seems to be a fake target due to some pattern. Just ignore it" >&2 ; exit 0; fi
+	 test -z "$(cmtmsg)" ||\
+	 echo "$(CMTMSGPREFIX)" "(${CONSTITUENT}.make) PEDANTIC: $@: Seems to be a fake target due to some pattern. Just ignore it" >&2 ; exit 0; fi
 endif
 
Index: /CMT/HEAD/mgr/fragments/constituent
===================================================================
--- /CMT/HEAD/mgr/fragments/constituent	(revision 458)
+++ /CMT/HEAD/mgr/fragments/constituent	(revision 459)
@@ -28,7 +28,7 @@
 	$(echo) "(constituents.make) Rebuilding setup.make $(cmt_local_tagfile_${CONSTITUENT})"
 	@if test -f $(cmt_local_tagfile_${CONSTITUENT}); then /bin/rm -f $(cmt_local_tagfile_${CONSTITUENT}); fi ; \
-	  $(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >>$(cmt_local_tagfile_${CONSTITUENT}); \
+	  $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >>$(cmt_local_tagfile_${CONSTITUENT}); \
 	  if test -f $(cmt_final_setup_${CONSTITUENT}); then /bin/rm -f $(cmt_final_setup_${CONSTITUENT}); fi; \
-	  $(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >>$(cmt_final_setup_${CONSTITUENT})
+	  $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >>$(cmt_final_setup_${CONSTITUENT})
 	$(echo) setup.make ok
 
@@ -54,5 +54,5 @@
 endif
 	$(echo) "(constituents.make) Building ${CONSTITUENT}.make"; \
-	  $(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build constituent_makefile -out=$(cmt_local_${CONSTITUENT}_makefile) ${CONSTITUENT}
+	  $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build constituent_makefile -out=$(cmt_local_${CONSTITUENT}_makefile) ${CONSTITUENT}
 
 ${CONSTITUENT} :: $(${CONSTITUENT}_dependencies) $(cmt_local_${CONSTITUENT}_makefile)
Index: /CMT/HEAD/mgr/fragments/constituent_lock
===================================================================
--- /CMT/HEAD/mgr/fragments/constituent_lock	(revision 458)
+++ /CMT/HEAD/mgr/fragments/constituent_lock	(revision 459)
@@ -28,7 +28,7 @@
 	$(echo) "(constituents.make) Rebuilding setup.make $(cmt_local_tagfile_${CONSTITUENT})"
 	@if test -f $(cmt_local_tagfile_${CONSTITUENT}); then /bin/rm -f $(cmt_local_tagfile_${CONSTITUENT}); fi ; \
-	  $(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >>$(cmt_local_tagfile_${CONSTITUENT}); \
+	  $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >>$(cmt_local_tagfile_${CONSTITUENT}); \
 	  if test -f $(cmt_final_setup_${CONSTITUENT}); then /bin/rm -f $(cmt_final_setup_${CONSTITUENT}); fi; \
-	  $(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >>$(cmt_final_setup_${CONSTITUENT})
+	  $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >>$(cmt_final_setup_${CONSTITUENT})
 	$(echo) setup.make ok
 
@@ -54,5 +54,5 @@
 endif
 	$(echo) "(constituents.make) Building ${CONSTITUENT}.make"; \
-	  $(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build constituent_makefile -out=$(cmt_local_${CONSTITUENT}_makefile) ${CONSTITUENT}
+	  $(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build constituent_makefile -out=$(cmt_local_${CONSTITUENT}_makefile) ${CONSTITUENT}
 
 ${CONSTITUENT} :: $(${CONSTITUENT}_dependencies) $(cmt_local_${CONSTITUENT}_makefile)
Index: /CMT/HEAD/mgr/fragments/constituents_header
===================================================================
--- /CMT/HEAD/mgr/fragments/constituents_header	(revision 458)
+++ /CMT/HEAD/mgr/fragments/constituents_header	(revision 459)
@@ -47,5 +47,5 @@
 endif
 
-##	@bin=`$(cmtexe) -quiet show macro_value bin`
+##	@bin=`$(cmtexe) show macro_value bin`
 
 #$(cmt_local_tagfile) : $(cmt_lock_setup)
@@ -60,5 +60,5 @@
 	  if test -f $(cmt_local_setup); then /bin/rm -f $(cmt_local_setup); fi; \
 	  trap '/bin/rm -f $(cmt_local_setup)' 0 1 2 15; \
-	  $(cmtexe) -quiet -tag=$(tags) show setup >>$(cmt_local_setup); \
+	  $(cmtexe) -tag=$(tags) show setup >>$(cmt_local_setup); \
 	  if test ! -f $@; then \
 	    mv $(cmt_local_setup) $@; \
@@ -78,5 +78,5 @@
 
 env.make ::
-	printenv >env.make.tmp; $(cmtexe) -quiet check files env.make.tmp env.make
+	printenv >env.make.tmp; $(cmtexe) check files env.make.tmp env.make
 
 ifndef QUICK
@@ -101,5 +101,6 @@
 
 .DEFAULT ::
-	@echo "#CMT> Warning: $@: Using default commands" >&2; exit
+	$(echo) "(constituents.make) $@: No rule for such target" >&2
+#	@echo "#CMT> Warning: $@: Using default commands" >&2; exit
 
 #	@if test "$@" = "$(cmt_lock_setup)"; then \
Index: /CMT/HEAD/mgr/fragments/generator_header
===================================================================
--- /CMT/HEAD/mgr/fragments/generator_header	(revision 458)
+++ /CMT/HEAD/mgr/fragments/generator_header	(revision 459)
@@ -12,6 +12,6 @@
 ${dir}${out}_stamp ::
 	@echo ${out}
-	$(cmtexe) -quiet expand model "${model}" > ${dir}${out}_temp
-	$(cmtexe) -quiet check files ${dir}${out}_temp ${dir}${out}
+	$(cmtexe) expand model "${model}" > ${dir}${out}_temp
+	$(cmtexe) check files ${dir}${out}_temp ${dir}${out}
 	@echo ${CONSTITUENT} >${dir}${out}_stamp
 
Index: /CMT/HEAD/mgr/fragments/make_setup
===================================================================
--- /CMT/HEAD/mgr/fragments/make_setup	(revision 458)
+++ /CMT/HEAD/mgr/fragments/make_setup	(revision 459)
@@ -11,5 +11,5 @@
 	@if test "$(nocheck)" = ""; then \
 	  /bin/echo "Rebuilding $@"; \
-	  $(cmtexe) setup -quiet -tag=$(tags) | sed -e 's#`${CMTROOT}/mgr/cmt system`#$(${PACKAGE}_tag)#' >$(${PACKAGE}_tag).csh; \
+	  $(cmtexe) setup -tag=$(tags) | sed -e 's#`${CMTROOT}/mgr/cmt system`#$(${PACKAGE}_tag)#' >$(${PACKAGE}_tag).csh; \
 	fi
 
@@ -20,5 +20,5 @@
 	@if test "$(nocheck)" = ""; then \
 	  /bin/echo "Rebuilding $@"; \
-	  $(cmtexe) setup -quiet -sh -tag=$(tags) | sed -e 's#`${CMTROOT}/mgr/cmt system`#$(${PACKAGE}_tag)#' >$(${PACKAGE}_tag).csh; \
+	  $(cmtexe) setup -sh -tag=$(tags) | sed -e 's#`${CMTROOT}/mgr/cmt system`#$(${PACKAGE}_tag)#' >$(${PACKAGE}_tag).csh; \
 	fi
 
@@ -27,11 +27,11 @@
 
 env.make ::
-	@printenv >env.make.tmp; $(cmtexe) -quiet check files env.make.tmp env.make
+	@printenv >env.make.tmp; $(cmtexe) check files env.make.tmp env.make
 
 $(${PACKAGE}_tag).make : requirements $(use_requirements)
 	@if test ! -d $(bin) ; then $(mkdir) -p $(bin); fi; \
 	  if test -f $(${PACKAGE}_tag).make; then /bin/rm -f $(${PACKAGE}_tag).make; fi; \
-	  $(cmtexe) -quiet -tag=$(tags) build tag_makefile >t$$$$; mv t$$$$ $(${PACKAGE}_tag).make ; \
-	  $(cmtexe) -quiet -tag=$(tags) show uses >t$$$$; mv t$$$$ uses.make ; \
+	  $(cmtexe) -tag=$(tags) build tag_makefile >t$$$$; mv t$$$$ $(${PACKAGE}_tag).make ; \
+	  $(cmtexe) -tag=$(tags) show uses >t$$$$; mv t$$$$ uses.make ; \
 	  $(cmtexe) -tag=$(tags) show tags >t$$$$; mv t$$$$ tags.make
 
Index: /CMT/HEAD/mgr/fragments/make_setup_nmake
===================================================================
--- /CMT/HEAD/mgr/fragments/make_setup_nmake	(revision 458)
+++ /CMT/HEAD/mgr/fragments/make_setup_nmake	(revision 459)
@@ -19,5 +19,5 @@
 $(${PACKAGE}_tag).make : requirements ${use_requirements}
 	@echo "Now rebuilding $@"
-###	@mkdir -p $(bin); touch $(${PACKAGE}_tag).make; ${CMTROOT}/mgr/cmt -quiet build tag_makefile -tag=$(${PACKAGE}_tag) >t$$$$; mv t$$$$ $(${PACKAGE}_tag).make
+###	@mkdir -p $(bin); touch $(${PACKAGE}_tag).make; ${CMTROOT}/mgr/cmt build tag_makefile -tag=$(${PACKAGE}_tag) >t$$$$; mv t$$$$ $(${PACKAGE}_tag).make
 
 -include $(${PACKAGE}_tag).make
Index: /CMT/HEAD/mgr/fragments/nmake/check_application_header
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/check_application_header	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/check_application_header	(revision 459)
@@ -5,5 +5,5 @@
 ${CONSTITUENT}check ::
 	@echo "------> starting ${CONSTITUENT}check"
-	@$(cmtexe) -quiet build -nmake constituent_makefile ${CONSTITUENT}
+	@$(cmtexe) build -nmake constituent_makefile ${CONSTITUENT}
 	$(MAKE) /f ${CONSTITUENT}.nmake build_strategy=keep_makefiles ${CONSTITUENT}check
 
Index: /CMT/HEAD/mgr/fragments/nmake/constituent
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/constituent	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/constituent	(revision 459)
@@ -16,8 +16,8 @@
 !endif
 
-!if [cmt -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >$(cmt_local_tagfile_${CONSTITUENT})] == 0
+!if [cmt -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >$(cmt_local_tagfile_${CONSTITUENT})] == 0
 !endif
 
-!if [$(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >$(cmt_final_setup_${CONSTITUENT})] == 0
+!if [$(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >$(cmt_final_setup_${CONSTITUENT})] == 0
 !endif
 
@@ -34,5 +34,5 @@
 	@set include=$(include)
 	@set lib=$(lib)
-	@$(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_makefile ${CONSTITUENT}
+	@$(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_makefile ${CONSTITUENT}
 	@move ${CONSTITUENT}.nmake $(bin)
 	$(echo) (constituents.nmake) ${CONSTITUENT}.nmake done
Index: /CMT/HEAD/mgr/fragments/nmake/constituent_lock
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/constituent_lock	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/constituent_lock	(revision 459)
@@ -16,8 +16,8 @@
 !endif
 
-!if [cmt -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >$(cmt_local_tagfile_${CONSTITUENT})] == 0
+!if [cmt -tag=$(tags) $(${CONSTITUENT}_extratags) build tag_makefile >$(cmt_local_tagfile_${CONSTITUENT})] == 0
 !endif
 
-!if [$(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >$(cmt_final_setup_${CONSTITUENT})] == 0
+!if [$(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) show setup >$(cmt_final_setup_${CONSTITUENT})] == 0
 !endif
 
@@ -34,5 +34,5 @@
 	@set include=$(include)
 	@set lib=$(lib)
-	@$(cmtexe) -quiet -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_makefile ${CONSTITUENT}
+	@$(cmtexe) -tag=$(tags) $(${CONSTITUENT}_extratags) build -nmake constituent_makefile ${CONSTITUENT}
 	@move ${CONSTITUENT}.nmake $(bin)
 	$(echo) (constituents.nmake) ${CONSTITUENT}.nmake done
Index: /CMT/HEAD/mgr/fragments/nmake/constituents_header
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/constituents_header	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/constituents_header	(revision 459)
@@ -15,5 +15,5 @@
 !endif
 
-!if [cmt -quiet build tag_makefile -tag_add=$(tags) >$(${PACKAGE}_tag).nmake] == 0
+!if [cmt build tag_makefile -tag_add=$(tags) >$(${PACKAGE}_tag).nmake] == 0
 !endif
 
@@ -30,5 +30,5 @@
 
 env.nmake ::
-	@set >env.nmake.tmp; $(cmtexe) -quiet check files env.nmake.tmp env.nmake
+	@set >env.nmake.tmp; $(cmtexe) check files env.nmake.tmp env.nmake
 
 all ::
@@ -44,5 +44,5 @@
 	$(echo) (constituents.nmake) Rebuilding setup.nmake
 	@if not exist $(bin) mkdir $(bin)
-	@$(cmtexe) -quiet -tag=$(tags) show setup   >$(cmt_setup_pid)
+	@$(cmtexe) -tag=$(tags) show setup   >$(cmt_setup_pid)
 	$(echo) setup.nmake ok
 
Index: /CMT/HEAD/mgr/fragments/nmake/generator_header
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/generator_header	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/generator_header	(revision 459)
@@ -9,6 +9,6 @@
 ${dir}${out}_stamp ::
         @echo ${out}
-        $(cmtexe) -quiet expand model "${model}" > ${dir}${out}_temp
-        $(cmtexe) -quiet check files ${dir}${out}_temp ${dir}${out}
+        $(cmtexe) expand model "${model}" > ${dir}${out}_temp
+        $(cmtexe) check files ${dir}${out}_temp ${dir}${out}
         @echo ${CONSTITUENT} >${dir}${out}_stamp
 
Index: /CMT/HEAD/mgr/fragments/nmake/lex
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/lex	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/lex	(revision 459)
@@ -5,5 +5,5 @@
 	$(lex_silent) $(lex) ${FILENAME}
 	sed -e 's/yy/${NAME}YY/g' -e 's/LexYY/YY/g' -e 's/ = {stdin}//' -e 's/ = {stdout}//' lex.yy.c > lex.yy.c.tmp
-	$(cmtexe) -quiet check_files lex.yy.c.tmp ${NAME}.c
+	$(cmtexe) check_files lex.yy.c.tmp ${NAME}.c
 	del lex.yy.c
 	$(lex_silent) $(ccomp) /Fo"$(bin)${CONSTITUENT}\${NAME}${CONSTITUENTSUFFIX}.obj" $(use_pp_cflags) $(${CONSTITUENT}_pp_cflags) $(app_${CONSTITUENT}_pp_cflags) $(${NAME}_pp_cflags) $(use_cflags) $(${CONSTITUENT}_cflags) $(app_${CONSTITUENT}_cflags) $(${NAME}_cflags) $(${NAME}_${FILESUFFIX}_cflags) ${ADDINCLUDE} $(src)${NAME}.c
Index: /CMT/HEAD/mgr/fragments/nmake/lex_library
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/lex_library	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/lex_library	(revision 459)
@@ -5,5 +5,5 @@
 	$(lex_silent) $(lex) ${FILENAME}
 	sed -e 's/yy/${NAME}YY/g' -e 's/LexYY/YY/g' -e 's/ = {stdin}//' -e 's/ = {stdout}//' lex.yy.c > lex.yy.c.tmp
-	$(cmtexe) -quiet check_files lex.yy.c.tmp ${NAME}.c
+	$(cmtexe) check_files lex.yy.c.tmp ${NAME}.c
 	del lex.yy.c
 	$(lex_silent) $(ccomp) /Fo"$(bin)${CONSTITUENT}\${NAME}${CONSTITUENTSUFFIX}.obj" $(use_pp_cflags) $(${CONSTITUENT}_pp_cflags) $(lib_${CONSTITUENT}_pp_cflags) $(${NAME}_pp_cflags) $(use_cflags) $(${CONSTITUENT}_cflags) $(lib_${CONSTITUENT}_cflags) $(${NAME}_cflags) $(${NAME}_${FILESUFFIX}_cflags) ${ADDINCLUDE} $(src)${NAME}.c
Index: /CMT/HEAD/mgr/fragments/nmake/yacc
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/yacc	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/yacc	(revision 459)
@@ -5,7 +5,7 @@
 	$(yacc_silent) $(yacc) ${FILENAME}
 	sed -e 's/yy/${NAME}YY/g' -e 's/ParseYY/YY/g' y.tab.c > y.tab.c.tmp
-	$(cmtexe) -quiet check_files y.tab.c.tmp ${NAME}.c
+	$(cmtexe) check_files y.tab.c.tmp ${NAME}.c
 	sed -e 's/yy/${NAME}YY/g' -e 's/ParseYY/YY/g' y.tab.h > y.tab.h.tmp
-	$(cmtexe) -quiet check_files y.tab.h.tmp ${NAME}.h
+	$(cmtexe) check_files y.tab.h.tmp ${NAME}.h
 	del y.tab.[ch]
 	$(yacc_silent) $(ccomp) /Fo"$(bin)${CONSTITUENT}\${NAME}${CONSTITUENTSUFFIX}.obj" $(use_pp_cflags) $(${CONSTITUENT}_pp_cflags) $(app_${CONSTITUENT}_pp_cflags) $(${NAME}_pp_cflags) $(use_cflags) $(${CONSTITUENT}_cflags) $(app_${CONSTITUENT}_cflags) $(${NAME}_cflags) $(${NAME}_${FILESUFFIX}_cflags) ${ADDINCLUDE} $(src)${NAME}.c
Index: /CMT/HEAD/mgr/fragments/nmake/yacc_library
===================================================================
--- /CMT/HEAD/mgr/fragments/nmake/yacc_library	(revision 458)
+++ /CMT/HEAD/mgr/fragments/nmake/yacc_library	(revision 459)
@@ -5,7 +5,7 @@
 	$(yacc_silent) $(yacc) ${FILENAME}
 	sed -e 's/yy/${NAME}YY/g' -e 's/ParseYY/YY/g' y.tab.c > y.tab.c.tmp
-	$(cmtexe) -quiet check_files y.tab.c.tmp ${NAME}.c
+	$(cmtexe) check_files y.tab.c.tmp ${NAME}.c
 	sed -e 's/yy/${NAME}YY/g' -e 's/ParseYY/YY/g' y.tab.h > y.tab.h.tmp
-	$(cmtexe) -quiet check_files y.tab.h.tmp ${NAME}.h
+	$(cmtexe) check_files y.tab.h.tmp ${NAME}.h
 	del y.tab.[ch]
 	$(yacc_silent) $(ccomp) /Fo"$(bin)${CONSTITUENT}\${NAME}${CONSTITUENTSUFFIX}.obj" $(use_pp_cflags) $(${CONSTITUENT}_pp_cflags) $(lib_${CONSTITUENT}_pp_cflags) $(${NAME}_pp_cflags) $(use_cflags) $(${CONSTITUENT}_cflags) $(lib_${CONSTITUENT}_cflags) $(${NAME}_cflags) $(${NAME}_${FILESUFFIX}_cflags) ${ADDINCLUDE} $(src)${NAME}.c
Index: /CMT/HEAD/mgr/requirements
===================================================================
--- /CMT/HEAD/mgr/requirements	(revision 458)
+++ /CMT/HEAD/mgr/requirements	(revision 459)
@@ -405,6 +405,6 @@
       VisualC                 "copy "
 
-macro build_library_links  "$(cmtexe) build library_links -quiet -tag=$(tags)"
-macro remove_library_links "$(cmtexe) remove library_links -quiet -tag=$(tags)"
+macro build_library_links  "$(cmtexe) build library_links -tag=$(tags)"
+macro remove_library_links "$(cmtexe) remove library_links -tag=$(tags)"
 
 #
@@ -418,5 +418,5 @@
 
 macro build_prototype    "$(cmtexe) build prototype"
-macro build_dependencies "$(cmtexe) -quiet -tag=$(tags) build dependencies"
+macro build_dependencies "$(cmtexe) -tag=$(tags) build dependencies"
 macro build_triggers     "$(cmtexe) build triggers"
 
Index: /CMT/HEAD/source/cmt.h
===================================================================
--- /CMT/HEAD/source/cmt.h	(revision 458)
+++ /CMT/HEAD/source/cmt.h	(revision 459)
@@ -100,4 +100,6 @@
   static void configure_uname_tag ();
   static void configure_version_tag ();
+  //  static void configure_cmt_message ();
+  static void configure_cmt_message (const ArgParser& ap);
 
   static void do_awk (const ArgParser& ap);
@@ -222,4 +224,9 @@
   static bool get_all_sets_done ();
 
+  static void get_cmt_flags (CmtSystem::cmt_string_vector& flags);
+  static cmt_string get_cmt_flags ();
+  static bool set_cmt_flags (const cmt_string& flags);
+  static bool add_cmt_flag (const cmt_string& flag);
+
   /// If a project file exists above the current directory we don't need CMTPATH
   static void guess_current_project ();
Index: /CMT/HEAD/source/cmt_awk.cxx
===================================================================
--- /CMT/HEAD/source/cmt_awk.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_awk.cxx	(revision 459)
@@ -13,4 +13,5 @@
 #include "cmt_awk.h"
 #include "cmt_system.h"
+#include "cmt_log.h"
 
 class Parser
@@ -504,5 +505,6 @@
       if (line.find ("\n") == cmt_string::npos)
         {
-          cerr << "#CMT> Warning: Line too long and truncated in PAwk::run for command " << command << endl;
+	  CmtMessage::warning ("Line too long and truncated in PAwk::run for command " + command);
+	  //          cerr << "#CMT> Warning: Line too long and truncated in PAwk::run for command " << command << endl;
         }
 
Index: /CMT/HEAD/source/cmt_commands.cxx
===================================================================
--- /CMT/HEAD/source/cmt_commands.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_commands.cxx	(revision 459)
@@ -10,4 +10,5 @@
 #include "cmt_symbol.h"
 #include "cmt_project.h"
+#include "cmt_log.h"
 
 ArgParser::ArgParser (CmtContext& context) : cmt(context), argc(0), argv(0), mode(Csh)
@@ -503,5 +504,6 @@
 	  // We have unexpected arguments (not handled by the command handler). This may sign 
 	  // an unprotected handler implementation.
-	  if (!cmt.m_quiet) cerr << "#CMT> warning : unexpected parameter " << reduced_arg << endl;
+	  CmtMessage::warning ("unexpected parameter " + reduced_arg);
+	  //	  if (!cmt.m_quiet) cerr << "#CMT> warning : unexpected parameter " << reduced_arg << endl;
 	}
       else
@@ -568,5 +570,6 @@
 	  else if (argc > 0)
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : wrong arguments" << endl;
+	      CmtMessage::error ("syntax: wrong arguments");
+//	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : wrong arguments" << endl;
 	      cmt.m_action = action_build_constituent_makefile;
 	      help_action = action_help;
@@ -574,5 +577,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : constituent name missing" << endl;
+	      CmtMessage::error ("syntax: constituent name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : constituent name missing" << endl;
 	      cmt.m_action = action_build_constituent_makefile;
 	      help_action = action_help;
@@ -593,5 +597,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing " << endl;
+	      CmtMessage::error ("syntax: arguments missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing " << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_build_dependencies;
@@ -637,5 +642,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing " << endl;
+	      CmtMessage::error ("syntax: arguments missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing " << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_build_os9_makefile;
@@ -651,5 +657,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing" << endl;
+	      CmtMessage::error ("syntax: arguments missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_build_prototype;
@@ -679,5 +686,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing" << endl;
+	      CmtMessage::error ("syntax: arguments missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_build_triggers;
@@ -693,5 +701,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing" << endl;
+	      CmtMessage::error ("syntax: arguments missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : arguments missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_build_windefs;
@@ -700,5 +709,6 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : wrong build argument" << endl;
+	  CmtMessage::error ("syntax: wrong build argument");
+	  //	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : wrong build argument" << endl;
 	  help_action = action_help;
 	  cmt.m_action = action_build;
@@ -707,5 +717,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to build" << endl;
+      CmtMessage::error ("syntax: don't know what to build");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to build" << endl;
       help_action = action_help;
       cmt.m_action = action_build;
@@ -738,6 +749,6 @@
 	      else
 		{
-		  if (!cmt.m_quiet) cerr << "#CMT> syntax error : reference file name missing" 
-					 << endl;
+		  CmtMessage::error ("syntax: reference file name missing");
+		  //		  if (!cmt.m_quiet) cerr << "#CMT> syntax error : reference file name missing" << endl;
 		  help_action = action_help;
 		  cmt.m_action = action_check_files;
@@ -746,5 +757,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : file name missing" << endl;
+	      CmtMessage::error ("syntax: file name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : file name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_check_files;
@@ -760,5 +772,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : package name missing" << endl;
+	      CmtMessage::error ("syntax: package name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : package name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_check_version;
@@ -767,5 +780,6 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad check option" << endl;
+	  CmtMessage::error ("syntax: bad check option");
+	  //	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad check option" << endl;
 	  help_action = action_help;
 	  cmt.m_action = action_check;
@@ -774,5 +788,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to check" << endl;
+      CmtMessage::error ("syntax: don't know what to check");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to check" << endl;
       help_action = action_help;
       cmt.m_action = action_check;
@@ -792,5 +807,5 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : reference file missing" << endl;
+	  CmtMessage::error ("syntax: reference file name missing");
 	  help_action = action_help;
 	  cmt.m_action = action_check_files;
@@ -799,5 +814,5 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : file name missing" << endl;
+      CmtMessage::error ("syntax: file name missing");
       help_action = action_help;
       cmt.m_action = action_check_files;
@@ -814,5 +829,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : checkout arguments missing" << endl;
+      CmtMessage::error ("syntax: checkout arguments missing");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : checkout arguments missing" << endl;
       help_action = action_help;
       cmt.m_action = action_checkout;
@@ -839,5 +855,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : create arguments missing" << endl;
+      CmtMessage::error ("syntax: create arguments missing");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : create arguments missing" << endl;
       help_action = action_help;
       cmt.m_action = action_create;
@@ -854,5 +871,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : create_project arguments missing" << endl;
+      CmtMessage::error ("syntax: create_project arguments missing");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : create_project arguments missing" << endl;
       help_action = action_help;
       cmt.m_action = action_create_project;
@@ -869,5 +887,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : cvsbranches arguments missing" << endl;
+      CmtMessage::error ("syntax: cvsbranches arguments missing");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : cvsbranches arguments missing" << endl;
       help_action = action_help;
       cmt.m_action = action_cvsbranches;
@@ -904,5 +923,5 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : package name missing" << endl;
+      CmtMessage::error ("syntax: package name missing");
       help_action = action_help;
       cmt.m_action = action_cvstags;
@@ -929,5 +948,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : action not specified" << endl;
+      CmtMessage::error ("syntax: action not specified");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : action not specified" << endl;
       help_action = action_help;
       cmt.m_action = action_do;
@@ -951,5 +971,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : model not specified" << endl;
+	      CmtMessage::error ("syntax: model not specified");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : model not specified" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_expand_model;
@@ -958,5 +979,6 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad expand option" << endl;
+	  CmtMessage::error ("syntax: bad expand option");
+	  //	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad expand option" << endl;
 	  help_action = action_help;
 	  cmt.m_action = action_expand_model;
@@ -965,5 +987,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to expand" << endl;
+      CmtMessage::error ("syntax: don't know what to expand");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to expand" << endl;
       help_action = action_help;
       cmt.m_action = action_expand_model;
@@ -980,5 +1003,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : file to filter not specified" << endl;
+      CmtMessage::error ("syntax: file to filter not specified");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : file to filter not specified" << endl;
       help_action = action_help;
       cmt.m_action = action_filter;
@@ -1017,5 +1041,6 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : version missing" << endl;
+	  CmtMessage::error ("syntax: version missing");
+	  //	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : version missing" << endl;
 	  help_action = action_help;
 	  cmt.m_action = action_lock;
@@ -1065,5 +1090,5 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : version missing" << endl;
+	      CmtMessage::error ("syntax: version missing");
 	      help_action = action_help;
 	      cmt.m_action = action_remove;
@@ -1073,5 +1098,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to remove" << endl;
+      CmtMessage::error ("syntax: don't know what to remove");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to remove" << endl;
       help_action = action_help;
       cmt.m_action = action_remove;
@@ -1088,5 +1114,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : run arguments missing" << endl;
+      CmtMessage::error ("syntax: run arguments missing");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : run arguments missing" << endl;
       help_action = action_help;
       cmt.m_action = action_run;
@@ -1103,5 +1130,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : run_sequence arguments missing" << endl;
+      CmtMessage::error ("syntax: run_sequence arguments missing");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : run_sequence arguments missing" << endl;
       help_action = action_help;
       cmt.m_action = action_run_sequence;
@@ -1135,5 +1163,6 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad set argument" << endl;
+	  CmtMessage::error ("syntax: bad set argument");
+	  //	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad set argument" << endl;
 	  help_action = action_help;
 	  //cmt.m_action = action_set;
@@ -1142,5 +1171,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to set" << endl;
+      CmtMessage::error ("syntax: don't know what to set");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to set" << endl;
       help_action = action_help;
       //cmt.m_action = action_set;
@@ -1173,5 +1203,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : action name missing" << endl;
+	      CmtMessage::error ("syntax: action name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : action name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_show_action;
@@ -1197,5 +1228,5 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : action name missing" << endl;
+	      CmtMessage::error ("syntax: action name missing");
 	      help_action = action_help;
 	      cmt.m_action = action_show_action_value;
@@ -1246,5 +1277,5 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : package name missing" << endl;
+	      CmtMessage::error ("syntax: package name missing");
 	      help_action = action_help;
 	      cmt.m_action = action_show_clients;
@@ -1264,5 +1295,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : constituent name missing" << endl;
+	      CmtMessage::error ("syntax: constituent name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : constituent name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_show_constituent;
@@ -1290,5 +1322,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : fragment name missing" << endl;
+	      CmtMessage::error ("syntax: fragment name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : fragment name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_show_fragment;
@@ -1316,5 +1349,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : language name missing" << endl;
+	      CmtMessage::error ("syntax: language name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : language name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_show_language;
@@ -1334,5 +1368,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : macro name missing" << endl;
+	      CmtMessage::error ("syntax: macro name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : macro name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_show_macro;
@@ -1358,5 +1393,5 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : macro name missing" << endl;
+	      CmtMessage::error ("syntax: macro name missing");
 	      help_action = action_help;
 	      cmt.m_action = action_show_macro_value;
@@ -1398,5 +1433,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : pattern name missing" << endl;
+	      CmtMessage::error ("syntax: pattern name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : pattern name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_show_pattern;
@@ -1452,5 +1488,6 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : set name missing" << endl;
+	      CmtMessage::error ("syntax: set name missing");
+	      //	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : set name missing" << endl;
 	      help_action = action_help;
 	      cmt.m_action = action_show_set_value;
@@ -1466,5 +1503,5 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : set name missing" << endl;
+	      CmtMessage::error ("syntax: set name missing");
 	      help_action = action_help;
 	      cmt.m_action = action_show_set;
@@ -1515,5 +1552,5 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : package name missing" << endl;
+	      CmtMessage::error ("syntax: package name missing");
 	      help_action = action_help;
 	      cmt.m_action = action_show_use_paths;
@@ -1545,5 +1582,5 @@
 	  else
 	    {
-	      if (!cmt.m_quiet) cerr << "#CMT> syntax error : package name missing" << endl;
+	      CmtMessage::error ("syntax: package name missing");
 	      help_action = action_help;
 	      cmt.m_action = action_show_versions;
@@ -1552,5 +1589,6 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad show argument" << endl;
+	  CmtMessage::error ("syntax: bad show argument");
+	  //	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : bad show argument" << endl;
 	  help_action = action_help;
 	  cmt.m_action = action_show;
@@ -1559,5 +1597,6 @@
   else
     {
-      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to show" << endl;
+      CmtMessage::error ("syntax: don't know what to show");
+      //      if (!cmt.m_quiet) cerr << "#CMT> syntax error : don't know what to show" << endl;
       help_action = action_help;
       cmt.m_action = action_show;
@@ -1596,5 +1635,5 @@
       else
 	{
-	  if (!cmt.m_quiet) cerr << "#CMT> syntax error : version missing" << endl;
+	  CmtMessage::error ("syntax: version missing");
 	  help_action = action_help;
 	  cmt.m_action = action_unlock;
@@ -1626,4 +1665,6 @@
 {
   cmt.m_disable_warnings = true;
+  if (CmtMessage::level () <= Warning)
+    CmtMessage::set_level (Error);
 }
 
@@ -1631,4 +1672,6 @@
 {
   cmt.m_quiet = true;
+  if (CmtMessage::level () <= Error)
+    CmtMessage::set_level (Fatal);
 }
 
@@ -1637,4 +1680,6 @@
 {
   cmt.m_warnings = true;
+  if (CmtMessage::level () != Warning)
+    CmtMessage::set_level (Warning);
 }
 
@@ -1747,5 +1792,6 @@
 void ArgParser::option_e ()
 {
-  cerr << "#CMT> Warning: extra statement = " << arg << endl;
+  CmtMessage::warning ("extra statement = " + arg);
+  //  cerr << "#CMT> Warning: extra statement = " << arg << endl;
   extra_line = arg;
 }
Index: /CMT/HEAD/source/cmt_constituent.cxx
===================================================================
--- /CMT/HEAD/source/cmt_constituent.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_constituent.cxx	(revision 459)
@@ -15,4 +15,5 @@
 #include "cmt_system.h"
 #include "cmt_database.h"
+#include "cmt_log.h"
 
 /*----------------------------------------------------------*/
@@ -248,6 +249,8 @@
 	//if (!Cmt::get_quiet ())
 	//{
-	cerr << "#CMT> Warning: bad option " 
-	     << w << " in constituent " << m_constituent.name << endl;
+	CmtMessage::warning ("bad option " + w + " in constituent " +
+			     m_constituent.name);
+	//	cerr << "#CMT> Warning: bad option " 
+	//	     << w << " in constituent " << m_constituent.name << endl;
 	//CmtError::set (CmtError::execution_error, cmd);
 	//}
Index: /CMT/HEAD/source/cmt_cvs.cxx
===================================================================
--- /CMT/HEAD/source/cmt_cvs.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_cvs.cxx	(revision 459)
@@ -14,4 +14,5 @@
 #include "cmt_symbol.h"
 #include "cmt_project.h"
+#include "cmt_log.h"
 
 /**
@@ -272,5 +273,6 @@
     if (m_verbose || m_simulation)
       {
-	cerr << "#CMT> Executing [" << command << "]" << endl;
+	CmtMessage::info ("Executing [" + command + "]");
+	//	cerr << "#CMT> Executing [" << command << "]" << endl;
       }
     
@@ -296,6 +298,10 @@
 	    retry++;
 	    
-	    cerr << "# " << message << ": status=" << status << endl;
-	    cerr << "#---------------------------------------------------------" << endl;
+	    char stat[8];
+	    sprintf (stat, "%d", status);
+	    CmtMessage::error ("# " + message + ": status=" + stat);
+	    CmtMessage::error ("#---------------------------------------------------------");
+	    //	    cerr << "# " << message << ": status=" << status << endl;
+	    //	    cerr << "#---------------------------------------------------------" << endl;
 	    
 	    if (retry > 5) exit(0);
@@ -314,5 +320,6 @@
     if (m_verbose || m_simulation)
       {
-	cerr << "#CMT> Executing [" << command << "]" << endl;
+	CmtMessage::info ("Executing [" + command + "]");
+	//	cerr << "#CMT> Executing [" << command << "]" << endl;
       }
     
@@ -404,9 +411,11 @@
 	if (found)
 	  {
-	    cerr << "#CMT> Protocol level " << m_protocol_level << endl;
+	    CmtMessage::info ("Protocol level " + m_protocol_level);
+	    //	    cerr << "#CMT> Protocol level " << m_protocol_level << endl;
 	  }
 	else
 	  {
-	    cerr << "#CMT> The CVS pluggin is not installed or is not at protocol level " << m_protocol_level << endl;
+	    CmtMessage::error ("The CVS pluggin is not installed or is not at protocol level " + m_protocol_level);
+	    //	    cerr << "#CMT> The CVS pluggin is not installed or is not at protocol level " << m_protocol_level << endl;
 	  }
       }
@@ -457,5 +466,6 @@
 	if (!CmtSystem::mkdir (tmp_dir))
 	  {
-	    cerr << "#CMT> Cannot create the temporary directory [" << tmp_dir << "]" << endl;
+	    CmtMessage::error ("Cannot create the temporary directory [" + tmp_dir + "]");
+	    //	    cerr << "#CMT> Cannot create the temporary directory [" << tmp_dir << "]" << endl;
 	    return;
 	  }
@@ -466,9 +476,11 @@
     if (!CmtSystem::cd (tmp_dir))
       {
-	cerr << "#CMT> Cannot move to the temporary directory " << tmp_dir << endl;
+	CmtMessage::error ("Cannot move to the temporary directory " + tmp_dir);
+	//	cerr << "#CMT> Cannot move to the temporary directory " << tmp_dir << endl;
 	
 	if (m_verbose)
 	  {
-	    cerr << "#CMT> now removing tmp_dir " << tmp_dir << " home=" << home_dir << endl;
+	    CmtMessage::info ("now removing tmp_dir " + tmp_dir + " home=" + home_dir);
+	    //	    cerr << "#CMT> now removing tmp_dir " << tmp_dir << " home=" << home_dir << endl;
 	  }
 	
@@ -480,5 +492,6 @@
     if (m_verbose)
       {
-	cerr << "#CMT> cvs infos are now obtained from the temporary directory " << CmtSystem::pwd () << endl;  
+	CmtMessage::info ("cvs infos are now obtained from the temporary directory " + CmtSystem::pwd ());  
+	//	cerr << "#CMT> cvs infos are now obtained from the temporary directory " << CmtSystem::pwd () << endl;  
       }
     
@@ -536,5 +549,6 @@
     if (m_verbose)
       {
-	cerr << "#CMT> now removing tmp_dir " << tmp_dir << " home=" << home_dir << endl;
+	CmtMessage::info ("now removing tmp_dir " + tmp_dir + " home=" + home_dir);
+	//	cerr << "#CMT> now removing tmp_dir " << tmp_dir << " home=" << home_dir << endl;
       }
     
@@ -570,5 +584,6 @@
     if (!check_protocol ())
       {
-	cerr << "#CMT> The CVS pluggin is not installed or is not at protocol level " << m_protocol_level << endl;
+	CmtMessage::error ("The CVS pluggin is not installed or is not at protocol level " + m_protocol_level);
+	//	cerr << "#CMT> The CVS pluggin is not installed or is not at protocol level " << m_protocol_level << endl;
 	return;
       }
@@ -576,5 +591,6 @@
     if (module == "")
       {
-	cerr << "#CMT> cmt cvs needs a module name" << endl;
+	CmtMessage::error ("cmt cvs needs a module name");
+	//	cerr << "#CMT> cmt cvs needs a module name" << endl;
 	return;
       }
@@ -584,5 +600,6 @@
 	if (m_verbose)
 	  {
-	    cerr << "#CMT> cvs infos for module " << module << " already there" << endl;
+	    CmtMessage::info ("cvs infos for module " + module + " already there");
+	    //	    cerr << "#CMT> cvs infos for module " << module << " already there" << endl;
 	  }
       }
@@ -836,5 +853,6 @@
     if (m_verbose)
       {
-	cerr << "#CMT> requesting cvs infos onto module " << module << endl;
+	CmtMessage::info ("requesting cvs infos onto module " + module);
+	//	cerr << "#CMT> requesting cvs infos onto module " << module << endl;
       }
     
@@ -844,5 +862,6 @@
       {
 	versions = "";
-	cerr << "#CMT> Product " << product << " not found in ${CVSROOT}" << endl;
+	CmtMessage::error ("Product " + product + " not found in ${CVSROOT}");
+	//	cerr << "#CMT> Product " << product << " not found in ${CVSROOT}" << endl;
 	return (false);
       }
@@ -1000,5 +1019,6 @@
     if (m_simulation)
       {
-	cerr << "#CMT> Would create the " << dir << " directory" << endl;
+	CmtMessage::info ("Would create the " + dir + " directory");
+	//	cerr << "#CMT> Would create the " << dir << " directory" << endl;
       }
     else
@@ -1008,5 +1028,6 @@
 	    if (m_verbose)
 	      {
-		cerr << "#CMT> About to mkdir " << dir << endl;
+		CmtMessage::info ("About to mkdir " + dir);
+		//		cerr << "#CMT> About to mkdir " << dir << endl;
 	      }
 
@@ -1014,6 +1035,8 @@
 	    if (!CmtSystem::cd (dir))
 	      {
-		cerr << "# Error creating the directory :" << dir << endl;
-		cerr << "#---------------------------------------------------------" << endl;
+		CmtMessage::error ("# Cannot cd into the directory: " + dir);
+		CmtMessage::error ("#---------------------------------------------------------");
+		//		cerr << "# Error creating the directory :" << dir << endl;
+		//		cerr << "#---------------------------------------------------------" << endl;
 		return (false);
 	      }
@@ -1045,5 +1068,6 @@
     if (m_verbose)
       {
-	cerr << "#CMT> CMTPATH=" << CmtSystem::getenv ("CMTPATH") << endl;
+	CmtMessage::info ("CMTPATH=" + CmtSystem::getenv ("CMTPATH"));
+	//	cerr << "#CMT> CMTPATH=" << CmtSystem::getenv ("CMTPATH") << endl;
       }
   }
@@ -1063,5 +1087,6 @@
     cmt_string dir = currentdir;
 
-    cerr << "  # get project files into " << dir << endl;
+    CmtMessage::info ("get project files into " + dir);
+    //    cerr << "  # get project files into " << dir << endl;
 
 
@@ -1127,6 +1152,7 @@
 	if (m_simulation)
 	  {
-	    cerr << "#CMT> Would fill in the CVS/Root file with " << endl;
-	    cerr << s << endl;
+	    CmtMessage::info ("Would fill in the CVS/Root file with\n" + s);
+	    //	    cerr << "#CMT> Would fill in the CVS/Root file with " << endl;
+	    //	    cerr << s << endl;
 	  }
 	else
@@ -1134,6 +1160,7 @@
 	    if (m_verbose)
 	      {
-		cerr << "#CMT> Fill in the CVS/Root file with " << endl;
-		cerr << s << endl;
+		CmtMessage::info ("Fill in the CVS/Root file with\n" + s);
+		//		cerr << "#CMT> Fill in the CVS/Root file with " << endl;
+		//		cerr << s << endl;
 	      }
 	    s.write (f);
@@ -1160,6 +1187,7 @@
 	if (m_simulation)
 	  {
-	    cerr << "#CMT> Would fill in the CVS/Repository file with " << endl;
-	    cerr << s << endl;
+	    CmtMessage::info ("Would fill in the CVS/Repository file with\n" + s);
+	    //	    cerr << "#CMT> Would fill in the CVS/Repository file with " << endl;
+	    //	    cerr << s << endl;
 	  }
 	else
@@ -1167,6 +1195,7 @@
 	    if (m_verbose)
 	      {
-		cerr << "#CMT> Fill in the CVS/Repository file with " << endl;
-		cerr << s << endl;
+		CmtMessage::info ("Fill in the CVS/Repository file with\n" + s);
+		//		cerr << "#CMT> Fill in the CVS/Repository file with " << endl;
+		//		cerr << s << endl;
 	      }
 	    s.write (f);
@@ -1176,6 +1205,7 @@
     if (m_simulation)
       {
-	cerr << "#CMT> Would write the top CVS/Entries file with " << endl;
-	cerr << entries_text << endl;
+	CmtMessage::info ("Would write the top CVS/Entries file with\n" + entries_text);
+	//	cerr << "#CMT> Would write the top CVS/Entries file with " << endl;
+	//	cerr << entries_text << endl;
       }
     else
@@ -1199,6 +1229,7 @@
 	if (m_verbose)
 	  {
-	    cerr << "#CMT> Fill in the top CVS/Entries file with " << endl;
-	    cerr << text << endl;
+	    CmtMessage::info ("Fill in the top CVS/Entries file with\n" + text);
+	    //	    cerr << "#CMT> Fill in the top CVS/Entries file with " << endl;
+	    //	    cerr << text << endl;
 	  }
 
@@ -1226,5 +1257,6 @@
     cmt_string dir = currentdir;
 
-    cerr << "  # get top files " << endl;
+    CmtMessage::info ("get top files ");
+    //    cerr << "  # get top files " << endl;
             
     cmt_string command = "cvs -f -Q co -l ";
@@ -1273,5 +1305,7 @@
     if (m_verbose)
       {
-	cerr << "#CMT> Now getting subdirectories pwd=" << CmtSystem::pwd () << " dir=" << dir << endl;
+	CmtMessage::info ("Now getting subdirectories pwd=" + CmtSystem::pwd ()
+			  + " dir=" + dir);
+	//	cerr << "#CMT> Now getting subdirectories pwd=" << CmtSystem::pwd () << " dir=" << dir << endl;
       }
     
@@ -1328,5 +1362,6 @@
 	  {  
     
-            cerr << "# --> udapte the file timestamps" << endl;                 
+            CmtMessage::info ("udapte the file timestamps");                 
+	    //            cerr << "# --> udapte the file timestamps" << endl;                 
             for (i = 0; i < branch_vector.size (); i++)
 	      {	
@@ -1371,5 +1406,6 @@
       {  
     
-        cerr << "# --> udapte the file timestamps" << endl;                 
+	CmtMessage::info ("udapte the file timestamps");                 
+	//        cerr << "# --> udapte the file timestamps" << endl;                 
         for (i = 0; i < branch_vector.size (); i++)
 	  {	
@@ -1562,6 +1598,7 @@
 
 	add_cmtpath (here);
-
-	cerr << "  # --> now getting project packages from the " << container << " " << here << endl;
+	
+	CmtMessage::info ("now getting project packages from the " + container + " " + here);
+	//	cerr << "  # --> now getting project packages from the " << container << " " << here << endl;
 
 	CmtSystem::cd (here);
@@ -1687,4 +1724,10 @@
     if (m_verbose)
       {
+	CmtMessage::info ("do_checkout_phase2> offset=" + offset
+			  + " " + structure_info + "=" + product
+			  + " specified_version=" + specified_version
+			  + " tag=" + tag
+			  + " pwd=" + CmtSystem::pwd ());
+	/*
 	cerr << "#CMT> do_checkout_phase2> offset=" << offset
 	     << " " << structure_info << "=" << product
@@ -1693,4 +1736,5 @@
 	     << " pwd=" << CmtSystem::pwd ()
 	     << endl;
+	*/
       }
     
@@ -1712,5 +1756,6 @@
     if (version == "")
       {
-	cerr << "# ================= No version specified for " << structure_info << " " << product << endl;
+	CmtMessage::warning ("================= No version specified for " + structure_info + " " + product);
+	//	cerr << "# ================= No version specified for " << structure_info << " " << product << endl;
 	return;
       }
@@ -1763,7 +1808,12 @@
 	if (cvs_tag.find ("*") != cmt_string::npos)
 	  {
+	    CmtMessage::warning ("================= " + structure_info + " " + product 
+				 + " version " + cvs_tag + echo_ppath 
+				 + " has wild cards and will not be considered.");
+	    /*
 	    cerr << "# ================= " << structure_info << " " << product 
 		 << " version " << cvs_tag << echo_ppath 
 		 << " has wild cards and will not be considered." << endl;
+	    */
 	    return;
 	  }
@@ -1802,7 +1852,12 @@
     if (check_structure (dir, version))
       {
+	CmtMessage::info ("================= " + structure_info + " " + product 
+			  + " version " + version + echo_ppath 
+			  + " already installed.");	
+	/*
 	cerr << "# ================= " << structure_info << " " << product 
 	     << " version "            << version        << echo_ppath 
 	     << " already installed."  << endl;	
+	*/
 	recursive = false;
       }
@@ -1815,5 +1870,6 @@
 	if (!really_checkout (offset, product, version, cvs_tag, module, dir, at_head))
 	  {
-	    cerr << "# bad return from really_checkout_product" << endl;
+	    CmtMessage::error ("bad return from really_checkout_product");
+	    //	    cerr << "# bad return from really_checkout_product" << endl;
 	    return;
 	  }
@@ -1826,5 +1882,6 @@
     if (m_simulation)
       {
-	cerr << "#CMT> " << structure_info << " directory not really created " << dir << endl;
+	CmtMessage::info (structure_info + " directory not really created " + dir);
+	//	cerr << "#CMT> " << structure_info << " directory not really created " << dir << endl;
       }
     else if (structure_info == "package")
@@ -1832,5 +1889,6 @@
 	if (!CmtSystem::cd (dir))
 	  {
-	    cerr << "#CMT> Package directory not created " << dir << endl;
+	    CmtMessage::error ("Package directory not created " + dir);
+	    //	    cerr << "#CMT> Package directory not created " << dir << endl;
 	    return;
 	  }
@@ -1871,5 +1929,6 @@
 	    else
 	      {
-		cerr << "# " << product << " not a CMT package" << endl;
+		CmtMessage::error (product + " not a CMT package");
+		//		cerr << "# " << product << " not a CMT package" << endl;
 		return;
 	      }
@@ -1921,10 +1980,12 @@
 	if (m_verbose)
 	  {
-	    cerr << "#CMT> dir=" << dir << endl;
+	    CmtMessage::info ("dir=" + dir);
+	    //	    cerr << "#CMT> dir=" << dir << endl;
 	  }
 	
 	if (!CmtSystem::cd (dir))
 	  {
-	    cerr << "#CMT> Project directory not created " << dir << endl;
+	    CmtMessage::error ("Project directory not created " + dir);
+	    //	    cerr << "#CMT> Project directory not created " << dir << endl;
 	    return;
 	  }
@@ -1938,5 +1999,6 @@
 	if (!CmtSystem::test_file (file_name))
 	  {
-	    cerr << "# " << product << " not a CMT project" << endl;
+	    CmtMessage::error (product + " not a CMT project");
+	    //	    cerr << "# " << product << " not a CMT project" << endl;
 	    return;
 	  }
@@ -1947,5 +2009,6 @@
 	  }
 
-	cerr << "# ================= Project " << product << " completed" << endl;
+	CmtMessage::info ("================= Project " + product + " completed");
+	//	cerr << "# ================= Project " << product << " completed" << endl;
 
       }
@@ -1968,6 +2031,8 @@
     if (m_verbose)
       {
-	cerr << "#CMT> checkout phase1 module=" << module
-	     << " version_dir=" << version_dir << " version_tag=" << version_tag << endl;
+	CmtMessage::info ("checkout phase1 module=" + module
+			  + " version_dir=" + version_dir + " version_tag=" + version_tag);
+	//	cerr << "#CMT> checkout phase1 module=" << module
+	//	     << " version_dir=" << version_dir << " version_tag=" << version_tag << endl;
       }
 
@@ -1982,5 +2047,6 @@
 	if (m_verbose)
 	  {
-	    cerr << "#CMT> Missing module name" << endl;
+	    CmtMessage::info ("Missing module name");
+	    //	    cerr << "#CMT> Missing module name" << endl;
 	  }
 	return;
@@ -2001,5 +2067,6 @@
       if (error_info != "")
 	{
-	  cerr << error_info << endl;
+	  CmtMessage::error (error_info);
+	  //	  cerr << error_info << endl;
 	  return;
 	}
@@ -2023,5 +2090,6 @@
 	if (m_verbose)
 	  {
-	    cerr << "#CMT> cumulated versions " << versions << endl;
+	    CmtMessage::info ("cumulated versions " + versions);
+	    //	    cerr << "#CMT> cumulated versions " << versions << endl;
 	  }
 
@@ -2080,6 +2148,8 @@
     if (m_verbose)
       {
-	cerr << "#CMT> about to checkout " << structure_info
-	     << " " << product << " version " << version << " into " << top_dir << endl;
+	CmtMessage::info ("about to checkout " + structure_info
+			  + " " + product + " version " + version + " into " + top_dir);
+	//	cerr << "#CMT> about to checkout " << structure_info
+	//	     << " " << product << " version " << version << " into " << top_dir << endl;
       }
 
@@ -2101,5 +2171,6 @@
 	if (!CmtSystem::test_file (file_name))
 	  {
-	    cerr << "# " << product << " was not properly checked out and is missing its cmt/project.cmt file" << endl;
+	    CmtMessage::error (product + " was not properly checked out and is missing its cmt/project.cmt file");
+	    //	    cerr << "# " << product << " was not properly checked out and is missing its cmt/project.cmt file" << endl;
 	    return;
 	  }
@@ -2133,5 +2204,6 @@
 	    else
 	      {
-		cerr << "# " << product << " was not properly checked out and is missing its cmt/requirements file" << endl;
+		CmtMessage::error (product + " was not properly checked out and is missing its cmt/requirements file");
+		//		cerr << "# " << product << " was not properly checked out and is missing its cmt/requirements file" << endl;
 		return;
 	      }
@@ -2140,5 +2212,6 @@
 	if (m_verbose)
 	  {
-	    cerr << "#CMT> product " << product << " has been checked out" << endl;
+	    CmtMessage::info ("product " + product + " has been checked out");
+	    //	    cerr << "#CMT> product " << product << " has been checked out" << endl;
 	  }
 	
@@ -2198,5 +2271,6 @@
     if (CmtSystem::getenv ("CVSROOT") == "")
       {
-	cerr << "# Please set CVSROOT first !" << endl;
+	CmtMessage::error ("Please set CVSROOT first !");
+	//	cerr << "# Please set CVSROOT first !" << endl;
 	return;
       }
@@ -2225,5 +2299,6 @@
 	    if (error_info != "")
 	      {
-		cerr << error_info << endl;
+		CmtMessage::error (error_info);
+		//		cerr << error_info << endl;
 	      }
 	    else
@@ -2250,5 +2325,6 @@
 		  {
 		    const cmt_string& s = v[i];
-		    cerr << s << endl;
+		    cout << s << endl;
+		    //		    cerr << s << endl;
 		  }
 	      }
@@ -2269,9 +2345,11 @@
     if (error_info != "")
       {
-	cerr << error_info << endl;
+	CmtMessage::error (error_info);
+	//	cerr << error_info << endl;
       }
     else
       {
-	cerr << branches_info << endl;
+	cout << branches_info << endl;
+	//	cerr << branches_info << endl;
       }
   }
@@ -2289,9 +2367,11 @@
     if (error_info != "")
       {
-	cerr << error_info << endl;
+	CmtMessage::error (error_info);
+	//	cerr << error_info << endl;
       }
     else
       {
-	cerr << subpackages_info << endl;
+	cout << subpackages_info << endl;
+	//	cerr << subpackages_info << endl;
       }
   }
@@ -2309,9 +2389,11 @@
     if (error_info != "")
       {
-	cerr << error_info << endl;
+	CmtMessage::error (error_info);
+	//	cerr << error_info << endl;
       }
     else
       {
-	cerr << subprojects_info << endl;
+	cout << subprojects_info << endl;
+	//	cerr << subprojects_info << endl;
       }
   }
@@ -2332,5 +2414,6 @@
     if (CmtSystem::getenv ("CVSROOT") == "")
       {
-	cerr << "# Please set CVSROOT first !" << endl;
+	CmtMessage::error ("Please set CVSROOT first !");
+	//	cerr << "# Please set CVSROOT first !" << endl;
 	return;
       }
Index: /CMT/HEAD/source/cmt_error.cxx
===================================================================
--- /CMT/HEAD/source/cmt_error.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_error.cxx	(revision 459)
@@ -8,11 +8,12 @@
 #include "cmt_error.h"
 #include "cmt_vector.h"
+#include "cmt_log.h"
 
-class Error
+class TheError
 {
 public:
-  static Error& instance ();
+  static TheError& instance ();
 
-  Error ()
+  TheError ()
   {
     error_names.add() = "ok";
@@ -40,5 +41,5 @@
   }
 
-  ~Error ()
+  ~TheError ()
   {
   }
@@ -88,7 +89,7 @@
 
 //---------------------------------------------------------------
-Error& Error::instance ()
+TheError& TheError::instance ()
 {
-  static Error e;
+  static TheError e;
   
   return (e);
@@ -98,5 +99,5 @@
 void CmtError::clear ()
 {
-  Error& e = Error::instance ();
+  TheError& e = TheError::instance ();
 
   e.clear ();
@@ -106,5 +107,5 @@
 bool CmtError::has_pending_error ()
 {
-  Error& e = Error::instance ();
+  TheError& e = TheError::instance ();
 
   if (e.get_code () == ok) return (false);
@@ -115,5 +116,5 @@
 CmtError::code CmtError::get_last_error_code ()
 {
-  Error& e = Error::instance ();
+  TheError& e = TheError::instance ();
 
   return (e.get_code ());
@@ -123,5 +124,5 @@
 int CmtError::get_last_execution_error ()
 {
-  Error& e = Error::instance ();
+  TheError& e = TheError::instance ();
 
   return (e.get_last_execution_error ());
@@ -131,5 +132,5 @@
 const cmt_string& CmtError::get_error_name (code error)
 {
-  Error& e = Error::instance ();
+  TheError& e = TheError::instance ();
 
   return (e.get_name (error));
@@ -139,5 +140,5 @@
 void CmtError::set (code error, const cmt_string& text, const int execution_error)
 {
-  Error& e = Error::instance ();
+  TheError& e = TheError::instance ();
 
   e.set (error, text, execution_error);
@@ -147,5 +148,5 @@
 cmt_string CmtError::get_last_error ()
 {
-  Error& e = Error::instance ();
+  TheError& e = TheError::instance ();
 
   cmt_string result;
@@ -161,7 +162,10 @@
 void CmtError::print ()
 {
-  Error& e = Error::instance ();
+  /*
+  TheError& e = TheError::instance ();
 
   cerr << "CMT> Error: " << get_error_name (e.get_code ()) << " : " << e.get_text () << endl;
+  */
+  CmtMessage::error (get_last_error ());
 }
 
Index: /CMT/HEAD/source/cmt_fragment.cxx
===================================================================
--- /CMT/HEAD/source/cmt_fragment.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_fragment.cxx	(revision 459)
@@ -15,4 +15,5 @@
 #include "cmt_system.h"
 #include "cmt_database.h"
+#include "cmt_log.h"
 
 /*----------------------------------------------------------*/
@@ -137,5 +138,6 @@
   if (fragment == 0)
     {
-      cerr << "Fragment " << name << " not found" << endl;
+      CmtMessage::info ("Fragment " + name + " not found");
+      //      cerr << "Fragment " << name << " not found" << endl;
     }
   else
@@ -1110,5 +1112,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1130,5 +1133,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1150,5 +1154,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1170,5 +1175,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1193,5 +1199,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1213,5 +1220,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1233,5 +1241,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1255,5 +1264,6 @@
   if (!result)
     {
-      cerr << "#CMT> Fragment " << _name << " not found" << endl;
+      CmtMessage::info ("Fragment " + _name + " not found");
+      //      cerr << "#CMT> Fragment " << _name << " not found" << endl;
       _fragment = 0;
     }
@@ -1272,5 +1282,6 @@
       if (_fragment == 0)
         {
-          cerr << "#CMT> Fragment " << _name << " not found" << endl;
+	  CmtMessage::info ("Fragment " + _name + " not found");
+	  //          cerr << "#CMT> Fragment " << _name << " not found" << endl;
         }
     }
Index: /CMT/HEAD/source/cmt_generator.cxx
===================================================================
--- /CMT/HEAD/source/cmt_generator.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_generator.cxx	(revision 459)
@@ -17,4 +17,5 @@
 
 #include "cmt_generators.h"
+#include "cmt_log.h"
 
 //------------------------------------------------------------------------
@@ -736,5 +737,6 @@
   else
     {
-      cerr << "#CMT> build constituent_makefile : wrong arguments" << endl;
+      CmtMessage::error ("build constituent_makefile : wrong arguments");
+      //      cerr << "#CMT> build constituent_makefile : wrong arguments" << endl;
       return;
     }
Index: /CMT/HEAD/source/cmt_generators.cxx
===================================================================
--- /CMT/HEAD/source/cmt_generators.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_generators.cxx	(revision 459)
@@ -107,5 +107,6 @@
     {
       file_not_found = true;
-      cerr << "#CMT> Warning: Source file " << file << " not found" << endl;
+      CmtMessage::warning ("Source file " + file + " not found");
+      //      cerr << "#CMT> Warning: Source file " << file << " not found" << endl;
     }
 
@@ -185,5 +186,6 @@
 	  can_build = false;
           obj  = "";
-	  cerr << "#CMT> Warning: Source file " << name << " cannot be rebuilt" << endl;
+	  CmtMessage::warning ("Source file " + name + " cannot be rebuilt");
+	  //	  cerr << "#CMT> Warning: Source file " << name << " cannot be rebuilt" << endl;
         }
       else
@@ -236,5 +238,6 @@
   else
     {
-      cerr << "#CMT> Warning: file " << m_FULLNAME << " not found" << endl;
+      CmtMessage::warning ("file " + m_FULLNAME + " not found");
+      //      cerr << "#CMT> Warning: file " << m_FULLNAME << " not found" << endl;
     }
 }
@@ -430,5 +433,6 @@
   need_prototypes = constituent.need_prototypes;
 
-  cout << m_TITLE << " " << m_CONSTITUENT << endl;
+  //  cout << m_TITLE << " " << m_CONSTITUENT << endl;
+  CmtMessage::info (m_TITLE + " " + m_CONSTITUENT);
 
   lib  = "$(";
@@ -881,5 +885,6 @@
   int i;
 
-  cout << m_TITLE << " " << m_CONSTITUENT << endl;
+  //  cout << m_TITLE << " " << m_CONSTITUENT << endl;
+  CmtMessage::info (m_TITLE + " " + m_CONSTITUENT);
 
   //
@@ -1068,5 +1073,6 @@
       if (!CmtSystem::test_file (file_name) && !CmtSystem::test_directory (file_name))
         {
-          cerr << "#CMT> Warning: Source file " << file_name << " not found" << endl;
+          CmtMessage::warning ("Source file " + file_name + " not found");
+	  //          cerr << "#CMT> Warning: Source file " << file_name << " not found" << endl;
         }
 
@@ -1117,5 +1123,6 @@
   if (!CmtSystem::test_file (file) && !CmtSystem::test_directory (file))
     {
-      cerr << "#CMT> Warning: Source file " << file << " not found" << endl;
+      CmtMessage::warning ("Source file " + file + " not found");
+      //      cerr << "#CMT> Warning: Source file " << file << " not found" << endl;
     }
 
@@ -1480,4 +1487,14 @@
               if (file != NULL)
                 {
+                  CmtMessage::warning ("\n"
+				       "# A Makefile already exists "
+				       "but it does not provide\n"
+				       "# the recommended features "
+				       "for a full benefit of CMT\n"
+				       "#\n"
+				       "# CMT is now building "
+				       "a new 'Makefile.cmt' which you can use\n"
+				       "# to upgrade your current one.");
+		  /*
                   cerr << "# " << endl;
                   cerr << "#CMT> Warning: " << endl;
@@ -1491,5 +1508,5 @@
                   cerr << "# to upgrade your current one." << endl;
                   cerr << "# " << endl;
-
+		  */
                   s.write (file);
                   fclose (file);
@@ -2872,5 +2889,6 @@
   if (f == 0)
     {
-      cerr << "Cannot open " << m_output_file_name << " for write" << endl;
+      CmtMessage::error ("Cannot open " + m_output_file_name + " for write");
+      //      cerr << "Cannot open " << m_output_file_name << " for write" << endl;
     }
   else
@@ -3007,5 +3025,6 @@
       if (!CmtSystem::mkdir (stamp_output))
 	{
-	  cerr << "Cannot create the binary output directory for this constituent" << endl;
+	  CmtMessage::error ("Cannot create the binary output directory for this constituent " + stamp_output);
+	  //	  cerr << "Cannot create the binary output directory for this constituent" << endl;
 	}
 
Index: /CMT/HEAD/source/cmt_install_area.cxx
===================================================================
--- /CMT/HEAD/source/cmt_install_area.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_install_area.cxx	(revision 459)
@@ -13,4 +13,5 @@
 #include "cmt_cmtpath_pattern.h"
 #include "cmt_project.h"
+#include "cmt_log.h"
 
 CmtInstallAreaMgr& CmtInstallAreaMgr::instance ()
@@ -86,8 +87,11 @@
   if (installarea == "") return;
 
+  CmtMessage::warning ("Doing cleanup in the installation area " + installarea);
+  /*
   if (!Cmt::get_quiet ())
     {
       cerr << "#CMT> Warning: Doing cleanup in the installation area " << installarea << endl;
     }
+  */
 
   Symbol* macro = Symbol::find ("cmt_installarea_paths");
@@ -167,4 +171,7 @@
 	      // and the reference file
 
+	      CmtMessage::info ("Removing obsolete installed file [" + ref + "]"
+				"  (and " + ref_file + ")");
+	      /*
 	      if (!Cmt::get_quiet ())
 		{
@@ -172,4 +179,5 @@
 		  cerr << "  (and " << ref_file << ")" << endl;
 		}
+	      */
 
               CmtSystem::remove_file (ref);
Index: /CMT/HEAD/source/cmt_lock.cxx
===================================================================
--- /CMT/HEAD/source/cmt_lock.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_lock.cxx	(revision 459)
@@ -10,4 +10,5 @@
 #include "cmt_error.h"
 #include "cmt_symbol.h"
+#include "cmt_log.h"
 
 //----------------------------------------------------------
@@ -73,5 +74,6 @@
     }
 
-  cerr << "Package now locked" << endl;
+  CmtMessage::info ("Package now locked");
+  //  cerr << "Package now locked" << endl;
 
   return (locked_by_user);
@@ -91,5 +93,6 @@
       return (s);
     case not_locked:
-      cerr << "Package not locked" << endl;
+      CmtMessage::info ("Package not locked");
+      //      cerr << "Package not locked" << endl;
       return (s);
     }
@@ -148,5 +151,6 @@
     }
 
-  cerr << "Package now unlocked" << endl;
+  CmtMessage::info ("Package now unlocked");
+  //  cerr << "Package now unlocked" << endl;
 
   return (not_locked);
Index: /CMT/HEAD/source/cmt_log.h
===================================================================
--- /CMT/HEAD/source/cmt_log.h	(revision 458)
+++ /CMT/HEAD/source/cmt_log.h	(revision 459)
@@ -40,6 +40,103 @@
 #define Log static CmtLog log_instance
 #define log_endl CmtLog::end ()
-#define log      if (Cmt::get_debug ()) log_instance << "#CMT> (" << __FILE__ << "-" << __LINE__ << ") "
+#define log      if (Cmt::get_debug ()) log_instance << CmtMessage::prefix () + " (" << __FILE__ << ":" << __LINE__ << ") "
+//#define log      if (Cmt::get_debug ()) log_instance << "#CMT> (" << __FILE__ << "-" << __LINE__ << ") "
 #define log_cont if (Cmt::get_debug ()) log_instance
 
+
+enum CmtMsgLevel
+  {
+    Nil = 0,
+    Debug,
+    Info,
+    Warning,
+    Error,
+    Fatal
+  };
+
+class CmtMessage
+{
+public:
+  static cmt_string& prefix ();
+  static void set_prefix (const cmt_string& prefix);
+  static CmtMsgLevel& level ();
+  static void set_level (const CmtMsgLevel& level);
+  static bool active (const CmtMsgLevel& level);
+  static void info (const cmt_string& message);
+  static void warning (const cmt_string& message);
+  static void error (const cmt_string& message);
+  static void fatal (const cmt_string& message);
+
+private:
+  CmtMessage ();
+  static CmtMessage& instance ();
+  cmt_string m_prefix;
+  CmtMsgLevel m_level;
+};
+
+/**----------------------------------------------------------
+   The CmtMessage default constructor
+   Here are primarily constructed all default definitions
+*/
+inline CmtMessage::CmtMessage ()
+  : m_prefix ("#CMT--->"), m_level (Info)
+{ }
+
+/**----------------------------------------------------------
+   The CmtMessage singleton
+*/
+inline CmtMessage& CmtMessage::instance ()
+{
+  static CmtMessage me;
+  return me;
+}
+
+inline cmt_string& CmtMessage::prefix ()
+{
+  return instance ().m_prefix;
+}
+
+inline void CmtMessage::set_prefix (const cmt_string& prefix)
+{
+  instance ().m_prefix = prefix;
+}
+
+inline CmtMsgLevel& CmtMessage::level ()
+{
+  return instance ().m_level;
+}
+
+inline void CmtMessage::set_level (const CmtMsgLevel& level)
+{
+  instance ().m_level = level;
+}
+
+inline bool CmtMessage::active (const CmtMsgLevel& lvl)
+{
+  return level () <= lvl;
+}
+
+inline void CmtMessage::info (const cmt_string& message)
+{
+  if (active (Info))
+    cerr << prefix () << " Info: " << message << endl;
+}
+
+inline void CmtMessage::warning (const cmt_string& message)
+{
+  if (active (Warning))
+    cerr << prefix () << " Warning: " << message << endl;
+}
+
+inline void CmtMessage::error (const cmt_string& message)
+{
+  if (active (Error))
+    cerr << prefix () << " Error: " << message << endl;
+}
+
+inline void CmtMessage::fatal (const cmt_string& message)
+{
+  if (active (Fatal))
+    cerr << prefix () << " Fatal: " << message << endl;
+}
 #endif
Index: /CMT/HEAD/source/cmt_model.cxx
===================================================================
--- /CMT/HEAD/source/cmt_model.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_model.cxx	(revision 459)
@@ -8,4 +8,5 @@
 #include "cmt_fragment.h"
 #include "cmt_symbol.h"
+#include "cmt_log.h"
 
 /**
@@ -199,5 +200,6 @@
       if (it._pos != pos)
 	{
-	  cerr << "Syntax error: no element name" << endl;
+	  CmtMessage::error ("syntax: no element name");
+	  //	  cerr << "Syntax error: no element name" << endl;
 	  break;
 	}
@@ -341,5 +343,6 @@
 	  if (it._pos != pos)
 	    {
-	      cerr << "Syntax error : no attribute before closing the element [" << text.substr (pos) << "]" << endl;
+	      CmtMessage::error ("syntax: no attribute before closing the element [" + text.substr (pos) + "]");
+	      //	      cerr << "Syntax error : no attribute before closing the element [" << text.substr (pos) << "]" << endl;
 	      break;
 	    }
Index: /CMT/HEAD/source/cmt_parser.cxx
===================================================================
--- /CMT/HEAD/source/cmt_parser.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_parser.cxx	(revision 459)
@@ -515,4 +515,8 @@
   Me.clear ();
 
+  log << "configure_cmt_message" << log_endl;
+  //configure_cmt_message ();
+  configure_cmt_message (ap);
+
   log << "configure_default_path" << log_endl;
   configure_default_path ();
@@ -873,7 +877,6 @@
 	    {
 	      Me.m_current_version = "v*";
-	      cerr << "#CMT> Warning: "
-		   << "Could not read `" << version_file << "'."
-		   << " Default version " << Me.m_current_version << endl;
+	      CmtMessage::warning ("Could not read `" + version_file + "'."
+				   " Default version `" + Me.m_current_version + "'");
 	    }
 
@@ -943,7 +946,6 @@
 	      if (structuring_style == with_version_directory)
 		{
-		  cerr << "#CMT> Warning: `"
-		       << up_branch << "' is not correct version syntax."
-		    " Assuming it is package name" << endl;
+		  CmtMessage::warning ("`" + up_branch + "' is not correct version syntax."
+				       " Assuming it is package name");
 		}
 	      // No version descriptor
@@ -952,8 +954,7 @@
 	      Me.m_current_package = up_branch;
 	      Me.m_current_version = "v*";
-	      cerr << "#CMT> Warning: "
-		   << "Structuring style used `without_version_directory', `"
-		   << version_file << "' missing."
-		   << " Default version `" << Me.m_current_version << "'" << endl;
+	      CmtMessage::warning ("Structuring style used `without_version_directory'"
+				   ", `" + version_file + "' missing."
+				   " Default version `" + Me.m_current_version + "'");
 	      CmtSystem::dirname (up_dir, Me.m_current_path);
 	      
@@ -979,30 +980,85 @@
 void Cmt::configure_current_structuring_style (const ArgParser& ap)
 {
-  for (int i = ap.argc - 1; i >= 0; i--)
-    {
-      const cmt_string& arg = ap.argv[i];
-      if (arg == "-without_version_directory")
+  cmt_string s;
+  s = CmtSystem::getenv ("CMTSTRUCTURINGSTYLE");
+  if (s == "without_version_directory")
+    {
+      Me.m_current_structuring_style = without_version_directory;
+    }
+  else if (s == "with_version_directory")
+    {
+      Me.m_current_structuring_style = with_version_directory;
+    } 
+
+  CmtSystem::cmt_string_vector flags;
+  Cmt::get_cmt_flags (flags);
+  for (int i = 0; i < flags.size (); i++)
+    {
+      const cmt_string& flag = flags[i];
+      if (flag == "-without_version_directory")
 	{
 	  Me.m_current_structuring_style = without_version_directory;
-	  return;
 	}
-      else if (arg == "-with_version_directory")
+      else if (flag == "-with_version_directory")
 	{
 	  Me.m_current_structuring_style = with_version_directory;
-	  return;
+	} 
+    }
+
+  for (int i = 1; i < ap.argc; i++)
+    {
+      const cmt_string& arg = ap.argv[i];
+      if (arg[0] != '-') break;
+      if (arg == "-without_v" ||
+	  arg == "-without_ve" ||
+	  arg == "-without_ver" ||
+	  arg == "-without_vers" ||
+	  arg == "-without_versi" ||
+	  arg == "-without_versio" ||
+	  arg == "-without_version" ||
+	  arg == "-without_version_" ||
+	  arg == "-without_version_d" ||
+	  arg == "-without_version_di" ||
+	  arg == "-without_version_dir" ||
+	  arg == "-without_version_dire" ||
+	  arg == "-without_version_direc" ||
+	  arg == "-without_version_direct" ||
+	  arg == "-without_version_directo" ||
+	  arg == "-without_version_director" ||
+	  arg == "-without_version_directory")
+	{
+	  Me.m_current_structuring_style = without_version_directory;
+	  //	  if (!CmtSystem::putenv ("CMTSTRUCTURINGSTYLE", "without_version_directory"))
+	  //	    CmtMessage::error ("Cannot set `CMTSTRUCTURINGSTYLE' to"
+	  //			       " `without_version_directory' in the environment");
+	  if (!Cmt::add_cmt_flag ("-without_version_directory"))
+	    CmtMessage::error ("Cannot add flag `-without_version_directory'");
 	}
-    }
-
-  cmt_string s;
-
-  s = CmtSystem::getenv ("CMTSTRUCTURINGSTYLE");
-  if (s == "without_version_directory")
-    {
-      Me.m_current_structuring_style = without_version_directory;
-    }
-  else if (s == "with_version_directory")
-    {
-      Me.m_current_structuring_style = with_version_directory;
-    } 
+      else if (arg == "-with_v" ||
+	       arg == "-with_ve" ||
+	       arg == "-with_ver" ||
+	       arg == "-with_vers" ||
+	       arg == "-with_versi" ||
+	       arg == "-with_versio" ||
+	       arg == "-with_version" ||
+	       arg == "-with_version_" ||
+	       arg == "-with_version_d" ||
+	       arg == "-with_version_di" ||
+	       arg == "-with_version_dir" ||
+	       arg == "-with_version_dire" ||
+	       arg == "-with_version_direc" ||
+	       arg == "-with_version_direct" ||
+	       arg == "-with_version_directo" ||
+	       arg == "-with_version_director" ||
+	       arg == "-with_version_directory")
+	{
+	  Me.m_current_structuring_style = with_version_directory;
+	  //	  if (!CmtSystem::putenv ("CMTSTRUCTURINGSTYLE", "with_version_directory"))
+	  //	    CmtMessage::error ("Cannot set `CMTSTRUCTURINGSTYLE' to"
+	  //			       " `with_version_directory' in the environment");
+	  if (!Cmt::add_cmt_flag ("-with_version_directory"))
+	    CmtMessage::error ("Cannot add flag `-with_version_directory'");
+	}
+    }
 }
 
@@ -1265,4 +1321,137 @@
 
 //----------------------------------------------------------
+//void Cmt::configure_cmt_message ()
+void Cmt::configure_cmt_message (const ArgParser& ap)
+{
+  cmt_string s;
+
+  s = CmtSystem::getenv ("CMTMSGPREFIX");
+  if (s != "")
+    CmtMessage::set_prefix (s);
+
+  s = CmtSystem::getenv ("CMTFATAL");
+  if (s != "")
+    {
+      CmtMessage::set_level (Fatal);
+    }
+
+  s = CmtSystem::getenv ("CMTERROR");
+  if (s != "")
+    {
+      CmtMessage::set_level (Error);
+    }
+
+  s = CmtSystem::getenv ("CMTWARNING");
+  if (s != "")
+    {
+      CmtMessage::set_level (Warning);
+    }
+
+  s = CmtSystem::getenv ("CMTINFO");
+  if (s != "")
+    {
+      CmtMessage::set_level (Info);
+    }
+
+  s = CmtSystem::getenv ("CMTDEBUG");
+  if (s != "")
+    {
+      CmtMessage::set_level (Debug);
+    }
+
+  CmtSystem::cmt_string_vector flags;
+  Cmt::get_cmt_flags (flags);
+  for (int i = 0; i < flags.size (); i++)
+    {
+      const cmt_string& flag = flags[i];
+      if (flag == "-disable_warnings")
+	{
+	  Me.m_disable_warnings = true;
+	  if (CmtMessage::level () <= Warning)
+	    CmtMessage::set_level (Error);
+	}
+      else if (flag == "-quiet")
+	{
+	  Me.m_quiet = true;
+	  if (CmtMessage::level () <= Error)
+	    CmtMessage::set_level (Fatal);
+	}
+      else if (flag == "-warnings")
+	{
+	  Me.m_warnings = true;
+	  if (CmtMessage::level () != Warning)
+	    CmtMessage::set_level (Warning);
+	  //	  if (CmtMessage::level () > Warning)
+	}
+    }
+
+  for (int i = 1; i < ap.argc; i++)
+    {
+      const cmt_string& arg = ap.argv[i];
+      if (arg[0] != '-') break;
+      if (arg == "-d" ||
+	  arg == "-di" ||
+	  arg == "-dis" ||
+	  arg == "-disa" ||
+	  arg == "-disab" ||
+	  arg == "-disabl" ||
+	  arg == "-disable" ||
+	  arg == "-disable_" ||
+	  arg == "-disable_w" ||
+	  arg == "-disable_wa" ||
+	  arg == "-disable_war" ||
+	  arg == "-disable_warn" ||
+	  arg == "-disable_warni" ||
+	  arg == "-disable_warnin" ||
+	  arg == "-disable_warning" ||
+	  arg == "-disable_warnings")
+	{
+	  Me.m_disable_warnings = true;
+	  if (CmtMessage::level () <= Warning)
+	    {
+	      CmtMessage::set_level (Error);
+	      //	      if (!CmtSystem::putenv ("CMTERROR", "1"))
+	      //		CmtMessage::error ("Cannot set `CMTERROR' in the environment");
+	    }
+	  if (!Cmt::add_cmt_flag ("-disable_warnings"))
+	    CmtMessage::error ("Cannot add flag `-disable_warnings'");
+	}
+      else if (arg == "-q" ||
+	       arg == "-qu" ||
+	       arg == "-qui" ||
+	       arg == "-quie" ||
+	       arg == "-quiet")
+	{
+	  Me.m_quiet = true;
+	  if (CmtMessage::level () <= Error)
+	    {
+	      CmtMessage::set_level (Fatal);
+	      //	      if (!CmtSystem::putenv ("CMTFATAL", "1"))
+	      //		CmtMessage::error ("Cannot set `CMTFATAL' in the environment");
+	    }
+	  if (!Cmt::add_cmt_flag ("-quiet"))
+	    CmtMessage::error ("Cannot add flag `-quiet'");
+	}
+      else if (arg == "-warn" ||
+	       arg == "-warni" ||
+	       arg == "-warnin" ||
+	       arg == "-warning" ||
+	       arg == "-warnings")
+	{
+	  Me.m_warnings = true;
+	  //	  if (CmtMessage::level () > Warning)
+	  if (CmtMessage::level () != Warning)
+	    {
+	      CmtMessage::set_level (Warning);
+	      //	      if (!CmtSystem::putenv ("CMTWARNING", "1"))
+	      //		CmtMessage::error ("Cannot set `CMTWARNING' in the environment");
+	    }
+	  if (!Cmt::add_cmt_flag ("-warnings"))
+	    CmtMessage::error ("Cannot add flag `-warnings'");
+	}
+    }
+}
+
+//----------------------------------------------------------
 //
 //   Actions
@@ -1285,5 +1474,6 @@
   if (ap.arguments.size () < 1)
     {
-      cerr << "#CMT> cmt awk <file> <pattern>" << endl;
+      CmtMessage::error ("cmt awk <file> <pattern>");
+      //      cerr << "#CMT> cmt awk <file> <pattern>" << endl;
       return;
     }
@@ -1458,4 +1648,8 @@
           if (!use->located ())
             {
+	      CmtMessage::warning ("package " + use->get_package_name ()
+				   + " " + use->version + " " + use->path
+				   + " not found");
+	      /*
               if (!Me.m_quiet)
                 {
@@ -1465,4 +1659,5 @@
 		    endl;
                 }
+	      */
             }
           else
@@ -1623,10 +1818,16 @@
           if (s.find ("cmt_standalone") != cmt_string::npos)
             {
-              cerr << "#CMT> Currently not in a CMT package" << endl;
+              CmtMessage::warning ("Currently not in a CMT package");
+	      //              cerr << "#CMT> Currently not in a CMT package" << endl;
             }
           else
             {
+	      char num[32]; sprintf (num, "%d/%d", i+1, uses.size ());
+              CmtMessage::error ("Cannot move to the package in " + s
+				 + " (" + num + ")");
+	      /*
               cerr << "#CMT> Cannot move to the package in " << s << " (" << i+1 << "/" 
                    << uses.size () << ")"<< endl;
+	      */
             }
 
@@ -1638,6 +1839,11 @@
       if (CmtLock::check () == CmtLock::locked_by_another_user)
         {
+	  char num[32]; sprintf (num, "%d/%d", i+1, uses.size ());
+	  CmtMessage::warning ("Ignore locked package in " + s
+			       + " (" + num + ")");
+	  /*
           cerr << "#CMT> Ignore locked package in " << s << " (" << i+1 << "/" 
                << uses.size () << ")" << endl;
+	  */
           continue;
         }
@@ -1686,8 +1892,11 @@
 
 
+  if (CmtMessage::active (Error))
+    {
       cout << "#--------------------------------------------------------------" << endl;
       cout << "# Now trying [" << cmd << "] in " << s << " (" << i+1 << "/" << uses.size () 
            << ")" << endl;
       cout << "#--------------------------------------------------------------" << endl;
+    }
 
       if (is_cmt)
@@ -2042,5 +2251,6 @@
       if (!Tag::check_tag_used (tag) && !Symbol::check_tag_used (tag)) 
 	{
-	  cerr << "#CMT> The tag " << t << " is not used in any tag expression. Please check spelling" << endl;
+	  CmtMessage::warning ("The tag " + t + " is not used in any tag expression. Please check spelling");
+	  //	  cerr << "#CMT> The tag " << t << " is not used in any tag expression. Please check spelling" << endl;
 	}
     }
@@ -2062,5 +2272,6 @@
   if (!Tag::check_tag_used (tag) && !Symbol::check_tag_used (tag) && Cmt::get_warnings ()) 
     {
-      cerr << "#CMT> The CMTSITE value " << env << " is not used in any tag expression. Please check spelling" << endl;
+      CmtMessage::warning ("The CMTSITE value " + env + " is not used in any tag expression. Please check spelling");
+      //      cerr << "#CMT> The CMTSITE value " << env << " is not used in any tag expression. Please check spelling" << endl;
     }
 
@@ -2160,4 +2371,6 @@
       if (CmtSystem::test_file ("requirements"))
         {
+	  if (CmtMessage::active (Error))
+	    {
           cout << "------------------------------------------" << endl;
           cout << "Configuring environment for standalone package." << endl;
@@ -2165,4 +2378,5 @@
           cout << "System is " << Me.m_cmt_config << endl;
           cout << "------------------------------------------" << endl;
+	    }
 
           install_test_setup_scripts ();
@@ -2198,5 +2412,6 @@
   if (makes.size () > 0)
     {
-      cout << "Removing all previous make fragments from " << branch << endl;
+      if (CmtMessage::active (Info))
+	cout << "Removing all previous make fragments from " << branch << endl;
 
       for (int i = 0; i < makes.size (); i++)
@@ -2220,6 +2435,9 @@
   if (makes.size () > 0) 
     {
-      cout << "Removing all previous make fragments from "
-           << Me.m_cmt_config << endl; 
+      if (CmtMessage::active (Info))
+	{
+	  cout << "Removing all previous make fragments from "
+	       << Me.m_cmt_config << endl; 
+	}
 
       for (int i = 0; i < makes.size (); i++) 
@@ -2253,5 +2471,6 @@
   if (!reach_current_package ())
     {
-      cout << "Cannot read the requirements file" << endl;
+      CmtMessage::error ("Cannot read the requirements file");
+      //      cout << "Cannot read the requirements file" << endl;
       return;
     }
@@ -2276,14 +2495,17 @@
           if (!CmtSystem::mkdir (branch_name))
             {
-              cout << "Cannot create the " << branch_name <<" branch" << endl;
+              CmtMessage::error ("Cannot create the " + branch_name + " branch");
+	      //              cout << "Cannot create the " << branch_name <<" branch" << endl;
             }
           else
             {
-              cout << "Installing the " << branch_name << " directory" << endl;
+	      if (CmtMessage::active (Info))
+		cout << "Installing the " << branch_name << " directory" << endl;
             }
         }
       else
         {
-          cout << branch_name << " directory already installed" << endl;
+	  if (CmtMessage::active (Info))
+	    cout << branch_name << " directory already installed" << endl;
         }
     }
@@ -2330,4 +2552,6 @@
       if (CmtSystem::test_file ("requirements"))
         {
+	  if (CmtMessage::active (Error))
+	    {
           cout << "------------------------------------------" << endl;
           cout << "Configuring environment for standalone package." << endl;
@@ -2335,5 +2559,5 @@
           cout << "System is "   << Me.m_cmt_config << endl;
           cout << "------------------------------------------" << endl;
-
+	    }
           install_test_setup_scripts ();
           install_test_cleanup_scripts ();
@@ -2379,5 +2603,6 @@
   if (!reach_current_package ())
     {
-      cout << "Cannot read the requirements file" << endl;
+      CmtMessage::error ("Cannot read the requirements file");
+      //      cout << "Cannot read the requirements file" << endl;
       return;
     }
@@ -2401,14 +2626,17 @@
           if (!CmtSystem::mkdir (branch_name))
             {
-              cout << "Cannot create the " << branch_name <<" branch" << endl;
+              CmtMessage::error ("Cannot create the " + branch_name + " branch");
+	      //              cout << "Cannot create the " << branch_name <<" branch" << endl;
             }
           else
             {
-              cout << "Installing the " << branch_name << " directory" << endl;
+	      if (CmtMessage::active (Info))
+		cout << "Installing the " << branch_name << " directory" << endl;
             }
         }
       else
         {
-          cout << branch_name << " directory already installed" << endl;
+	  if (CmtMessage::active (Info))
+	    cout << branch_name << " directory already installed" << endl;
         }
     }
@@ -2456,4 +2684,6 @@
   // Now 'the_path' contains the complete path where the package will be created
 
+  if (CmtMessage::active (Error))
+    {
   cout << "------------------------------------------" << endl;
   cout << "Configuring environment for package " << package <<
@@ -2463,4 +2693,5 @@
   cout << "System is " << Me.m_cmt_config << endl;
   cout << "------------------------------------------" << endl;
+    }
 
   if (!CmtSystem::test_directory (the_path))
@@ -2468,10 +2699,12 @@
       if (!CmtSystem::mkdir (the_path))
         {
-          cout << "Cannot create the path directory" << endl;
+          CmtMessage::error ("Cannot create the path directory");
+	  //          cout << "Cannot create the path directory" << endl;
           return;
         }
       else
         {
-          cout << "Installing the path directory" << endl;
+	  if (CmtMessage::active (Info))
+	    cout << "Installing the path directory" << endl;
         }
     }
@@ -2483,15 +2716,18 @@
       if (!CmtSystem::mkdir (package))
         {
-          cout << "Cannot create the package directory" << endl;
+          CmtMessage::error ("Cannot create the package directory");
+	  //          cout << "Cannot create the package directory" << endl;
           return;
         }
       else
         {
-          cout << "Installing the package directory" << endl;
+	  if (CmtMessage::active (Info))
+	    cout << "Installing the package directory" << endl;
         }
     }
   else
     {
-      cout << "Package directory already installed" << endl;
+      if (CmtMessage::active (Info))
+	cout << "Package directory already installed" << endl;
     }
 
@@ -2528,15 +2764,18 @@
           if (!CmtSystem::mkdir (version))
             {
-              cout << "Cannot create the version directory" << endl;
+              CmtMessage::error ("Cannot create the version directory");
+	      //              cout << "Cannot create the version directory" << endl;
               return;
             }
           else
             {
-              cout << "Installing the version directory" << endl;
+	      if (CmtMessage::active (Info))
+		cout << "Installing the version directory" << endl;
             }
         }
       else
         {
-          cout << "Version directory already installed" << endl;
+	  if (CmtMessage::active (Info))
+	    cout << "Version directory already installed" << endl;
         }
 
@@ -2545,5 +2784,6 @@
   else
     {
-      cout << "Version directory will not be created due to structuring style" << endl;
+      if (CmtMessage::active (Info))
+	cout << "Version directory will not be created due to structuring style" << endl;
     }
 
@@ -2554,5 +2794,6 @@
           if (!CmtSystem::mkdir ("cmt"))
             {
-              cout << "Cannot create the cmt directory" << endl;
+	      CmtMessage::error ("Cannot create the cmt directory");
+//              cout << "Cannot create the cmt directory" << endl;
               return;
             }
@@ -2568,5 +2809,6 @@
                 }
 
-              cout << "Installing the cmt directory" << endl;
+	      if (CmtMessage::active (Info))
+		cout << "Installing the cmt directory" << endl;
             }
         }
@@ -2582,5 +2824,6 @@
             }
           
-          cout << "Mgr directory already installed" << endl;
+	  if (CmtMessage::active (Info))
+	    cout << "Mgr directory already installed" << endl;
         }
     }
@@ -2596,5 +2839,6 @@
         }
 
-      cout << "Cmt directory already installed" << endl;
+      if (CmtMessage::active (Info))
+	cout << "Cmt directory already installed" << endl;
     }
 
@@ -2603,15 +2847,18 @@
       if (!CmtSystem::mkdir ("src"))
         {
-          cout << "Cannot create the src directory" << endl;
+          CmtMessage::error ("Cannot create the src directory");
+	  //          cout << "Cannot create the src directory" << endl;
           return;
         }
       else
         {
-          cout << "Installing the src directory" << endl;
+	  if (CmtMessage::active (Info))
+	    cout << "Installing the src directory" << endl;
         }
     }
   else
     {
-      cout << "src directory already installed" << endl;
+      if (CmtMessage::active (Info))
+	cout << "src directory already installed" << endl;
     }
 
@@ -2801,5 +3048,5 @@
       Symbol::expand (cmd);
 
-      cerr << "Execute action " << ap.arguments[0] << " => " << cmd << endl;
+      CmtMessage::info ("Execute action " + ap.arguments[0] + " => " + cmd);
 
       int status = CmtSystem::execute (cmd);
@@ -2849,5 +3096,6 @@
   if (!CmtSystem::test_file (input))
     {
-      cerr << "#CMT> File " << input << " not found" << endl;
+      CmtMessage::error ("File " + input + " not found");
+      //      cerr << "#CMT> File " << input << " not found" << endl;
       return;
     }
@@ -2864,5 +3112,6 @@
   if (file == NULL)
     {
-      cerr << "#CMT> Cannot write filtered file " << output << endl;
+      CmtMessage::error ("Cannot write filtered file " + output);
+      //      cerr << "#CMT> Cannot write filtered file " << output << endl;
     }
   else
@@ -2896,5 +3145,6 @@
   //(unsused) Use& use = Use::current();
 
-  cerr << "try to lock package " << package << " in " << CmtSystem::pwd () << endl;
+  CmtMessage::info ("try to lock package " + package + " in " + CmtSystem::pwd ());
+  //  cerr << "try to lock package " << package << " in " << CmtSystem::pwd () << endl;
 
   set_standard_macros ();
@@ -2936,4 +3186,6 @@
   CmtSystem::compress_path (the_path);
 
+  if (CmtMessage::active (Info))
+    {
   cout << "------------------------------------------" << endl;
   cout << "Removing package " << package <<
@@ -2943,4 +3195,5 @@
   cout << "System is " << Me.m_cmt_config << endl;
   cout << "------------------------------------------" << endl;
+    }
 
   the_path += CmtSystem::file_separator ();
@@ -2949,5 +3202,6 @@
   if (!CmtSystem::cd (the_path))
     {
-      cerr << "Path " << the_path << " not reachable" << endl;
+      CmtMessage::error ("Path " + the_path + " not reachable");
+      //      cerr << "Path " << the_path << " not reachable" << endl;
       return;
     }
@@ -2957,5 +3211,6 @@
       if (CmtSystem::remove_directory (version))
         {
-          cerr << "Version " << version << " has been removed from " << the_path << endl;
+	  if (CmtMessage::active (Info))
+	    cerr << "Version " << version << " has been removed from " << the_path << endl;
           CmtSystem::cmt_string_vector contents;
           CmtSystem::scan_dir (".", contents);
@@ -2965,5 +3220,6 @@
               if (CmtSystem::remove_directory (package))
                 {
-                  cerr << "Package " << package << " has no more versions. Thus it has been removed."<< endl;
+		  if (CmtMessage::active (Info))
+		    cerr << "Package " << package << " has no more versions. Thus it has been removed."<< endl;
                 }
             }
@@ -2971,5 +3227,6 @@
       else
         {
-          cerr << "Impossible to remove version " << version << " from " << the_path << endl;
+          CmtMessage::warning ("Impossible to remove version " + version + " from " + the_path);
+	  //          cerr << "Impossible to remove version " << version << " from " << the_path << endl;
         }
     }
@@ -2986,21 +3243,27 @@
           if (!CmtSystem::remove_directory ("cmt"))
             {
+	      if (CmtMessage::active (Info))
+		{
               cerr << "Unstructured version " << version
                    << " has been removed from " << the_path << endl;
+		}
             }
           else
             {
-              cerr << "Impossible to remove unstructured version " << version
-                   << " from " << the_path << endl;
+              CmtMessage::warning ("Impossible to remove unstructured version " + version + " from " + the_path);
+	      //              cerr << "Impossible to remove unstructured version " << version
+	      //                   << " from " << the_path << endl;
             }
         }
       else
         {
-          cerr << "Version " << version << " not found" << endl;
+          CmtMessage::warning ("Version " + version + " not found");
+	  //          cerr << "Version " << version << " not found" << endl;
         }
     }
   else
     {
-      cerr << "Version " << version << " not found" << endl;
+      CmtMessage::warning ("Version " + version + " not found");
+      //      cerr << "Version " << version << " not found" << endl;
     }
 }
@@ -3051,4 +3314,8 @@
       if (!use->located ())
         {
+	  CmtMessage::warning ("package " + use->get_package_name ()
+			       + " " + use->version + " " + use->path
+			       + " not found");
+	      /*
           if (!Me.m_quiet)
             {
@@ -3058,4 +3325,5 @@
 		endl;
             }
+	      */
         }
       else
@@ -3185,5 +3453,6 @@
                   if (status != 2) CmtError::set (CmtError::execution_error, s);
 
-                  cerr << "#CMT> Cannot remove the symbolic link " << s << endl;
+                  CmtMessage::warning ("Cannot remove the symbolic link " + s);
+		  //                  cerr << "#CMT> Cannot remove the symbolic link " << s << endl;
 
                   break;
@@ -3218,9 +3487,12 @@
 void Cmt::do_run_sequence (const ArgParser& ap)
 {
-  if (ap.arguments.size () == 0) cerr << "#CMT> run_sequence: no sequence specified" << endl;
+  if (ap.arguments.size () == 0)
+    CmtMessage::warning ("run_sequence: no sequence specified");
+  //cerr << "#CMT> run_sequence: no sequence specified" << endl;
 
   SequenceRunner runner;
 
-  cerr << "# cmt run_sequence: sequence " << ap.arguments[0] << endl;
+  if (CmtMessage::active (Info))
+    cerr << "# cmt run_sequence: sequence " << ap.arguments[0] << endl;
 
   runner.run (ap.arguments[0]);
@@ -3230,5 +3502,7 @@
 void Cmt::do_set_version (const ArgParser& ap)
 {
-  if (ap.arguments.size () == 0) cerr << "#CMT> set version: no version specified" << endl;
+  if (ap.arguments.size () == 0)
+    CmtMessage::warning ("set version: no version specified");
+  //cerr << "#CMT> set version: no version specified" << endl;
 
   const cmt_string& version = ap.arguments[0];
@@ -3238,5 +3512,6 @@
   if (!CmtSystem::is_version_directory (version, v, r, p))
     {
-      cerr << "#CMT> set version " << version << " is not a correct version syntax" << endl;
+      CmtMessage::error ("set version " + version + " is not a correct version syntax");
+      //      cerr << "#CMT> set version " << version << " is not a correct version syntax" << endl;
       return;
     }
@@ -3244,6 +3519,8 @@
   if ((v == -1) || (r == -1) || (p == -1))
     {
-      cerr << "#CMT> set version " << version
-	   << " You cannot use wild card to set a version" << endl;
+      CmtMessage::error ("set version " + version
+			 + " You cannot use wild card to set a version");
+      //      cerr << "#CMT> set version " << version
+      //	   << " You cannot use wild card to set a version" << endl;
       return;
     }
@@ -3258,6 +3535,8 @@
   if (branch != "cmt")
     {
-      cerr << "#CMT> set version " << version << " must be applied in a cmt directory" 
-	   << endl;
+      CmtMessage::error ("set version " + version
+			 + " must be applied in a cmt directory");
+      //      cerr << "#CMT> set version " << version << " must be applied in a cmt directory" 
+      //	   << endl;
       return;
     }
@@ -3268,10 +3547,13 @@
   if (branch == version)
     {
-      cerr << "#CMT> set version " << version << " is already available as a version directory" 
-	   << endl;
+      CmtMessage::warning ("set version " + version
+			   + " is already available as a version directory");
+      //      cerr << "#CMT> set version " << version << " is already available as a version directory" 
+      //	   << endl;
       return;
     }
 
-  cerr << "Writing version file : " << version << endl;
+  CmtMessage::info ("Writing version file : " + version);
+  //  cerr << "Writing version file : " << version << endl;
 
   version.write ("version.cmt");
@@ -4012,5 +4294,6 @@
   // (unused??) Use& use = Use::current();
 
-  cerr << "try to unlock package " << package << " in " << CmtSystem::pwd () << endl;
+  CmtMessage::info ("try to unlock package " + package + " in " + CmtSystem::pwd ());
+  //  cerr << "try to unlock package " << package << " in " << CmtSystem::pwd () << endl;
 
   set_standard_macros ();
@@ -4151,4 +4434,49 @@
 {
   return (Me.m_all_sets_done);
+}
+
+//----------------------------------------------------------
+void Cmt::get_cmt_flags (CmtSystem::cmt_string_vector& flags)
+{
+  CmtSystem::split (CmtSystem::getenv ("CMTFLAGS"), " \t", flags);
+}
+
+//----------------------------------------------------------
+cmt_string Cmt::get_cmt_flags ()
+{
+  return CmtSystem::getenv ("CMTFLAGS");
+}
+
+//----------------------------------------------------------
+bool Cmt::set_cmt_flags (const cmt_string& cmtflags)
+{
+  return CmtSystem::putenv ("CMTFLAGS", cmtflags) ?
+    true :
+    (CmtMessage::error ("Cannot set `CMTFLAGS' to `" + cmtflags +
+			"' in the environment"),
+     false) ;
+}
+
+//----------------------------------------------------------
+bool Cmt::add_cmt_flag (const cmt_string& flag)
+{
+  CmtSystem::cmt_string_vector flags;
+  get_cmt_flags (flags);
+  cmt_string cmtflags;
+  for (int i = 0; i < flags.size (); i++)
+    {
+      if (flags[i] == flag) continue;
+      if (cmtflags == "")
+	cmtflags = flags[i]; 
+      else
+	cmtflags += " " + flags[i]; 
+    }
+
+  if (cmtflags == "")
+    cmtflags = flag; 
+  else
+    cmtflags += " " + flag; 
+
+  return set_cmt_flags (cmtflags);
 }
 
@@ -4311,5 +4639,6 @@
 #endif
 
-  cerr << "Creating cleanup scripts." << endl;
+  if (CmtMessage::active (Error))
+    cerr << "Creating cleanup scripts." << endl;
 
   cmt_string temp;
@@ -4397,5 +4726,6 @@
 #endif
 
-  cerr << "Creating setup scripts." << endl;
+  if (CmtMessage::active (Error))
+    cerr << "Creating setup scripts." << endl;
 
   Use& current_use = Use::current ();
@@ -4511,5 +4841,6 @@
 #endif
 
-  cerr << "Creating cleanup scripts." << endl;
+  if (CmtMessage::active (Error))
+    cerr << "Creating cleanup scripts." << endl;
 
   cmt_string temp;
@@ -4590,5 +4921,6 @@
       if (value != "")
 	{
-	  cerr << "Creating native_version file." << endl;    
+	  if (CmtMessage::active (Info))
+	    cerr << "Creating native_version file." << endl;    
 
 	  FILE* f = fopen ("new.native_version.cmt", "wb");
@@ -4618,5 +4950,6 @@
 #endif
 
-  cerr << "Creating setup scripts." << endl;
+  if (CmtMessage::active (Error))
+    cerr << "Creating setup scripts." << endl;
 
   Use& current_use = Use::current ();
@@ -4804,4 +5137,6 @@
   if (!CmtSystem::cd (Me.m_current_path))
     {
+      CmtMessage::error ("Cannot reach the directory " + Me.m_current_path);
+      /*
       if (!Me.m_quiet)
         {
@@ -4809,4 +5144,5 @@
             Me.m_current_path << endl;
         }
+      */
       CmtError::set (CmtError::package_not_found, "Load> Cannot reach the path directory");
       CmtSystem::cd (Me.m_current_dir);
@@ -4820,4 +5156,6 @@
   if (!CmtSystem::cd (Me.m_current_package))
     {
+      CmtMessage::error ("Cannot reach the package " + Me.m_current_package);
+      /*
       if (!Me.m_quiet)
         {
@@ -4825,4 +5163,5 @@
             Me.m_current_package << endl;
         }
+      */
       CmtError::set (CmtError::package_not_found, "Load> Cannot reach the package directory");
       CmtSystem::cd (Me.m_current_dir);
@@ -4840,4 +5179,6 @@
       if (!CmtSystem::test_directory ("cmt"))
         {
+	  CmtMessage::error ("Cannot reach the version " + Me.m_current_version);
+	  /*
           if (!Me.m_quiet)
             {
@@ -4845,4 +5186,5 @@
                 Me.m_current_version << endl;
             }
+	  */
           CmtError::set (CmtError::package_not_found, "Load> Cannot reach the version directory");
           CmtSystem::cd (Me.m_current_dir);
@@ -4879,8 +5221,11 @@
       else
         {
+	  CmtMessage::error ("Cannot reach the mgr branch");
+	  /*
           if (!Me.m_quiet)
             {
               cerr << "#CMT> Cannot reach the mgr branch" << endl;
             }
+	  */
 
           CmtError::set (CmtError::package_not_found,
@@ -5032,4 +5377,7 @@
     }
 
+  // save CMTFLAGS
+  cmt_string cmtflags (get_cmt_flags ());
+
   clear ();
 
@@ -5069,5 +5417,6 @@
   if (Me.m_configure_error != "")
     {
-      if (!Me.m_quiet) cerr << "#CMT> Error: " << Me.m_configure_error << endl;
+      CmtMessage::error (Me.m_configure_error);
+      //      if (!Me.m_quiet) cerr << "#CMT> Error: " << Me.m_configure_error << endl;
       return (CmtError::execution_error);
     }
@@ -5645,5 +5994,6 @@
 	  break;
 	case action_load :
-	  cerr << "#CMT> action not implemented" << endl;
+	  CmtMessage::error ("action not implemented");
+	  //	  cerr << "#CMT> action not implemented" << endl;
 	  break;
 	case action_lock :
@@ -5820,4 +6170,7 @@
 	}
     }
+
+  // restore CMTFLAGS
+  set_cmt_flags (cmtflags);
 
   if (CmtError::has_pending_error ())
@@ -6300,8 +6653,11 @@
           else
             {
+	      CmtMessage::error ("Cannot reach the mgr branch");
+	      /*
               if (!Me.m_quiet)
                 {
                   cerr << "#CMT> Cannot reach the mgr branch" << endl;
                 }
+	      */
               
               CmtError::set (CmtError::package_not_found,
Index: /CMT/HEAD/source/cmt_pattern.cxx
===================================================================
--- /CMT/HEAD/source/cmt_pattern.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_pattern.cxx	(revision 459)
@@ -16,4 +16,5 @@
 #include "cmt_error.h"
 #include "cmt_syntax.h"
+#include "cmt_log.h"
 
 
@@ -915,4 +916,11 @@
 	    {
 	      state = in_error;
+	      CmtMessage::warning ("bad syntax in apply_pattern " + name
+				   + " (missing '=' separator)"
+				   + ( (use != 0) ?
+				       " (from " + use->get_package_name () + ")":
+				       "" )
+				   );
+	      /*
 	      if (!Cmt::get_quiet ())
 		{
@@ -924,4 +932,5 @@
 		  cerr << endl;
 		}
+	      */
 	      break;
 	    }
@@ -990,4 +999,11 @@
 	  if (p->line.find (tsearch) == cmt_string::npos)
 	    {
+	      CmtMessage::warning ("template <" + tname
+				   + "> not expected in pattern " + name
+				   + ( (use != 0) ?
+				       " (from " + use->get_package_name () + ")":
+				       "" )
+				   );
+	      /*
 	      if (!Cmt::get_quiet ())
 		{
@@ -996,4 +1012,5 @@
 		  cerr << endl;
 		}
+	      */
 	    }
 
Index: /CMT/HEAD/source/cmt_project.cxx
===================================================================
--- /CMT/HEAD/source/cmt_project.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_project.cxx	(revision 459)
@@ -18,4 +18,5 @@
 #include "cmt_tag.h"
 #include "cmt_error.h"
+#include "cmt_log.h"
 
 class ProjectReader : public Awk
@@ -232,4 +233,8 @@
 	  if (r != p.get_release ())
 	    {
+	      CmtMessage::error ("Project " + p.get_name ()
+				   + " requested with conflicting releases "
+				   + p.get_release () + " and " + r);
+	      /*
 	      if (!Cmt::get_quiet ())
 		{
@@ -237,4 +242,5 @@
 		       << " requested with conflicting releases " << p.get_release () << " and " << r << endl;
 		}
+	      */
 	      CmtError::set (CmtError::project_release_conflict, p.get_name ());
 	    }
@@ -420,4 +426,8 @@
 	      // The specified name is not in the path.
 	      
+	      CmtMessage::warning ("none of specified project names "
+				   + specified_name + " from graph and "
+				   + project_name + " from project file match path.");
+	      /*
 	      if (!Cmt::get_quiet ())
 		{
@@ -428,4 +438,5 @@
 		       << " from project file match path." << endl;
 		}
+	      */
 
 	      name = specified_name;
@@ -650,4 +661,6 @@
   cmt_string pwd = CmtSystem::pwd ();
 
+  if (CmtMessage::active (Error))
+    {
   cerr << "------------------------------------------" << endl;
   cerr << "Configuring environment for project " << name << " " << release << " (from " << pwd << ") ";
@@ -661,4 +674,5 @@
   cerr << "CMT version " << Cmt::get_cmt_version () << "." << endl;
   cerr << "------------------------------------------" << endl;
+    }
 
   if (path != "")
@@ -666,5 +680,6 @@
       if (!CmtSystem::mkdir (path))
 	{
-          cerr << "Cannot create the " << path << " directory" << endl;
+          CmtMessage::error ("Cannot create the " + path + " directory");
+	  //          cerr << "Cannot create the " << path << " directory" << endl;
           return (false);
 	}
@@ -672,5 +687,6 @@
       if (!CmtSystem::cd (path))
 	{
-          cerr << "Cannot access the " << path << " directory" << endl;
+          CmtMessage::error ("Cannot access the " + path + " directory");
+	  //          cerr << "Cannot access the " << path << " directory" << endl;
           return (false);
 	}
@@ -679,5 +695,6 @@
   if (!CmtSystem::mkdir (name))
     {
-      cerr << "Cannot create the " << name << " directory" << endl;
+      CmtMessage::error ("Cannot create the " + name + " directory");
+      //      cerr << "Cannot create the " << name << " directory" << endl;
       return (false);
     }
@@ -685,5 +702,6 @@
   if (!CmtSystem::cd (name))
     {
-      cerr << "Cannot access the " << name << " directory" << endl;
+      CmtMessage::error ("Cannot access the " + name + " directory");
+      //      cerr << "Cannot access the " << name << " directory" << endl;
       return (false);
     }
@@ -693,5 +711,6 @@
       if (!CmtSystem::mkdir (release))
 	{
-	  cerr << "Cannot create the " << release << " directory" << endl;
+	  CmtMessage::error ("Cannot create the " + release + " directory");
+	  //	  cerr << "Cannot create the " << release << " directory" << endl;
 	  return (false);
 	}
@@ -699,5 +718,6 @@
       if (!CmtSystem::cd (release))
 	{
-	  cerr << "Cannot access the " << release << " directory" << endl;
+	  CmtMessage::error ("Cannot access the " + release + " directory");
+	  //	  cerr << "Cannot access the " << release << " directory" << endl;
 	  return (false);
 	}
@@ -708,10 +728,12 @@
       if (!CmtSystem::mkdir ("cmt"))
         {
-          cerr << "Cannot create the cmt directory" << endl;
+          CmtMessage::error ("Cannot create the cmt directory");
+	  //          cerr << "Cannot create the cmt directory" << endl;
           return (false);
         }
       else
         {
-          cerr << "Installing the cmt directory" << endl;
+	  if (CmtMessage::active (Info))
+	    cerr << "Installing the cmt directory" << endl;
         }
     }
@@ -721,5 +743,6 @@
   if (!CmtSystem::test_file (get_project_file_name ()))
     {
-      cerr << "Creating a new project file" << endl;
+      if (CmtMessage::active (Info))
+	cerr << "Creating a new project file" << endl;
 
       ofstream f (get_project_file_name ());
@@ -732,5 +755,6 @@
       else
 	{
-          cerr << "Cannot create the project file" << endl;
+          CmtMessage::error ("Cannot create the project file");
+	  //          cerr << "Cannot create the project file" << endl;
           return (false);
 	}
@@ -746,5 +770,6 @@
       p.commit ();
 
-      cerr << "project file already there" << endl;
+      if (CmtMessage::active (Info))
+	cerr << "project file already there" << endl;
     }
 
@@ -831,12 +856,15 @@
     if (project != 0) 
       {
-	if (!Cmt::get_quiet ())
-	  {
+	//	if (!Cmt::get_quiet ())
+	//	  {
 	    if (release != project->get_release ())
 	      {
-		cerr << "#CMT> Project " << name << " requested with conflicting releases " << project->get_release () << " and " << release << endl;
+		CmtMessage::error ("Project " + name
+				   + " requested with conflicting releases "
+				   + project->get_release () + " and " + release);
+		//		cerr << "#CMT> Project " << name << " requested with conflicting releases " << project->get_release () << " and " << release << endl;
 		CmtError::set (CmtError::project_release_conflict, name);
 	      }
-	  }
+	    //	  }
 
 	// Project objects are recreated here to follow the hierarchy
@@ -1592,5 +1620,6 @@
   if (!found && (cmtprojectpath != ""))
     {
-      cerr << "#CMT> Project " << name << " " << release << " requested by " << m_name << " not found in CMTPROJECTPATH" << endl;
+      CmtMessage::warning ("Project " + name + " " + release + " requested by " + m_name + " not found in CMTPROJECTPATH");
+      //      cerr << "#CMT> Project " << name << " " << release << " requested by " << m_name << " not found in CMTPROJECTPATH" << endl;
     }
 }
@@ -1873,5 +1902,6 @@
   if (def == 0)
     {
-      cerr << "#CMT> strategy " << name << " undefined" << endl;
+      CmtMessage::warning ("strategy " + name + " undefined");
+      //      cerr << "#CMT> strategy " << name << " undefined" << endl;
       return (false);
     }
@@ -1930,5 +1960,6 @@
   if (def == 0)
     {
-      cerr << "#CMT> strategy " << name << " undefined" << endl;
+      CmtMessage::warning ("strategy " + name + " undefined");
+      //      cerr << "#CMT> strategy " << name << " undefined" << endl;
       return;
     }
@@ -1946,5 +1977,6 @@
   if (def == 0)
     {
-      cerr << "#CMT> strategy " << name << " undefined" << endl;
+      CmtMessage::warning ("strategy " + name + " undefined");
+      //      cerr << "#CMT> strategy " << name << " undefined" << endl;
       return;
     }
@@ -1962,5 +1994,6 @@
   else
     {
-      cerr << "#CMT> requested strategy value " << value << " undefined in strategy " << name << endl;
+      CmtMessage::warning ("requested strategy value " + value + " undefined in strategy " + name);
+      //      cerr << "#CMT> requested strategy value " << value << " undefined in strategy " << name << endl;
       return;
     }
Index: /CMT/HEAD/source/cmt_symbol.cxx
===================================================================
--- /CMT/HEAD/source/cmt_symbol.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_symbol.cxx	(revision 459)
@@ -14,4 +14,5 @@
 #include "cmt_system.h"
 #include "cmt_database.h"
+#include "cmt_log.h"
 
 // Global inhibitor of any display
@@ -773,8 +774,17 @@
                   } 
 
+                CmtMessage::warning ("Symbol " + name 
+				     + " inconsistently redeclared from " + s1
+				     + " to " + s2
+				     + ( (use != 0) ?
+					 " in package " + use->get_package_name () :
+					 "" )
+				     );
+		/*
                 cerr << "#CMT> Warning: Symbol " << name 
                      << " inconsistently redeclared from " << s1 << " to " << s2;
                 if (use != 0) cerr << " in package " << use->get_package_name ();
                 cerr << endl;
+		*/
               }
           }
@@ -876,9 +886,11 @@
       if (!CmtSystem::test_directory (t))
 	  {
+	    CmtMessage::warning ("Wrong path item " + t + " in " + name);
+	    /*
 	      if (Cmt::get_warnings ())
 	      {
 	          cerr << "#CMT> Warning: Wrong path item " << t << " in " << name << endl;
 	      }
-
+	    */
 	  }
 	    
Index: /CMT/HEAD/source/cmt_syntax.cxx
===================================================================
--- /CMT/HEAD/source/cmt_syntax.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_syntax.cxx	(revision 459)
@@ -18,4 +18,5 @@
 #include "cmt_project.h"
 #include "cmt_cmtpath_pattern.h"
+#include "cmt_log.h"
 
 
@@ -1294,6 +1295,8 @@
 	       int line_number)
   {
-    cerr << "# Package " << use->get_package_name () <<
-      " sets obsolescent version strategy" << endl;
+    CmtMessage::warning ("Package " + use->get_package_name ()
+			 + " sets obsolescent version strategy");
+    //    cerr << "# Package " << use->get_package_name () <<
+    //      " sets obsolescent version strategy" << endl;
   }
   void action (const CmtSystem::cmt_string_vector& words,
@@ -1331,4 +1334,9 @@
       Unknown keyword : just ignore the line
     */
+    char num[32]; sprintf (num, "%d", line_number);
+    CmtMessage::error ("bad syntax in requirements of " + use->get_package_name ()
+		       + " " + use->version + " line #" + num
+		       + " [" + words[0] + "...]");
+    /*
     if (!Cmt::get_quiet ())
       {
@@ -1337,4 +1345,5 @@
 	cerr << " [" << words[0] << "...]" << endl;
       }
+    */
     
     CmtError::set (CmtError::syntax_error, "ParseRequirements> ");
@@ -1890,4 +1899,11 @@
   if (CmtError::has_pending_error ())
     {
+      char num[32]; sprintf (num, "%d", line_number);
+      CmtMessage::error ("bad syntax in requirements of " + use->get_package_name ()
+			 + " " + use->version
+			 + " " + use->specified_path
+			 + " line #" + num
+			 + " [" + command + " ...]");
+      /*
       if (!Cmt::get_quiet ())
         {
@@ -1898,4 +1914,5 @@
           cerr << " [" << command << " ...]" << endl;
         }
+      */
 
       return;
@@ -1934,4 +1951,9 @@
   if (CmtError::has_pending_error ())
     {
+      char num[32]; sprintf (num, "%d", line_number);
+      CmtMessage::error ("bad syntax in project file of " + project->get_name ()
+			 + " line #" + num
+			 + " [" + command + " ...]");
+      /*
       if (!Cmt::get_quiet ())
         {
@@ -1940,4 +1962,5 @@
           cerr << " [" << command << " ...]" << endl;
         }
+      */
 
       return;
Index: /CMT/HEAD/source/cmt_system.cxx
===================================================================
--- /CMT/HEAD/source/cmt_system.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_system.cxx	(revision 459)
@@ -58,4 +58,5 @@
 #include "cmt_error.h"
 #include "cmt_map.h"
+#include "cmt_log.h"
 
 //--------------------------------------------------
@@ -659,5 +660,6 @@
   if (::unlink (name) != 0)
     {
-      cerr << "#CMT> Cannot remove file " << name << endl;
+      CmtMessage::error ("Cannot remove file " + name);
+      //      cerr << "#CMT> Cannot remove file " << name << endl;
       return (false);
     }
@@ -694,5 +696,7 @@
   if (status != 0)
     {
-      cerr << "#CMT> Cannot remove directory " << name << " errno=" << errno << endl;
+      char num[32]; sprintf (num, "%d", errno);
+      CmtMessage::error ("Cannot remove directory " + name + " errno=" + num);
+      //      cerr << "#CMT> Cannot remove directory " << name << " errno=" << errno << endl;
       return (false);
     }
Index: /CMT/HEAD/source/cmt_tag.cxx
===================================================================
--- /CMT/HEAD/source/cmt_tag.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_tag.cxx	(revision 459)
@@ -202,8 +202,11 @@
   if (name == "")
     {
+      CmtMessage::warning ("apply_tag with empty name [" + words[1] + "]");
+      /*
       if (!Cmt::get_quiet ())
 	{
 	  cerr << "#CMT> Warning: apply_tag with empty name [" << words[1] << "]" << endl;
 	}
+      */
     }
   else
@@ -485,5 +488,6 @@
           else
             {
-              cerr << "#Tag::add> unknown tag " << op_name << " in tag expression" << endl;
+              CmtMessage::warning ("Tag::add> unknown tag " + op_name + " in tag expression");
+	      //              cerr << "#Tag::add> unknown tag " << op_name << " in tag expression" << endl;
             }
         }
Index: /CMT/HEAD/source/cmt_triggers.cxx
===================================================================
--- /CMT/HEAD/source/cmt_triggers.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_triggers.cxx	(revision 459)
@@ -25,4 +25,5 @@
 #include "cmt_constituent.h"
 #include "cmt_syntax.h"
+#include "cmt_log.h"
 
 //--------------------------------------------------
@@ -248,16 +249,22 @@
   if (pos == 0)
     {
+      CmtMessage::error ("Syntax in trigger file : empty name");
+      /*
       if (!Cmt::get_quiet ())
         {
           cerr << "Syntax error in trigger file : empty name" << endl;
         }
+      */
       exit (0);
     }
   if (pos == cmt_string::npos)
     {
+      CmtMessage::error ("Syntax in trigger file : no = sign");
+      /*
       if (!Cmt::get_quiet ())
         {
           cerr << "Syntax error in trigger file : no = sign" << endl;
         }
+      */
       exit (0);
     }
@@ -297,4 +304,6 @@
   else
     {
+      CmtMessage::error ("Syntax in trigger file : bad keyword (" + name + ")");
+      /*
       if (!Cmt::get_quiet ())
         {
@@ -302,4 +311,5 @@
 	    name << ")" << endl;
         }
+      */
       exit (0);
     }
@@ -418,4 +428,7 @@
   if ((pos == 0) || (pos == cmt_string::npos))
     {
+      CmtMessage::error ("Syntax in dependency file: " + line
+			 + ": Missing = or target name.");
+      /*
       if (!Cmt::get_quiet ())
         {
@@ -423,4 +436,5 @@
           cerr << "  Missing = or target name." << endl;
         }
+      */
       exit (1);
     }
@@ -447,6 +461,8 @@
   if (dependencies == "") 
     {
-      cerr << "#CMT> Warning: It seems there is nothing after \'=\' "
-	"in dependency file " << m_file_name << endl;
+      CmtMessage::warning ("It seems there is nothing after \'=\' "
+			   "in dependency file " + m_file_name);
+      //      cerr << "#CMT> Warning: It seems there is nothing after \'=\' "
+      //	"in dependency file " << m_file_name << endl;
       return;
     }
@@ -831,5 +847,6 @@
   if (analyzer->run (file_name) == Awk::failed)
     {
-      cerr << "  File " << file_name << " not found" << endl;
+      CmtMessage::warning (" File " + file_name + " not found");
+      //      cerr << "  File " << file_name << " not found" << endl;
     }
 
Index: /CMT/HEAD/source/cmt_use.cxx
===================================================================
--- /CMT/HEAD/source/cmt_use.cxx	(revision 458)
+++ /CMT/HEAD/source/cmt_use.cxx	(revision 459)
@@ -16,4 +16,5 @@
 #include "cmt_database.h"
 #include "cmt_syntax.h"
+#include "cmt_log.h"
 
 static void show_packages ();
@@ -497,4 +498,8 @@
           if (!use->located ())
             {
+	      CmtMessage::warning ("package " + use->get_package_name ()
+				   + " " + use->version + " " + use->path
+				   + " not found");
+	      /*
               if (!Cmt::get_quiet ())
                 {
@@ -504,4 +509,5 @@
 		    endl;
                 }
+	      */
               CmtError::set (CmtError::package_not_found, use->get_package_name ());
             }
@@ -2473,4 +2479,12 @@
   if (!found)
     {
+      CmtMessage::warning ("package " + use->get_package_name ()
+			   + " " + use->version + " " + use->path
+			   + " not found"
+			   + ( (context_use != 0) ?
+			       " (requested by " + context_use->get_package_name () + ")" :
+			       "" )
+			   );
+      /*
       if (!Cmt::get_quiet ())
         {
@@ -2486,4 +2500,5 @@
 	  cerr << endl;
         }
+      */
 
       //CmtError::set (CmtError::package_not_found, use->get_package_name ());
@@ -3153,5 +3168,7 @@
       Symbol::expand (text);
 
-      if (!Cmt::get_quiet ()) cerr << "   Creating the reference file " << ref_file << endl;
+      if (CmtMessage::active (Info))
+	cerr << "   Creating the reference file " << ref_file << endl;
+	  //      if (!Cmt::get_quiet ()) cerr << "   Creating the reference file " << ref_file << endl;
       text.write (ref_file);
     }
@@ -3178,5 +3195,6 @@
 
   //if (!Cmt::get_quiet ()) 
-  cerr << "   Symlinking " << libname << " to " << s << endl;
+  if (CmtMessage::active (Info))
+    cerr << "   Symlinking " << libname << " to " << s << endl;
 
   if (symlinkcmd == "")
@@ -3184,5 +3202,6 @@
       if (!CmtSystem::create_symlink (libname, s))
 	{
-	  cerr << "#CMT> Cannot create a symbolic link to " << libname << endl;
+	  CmtMessage::error ("Cannot create a symbolic link to " + libname);
+	  //	  cerr << "#CMT> Cannot create a symbolic link to " << libname << endl;
 	  return (false);
 	}
@@ -3200,5 +3219,6 @@
       if (status != 0)
 	{
-	  cerr << "#CMT> Cannot create a symbolic link to " << libname << endl;
+	  CmtMessage::error ("Cannot create a symbolic link to " + libname);
+	  //	  cerr << "#CMT> Cannot create a symbolic link to " << libname << endl;
 	  return (false);
 	}
@@ -3219,4 +3239,8 @@
   if (!located ())
     {
+      CmtMessage::warning ("package " + get_package_name ()
+			   + " " + version + " " + path
+			   + " not found");
+      /*
       if (!Cmt::get_quiet ())
 	{
@@ -3226,4 +3250,5 @@
 	    endl;
 	}
+      */
       return;
     }
@@ -3494,5 +3519,6 @@
   if (use == 0)
     {
-      cerr << "#CMT> No access to " << to_name << endl;
+      CmtMessage::warning ("No access to " + to_name);
+      //      cerr << "#CMT> No access to " << to_name << endl;
       return (false);
     }
Index: /CMT/HEAD/src/Makefile.header
===================================================================
--- /CMT/HEAD/src/Makefile.header	(revision 458)
+++ /CMT/HEAD/src/Makefile.header	(revision 459)
@@ -51,7 +51,8 @@
 
 binclean ::
-	@if test ! "$(bin)" = "./"; then \
+	if test ! "$(bin)" = "./"; then \
 	  if test -d $(bin) ; then \
-	    echo "------> (Makefile.header) Cleaning all from $(bin)"; \
+	    test -z "$(cmtmsg)" || \
+	    echo "$(CMTMSGPREFIX)" "(Makefile.header) Cleaning all from $(bin)"; \
 	    /bin/rm -rf $(bin) ; \
 	  fi ; \
@@ -83,5 +84,5 @@
 	  /bin/rm -f $${temp_lock}; \
 	  echo "------> (Makefile.header) Rebuilding constituents.make"; \
-	  $(cmtexe) -quiet -tag=$(tags) build constituents_makefile -out=$${temp_constituents}; status=$$?; \
+	  $(cmtexe) -tag=$(tags) build constituents_makefile -out=$${temp_constituents}; status=$$?; \
 	  if test $${status} = 0; then \
 	    /bin/rm -f $(cmt_local_tagfile); \
@@ -100,5 +101,5 @@
 	$(echo) "(Makefile.header) Rebuilding $@"; \
 	  if test ! -d $(@D) ; then $(mkdir) -p $(@D); fi; \
-	  $(cmtexe) -quiet -tag=$(tags) build constituents_makefile -out=$@; \
+	  $(cmtexe) -tag=$(tags) build constituents_makefile -out=$@; \
 	  retval=$$?; \
 	  if test $${retval} != 0; then \
@@ -115,5 +116,5 @@
 	  if test -f $@; then rm -f $@; fi; \
 	  if test ! -d $(@D); then $(mkdir) -p $(@D); fi; \
-	  $(cmtexe) -quiet -tag=$(tags) build tag_makefile >$@
+	  $(cmtexe) -tag=$(tags) build tag_makefile >$@
 
 # 	  && /bin/echo $@ ok   
@@ -125,5 +126,5 @@
 #
 $(gmake_hosts) ::
-	rsh $@ "sh -c '(cd `$(cmtexe) show pwd -quiet`; . setup.sh; gmake $(MAKEFLAGS) $(target))'"
+	rsh $@ "sh -c '(cd `$(cmtexe) show pwd`; . setup.sh; gmake $(MAKEFLAGS) $(target))'"
 
 $(make_hosts) ::
@@ -146,10 +147,10 @@
 	@echo 'binclean    : fast erase of the binary directory'
 	@echo ' '
-	@groups=`$(cmtexe) show groups -quiet -tag=$(tags)`; \
+	@groups=`$(cmtexe) show groups -tag=$(tags)`; \
 	  for g in $${groups}; do \
 	    echo "$${g} : rebuild all constituents of group $${g}"; \
 	  done
 	@echo "Constituents:"; \
-	  for c in `$(cmtexe) show constituent_names -quiet -tag=$(tags)` ; do \
+	  for c in `$(cmtexe) show constituent_names -tag=$(tags)` ; do \
 	    echo "  $${c}  $${c}clean"; \
 	  done
Index: /CMT/HEAD/src/NMakefile.header
===================================================================
--- /CMT/HEAD/src/NMakefile.header	(revision 458)
+++ /CMT/HEAD/src/NMakefile.header	(revision 459)
@@ -55,5 +55,5 @@
 
 
-!if [$(cmtexe) -quiet build constituents_makefile -tag=$(tags)] == 0
+!if [$(cmtexe) build constituents_makefile -tag=$(tags)] == 0
 !endif
 
Index: /CMT/HEAD/src/constituents.make
===================================================================
--- /CMT/HEAD/src/constituents.make	(revision 458)
+++ /CMT/HEAD/src/constituents.make	(revision 459)
@@ -9,5 +9,5 @@
 #	@if test ! -f constituents.make -o "$(build_strategy)" = "rebuild_makefiles"; then \
 #	  echo "Rebuilding $@"; \
-#	  $(cmtexe) build constituents_makefile -quiet -tag=$(tags); \
+#	  $(cmtexe) build constituents_makefile -tag=$(tags); \
 #	fi
 #
Index: /CMT/HEAD/src/constituents.nmake
===================================================================
--- /CMT/HEAD/src/constituents.nmake	(revision 458)
+++ /CMT/HEAD/src/constituents.nmake	(revision 459)
@@ -6,7 +6,7 @@
 
 #
-#!if [echo $(cmtexe) -quiet build constituents_makefile -tag=$(tags)] == 0
+#!if [echo $(cmtexe) build constituents_makefile -tag=$(tags)] == 0
 #!endif
-#!if [$(cmtexe) -quiet build constituents_makefile -tag=$(tags)] == 0
+#!if [$(cmtexe) build constituents_makefile -tag=$(tags)] == 0
 #!endif
 #
