gcc/gcc/cp/Make-lang.in

279 lines
11 KiB
Plaintext
Raw Normal View History

# Top level -*- makefile -*- fragment for GNU C++.
# Copyright (C) 1994, 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
# Free Software Foundation, Inc.
1994-04-22 09:25:56 +02:00
#This file is part of GCC.
1994-04-22 09:25:56 +02:00
#GCC is free software; you can redistribute it and/or modify
1994-04-22 09:25:56 +02:00
#it under the terms of the GNU General Public License as published by
#the Free Software Foundation; either version 2, or (at your option)
#any later version.
#GCC is distributed in the hope that it will be useful,
1994-04-22 09:25:56 +02:00
#but WITHOUT ANY WARRANTY; without even the implied warranty of
#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
#GNU General Public License for more details.
#You should have received a copy of the GNU General Public License
#along with GCC; see the file COPYING. If not, write to
1995-06-15 23:06:59 +02:00
#the Free Software Foundation, 59 Temple Place - Suite 330,
#Boston, MA 02111-1307, USA.
1994-04-22 09:25:56 +02:00
# This file provides the language dependent support in the main Makefile.
# Each language makefile fragment must provide the following targets:
#
# foo.all.build, foo.all.cross, foo.start.encap, foo.rest.encap,
Makefile.in (install-info): Simplify. * Makefile.in (install-info): Simplify. ($(DESTDIR)$(infodir)/%.info): New rule. * configure.in (target_list): Remove install-info. * doc/.cvsignore (gcc.info*): Remove. (gccint.info*): Likewise. (gccinstall.info*): Likewise. (cpp.info*): Likewise. (cppinternals.info*): Likewise. (*.info*): Add it. * doc/sourcebuild.texi: Update description of install-info. * objc/Make-lang.in (objc.install-info): Remove. 2003-10-20 Mark Mitchell <mark@codesourcery.com> * Make-lang.in (ada.install-info): Remove target. (info): New target. (install-info): Likewise. (gnat_ug_unx.info): Simplify rule. (gnat_ug_vmx.info): Likewise. (gnat_ug_vxw.info): Likewise. (gnat_ug_wnt.info): Likewise. (gnat_rm.info): Likewise. (gnat-style.info): Likewise. 2003-10-20 Mark Mitchell <mark@codesourcery.com> * Make-lang.in (c++.install-info): Remove. Mon Oct 20 13:49:43 2003 Mark Mitchell <mark@codesourcery.com> * Make-lang.in (.PHONY): Remove f77.info, f77.install-info. (info): Update dependencies. ($(srcdir)/f/g77.info): Replace with ... ($(docobjdir)/g77.info): ... this. (f77.install-info): Remove. (install-info): New target. 2003-10-20 Mark Mitchell <mark@codesourcery.com> * Make-lang.in (info): Update dependencies. (java.install-info): Remove. ($(srcdir)/java/gcj.info): Replace with ... ($(docobjdir)/gcj.info): ... this. 2003-10-20 Mark Mitchell <mark@codesourcery.com> * Make-lang.in (info): Use docobjdir. ($(srcdir)/treelang/treelang.info): Replace with ... ($(docobjdir)/treelang/treelang.info): ... this. (install-info): New target. From-SVN: r72718
2003-10-20 22:58:26 +02:00
# foo.install-normal, foo.install-common, foo.install-man,
# foo.uninstall,
# foo.mostlyclean, foo.clean, foo.distclean,
# foo.maintainer-clean, foo.stage1, foo.stage2, foo.stage3, foo.stage4
1994-04-22 09:25:56 +02:00
#
# where `foo' is the name of the language.
#
# It should also provide rules for:
#
# - making any compiler driver (eg: g++)
# - the compiler proper (eg: cc1plus)
# - define the names for selecting the language in LANGUAGES.
# Actual names to use when installing a native compiler.
CXX_INSTALL_NAME := $(shell echo c++|sed '$(program_transform_name)')
GXX_INSTALL_NAME := $(shell echo g++|sed '$(program_transform_name)')
CXX_TARGET_INSTALL_NAME := $(target_noncanonical)-$(shell echo c++|sed '$(program_transform_name)')
GXX_TARGET_INSTALL_NAME := $(target_noncanonical)-$(shell echo g++|sed '$(program_transform_name)')
#
1994-04-22 09:25:56 +02:00
# Define the names for selecting c++ in LANGUAGES.
# Note that it would be nice to move the dependency on g++
# into the C++ rule, but that needs a little bit of work
# to do the right thing within all.cross.
C++ c++: cc1plus$(exeext)
1994-04-22 09:25:56 +02:00
# Tell GNU make to ignore these if they exist.
.PHONY: C++ c++
g++spec.o: $(srcdir)/cp/g++spec.c $(SYSTEM_H) coretypes.h $(TM_H) $(GCC_H) $(CONFIG_H)
(SHLIB_LINK='$(SHLIB_LINK)' \
SHLIB_MULTILIB='$(SHLIB_MULTILIB)'; \
$(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(DRIVER_DEFINES) \
$(INCLUDES) $(srcdir)/cp/g++spec.c)
1994-04-22 09:25:56 +02:00
# Create the compiler driver for g++.
GXX_OBJS = gcc.o g++spec.o intl.o prefix.o version.o
g++$(exeext): $(GXX_OBJS) $(EXTRA_GCC_OBJS) $(LIBDEPS)
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ \
$(GXX_OBJS) $(EXTRA_GCC_OBJS) $(LIBS)
1994-04-22 09:25:56 +02:00
# Create a version of the g++ driver which calls the cross-compiler.
g++-cross$(exeext): g++$(exeext)
-rm -f g++-cross$(exeext)
cp g++$(exeext) g++-cross$(exeext)
1994-04-22 09:25:56 +02:00
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
# The compiler itself.
# Shared with C front end:
CXX_C_OBJS = attribs.o c-common.o c-format.o c-pragma.o c-semantics.o c-lex.o \
Makefile.in (C_AND_OBJC_OBJS, [...]): Update. * Makefile.in (C_AND_OBJC_OBJS, c-incpath.o, c-lex.o, LIBCPP_OBJS, cppinit.o, cppdefault.o, fix-header): Update. * c-incpath.c: New file. * c-incpath.h: New file. * c-lex.c: Include c-incpath.h. (init_c_lex): Register path simplifier. * c-opts.c: Include cppdefault.h and c-incpath.h. (TARGET_SYSTEM_ROOT, verbose, iprefix, sysroot, std_inc, std_cxx_inc, quote_chain_split, add_prefixed_path): New. (COMMAND_LINE_OPTIONS): Add more options from cpplib. (missing_arg, c_common_decode_option): Handle them. (c_common_post_options): Register include chains. (print_help): Update. * cppdefault.h (struct default include): Update. Move some macros to ... * cppdefault.c: ... here. (cpp_include_defaults): Add extra field add_sysroot. * cppfiles.c (include_file, search_from, find_or_create_entry, cpp_included, find_include_file, remap_filename): Update for renaming of search_path to cpp_path, and of the chain headers. (remove_component_p, _cpp_simplify_pathname): Move to c-incpath.c. * cpphash.h (struct search_path): Move to cpplib.h. (struct cpp_buffer, struct cpp_reader): Update. (_cpp_simplify_pathname): Remove. * cppinit.c: Don't include prefix.h and cppdefault.h. (INO_T_EQ, INO_T_COPY, path_include, append_include_chain, remove_dup_dir, remove_dup_nonsys_dirs, remove_dup_dirs, init_standard_includes, BRACKET, SYSTEM, AFTER, no_dir, no_pth, cpp_handle_options): Remove. (struct pending_option): Remove chain members. (cpp_destroy, cpp_read_main_file, COMMAND_LINE_OPTIONS, cpp_handle_option): Update. * cpplib.h (struct cpp_path, cpp_set_include_chains): New. (struct cpp_options): Remove quote_include, bracket_include, include_prefix, include_prefix_len, verbose, ignore_srcdir, no_standard_includes, no_standard_cplusplus_includes. (struct cpp_callbacks): Add simplify_path. (cpp_handle_options): Remove. * fix-header.c: Include c-incpath.h. (read_scan_file): Update to use c-incpath functionality. * doc/passes.texi: Update. cp: * Make-lang.in (CXX_C_OBJS): Update. From-SVN: r63612
2003-03-01 15:31:21 +01:00
c-dump.o $(CXX_TARGET_OBJS) c-pretty-print.o c-opts.o c-pch.o \
c-incpath.o cppdefault.o c-ppoutput.o c-cppbuiltin.o prefix.o \
c-simplify.o tree-inline.o
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
# Language-specific object files.
top level: * errors.h (warning, error, fatal, internal_error): Don't mark with ATTRIBUTE_PRINTF_n. * toplev.h (internal_error, fatal_io_error, warning, error, pedwarn, pedwarn_with_file_and_line, warning_with_file_and_line, error_with_file_and_line, sorry, error_for_asm, warning_for_asm): Likewise. cp: * Make-lang.in (CXX_OBJS): Take out cp/errfn.o. (cp/errfn.o): Delete rule. (cp/error.o): Depend on flags.h. * errfn.c: Delete file. * cp-tree.h: Declare warn_deprecated. Remove definitions of TFF_NAMESPACE_SCOPE, TFF_CLASS_SCOPE, TFF_CHASE_NAMESPACE_ALIAS, and TFF_TEMPLATE_DEFAULT_ARGUMENTS. #define cp_error, cp_warning, cp_pedwarn, and cp_compiler_error to error, warning, pedwarn, and internal_error respectively. Make cp_deprecated into a macro. Don't define cp_printer typedef or declare cp_printers. * error.c: Include flags.h. Delete: struct tree_formatting_info, print_function_argument_list, print_declaration, print_expression, print_function_declaration, print_function_parameter, print_type_id, print_cv_qualifier_seq, print_type_specifier_seq, print_simple_type_specifier, print_elaborated_type_specifier, print_rest_of_abstract_declarator, print_parameter_declaration_clause, print_exception_specification, print_nested_name_specifier, and definition of cp_printers. (locate_error): New function. (cp_error_at, cp_warning_at, cp_pedwarn_at): Moved here and rewritten in terms of locate_error and diagnostic.c. (cp_tree_printer): Rename cp_printer; wire up to *_to_string instead of deleted print_* routines. Handle %C, %L, %O, %Q also. (init_error): Adjust to match. po: * POTFILES.in: Remove cp/errfn.c. From-SVN: r45765
2001-09-24 02:27:33 +02:00
CXX_OBJS = cp/call.o cp/decl.o cp/expr.o cp/pt.o cp/typeck2.o \
Make-lang.in (po-generated): Remove parse.c. * Make-lang.in (po-generated): Remove parse.c. (CXX_OBJS): Remove parse.o and spew.o. Add parser.o. ($(srcdir)/cp/parse.h): Remove target. ($(srcdir)/cp/parse.c): Likewise. (gt-cp-parse.h): Likewise. (gt-cp-parser.h): New target. (c++.distclean): Do not remove parse.output. (c++.maintainer-clean): Do not remove parse.c or parse.h. (cp/spew.o): Remove target. (cp/lex.o): Adjust dependencies. (cp/pt.o): Likewise. (cp/parse.o): Likewise. (cp/TAGS): Do not mention parse.c. (cp/parser.o): New target. * NEWS: Mention the new parser. * call.c (build_scoped_method_call): Simplify. (build_method_call): Likewise. (build_new_function_call): Adjust calls to add_function_candidate and add_template_candidate. (build_new_op): Improve handling of erroroneous operands. (convert_default_arg): Remove circular argument processing. (name_as_c_string): New function. (build_new_method_call): Use it. (perform_implicit_conversion): Use error_operand_p. * class.c (finish_struct_anon): Use constructor_name_p. (check_field_decls): Likewise. (pop_nested_class): Use OVL_NEXT, not OVL_CHAIN. (resolve_address_of_overloaded_function): Likewise. (instantiate_type): Tweak pointer-to-member handling. (get_primary_binfo): Remove incorrect assertion. * config-lang.in (gtfiles): Add parser.c, remove parse.c. * cp-tree.h (DEFARG_TOKENS): New macro. (default_arg): New structure. (cp_tree_node_structure_enum): Add TS_CP_DEFAULT_ARG. (lang_tree_node): Add default_arg. (cp_tree_index): Add CPTI_TYPE_INFO_REF_TYPE. (type_info_ref_type): New macro. (saved_scope): Make processing_explicit_instantiation a boolean. (check_access): New field. (unparsed_text): Remove. (language_function): Remove unparsed_inlines. (error_operand_p): New macro. (lang_decl): Adjust pending_inline_info. (DEFARG_POINTER): Remove. (tag_types): Add typenames. (lookup_ualified_name): Declare. (lookup_name_real): Likewise. (shadow_tag): Adjust prototype. (get_scope_of_declarator): Declare it. (process_next_inline): Remove it. (check_for_missing_semicolon): Likewise. (maybe_get_template_decl_from_type_decl): Declare it. (finish_label_stmt): Adjust prototype. (finish_non_static_data_meber): Declare it. (finish_pseudo_destructor_call_expr): Rename to ... (finish_pseudo_destructor_expr): ... this. (finish_compound_literal): Declare it. (begin_inline_definitions): Remove it. (init_spew): Remove. (peekyylex): Likewise. (arbitrate_lookup): Likewise. (frob_opname): Likewise. (maybe_snarf_defarg): Likewise. (add_defarg_fn): Likewise. (do_pending_defargs): Likewise. (done_pending_defargs): Likewise. (unprocessed_defarg_fn): Likewise. (replace_defarg): Likewise. (end_input): Likewise. (get_overloaded_fn): Likewise. * cvt.c (convert_to_reference): Improve error handling. * decl.c (lookup_name_real): Do not declare it static. (maybe_push_to_top_level): Set check_access. (identifier_type_value): Adjust call to lookup_name_real. (lookup_qualified_name): New method. (lookup_name_real): Remove special-case parsing code. (lookup_name-nonclass): Adjust call to lookup_name_real. (lookup_name_namespace_only): Likewise. (lookup_name): Likewise. (check_tag_decl): Return the type declared. (shadow_tag): Likewise. (register_dtor_fn): Tweak check_access. (grokfndecl): Use constructor_name_p. (get_scope_of_declarator): New function. (grokdeclarator): Obscure tweaks for slightly different declarator representations. (start_method): Return error_mark_node to indicate failure. (cp_tree_node_structure_enum): Use TS_CP_DEFAULT_ARG for DEFAULT_ARGs. * decl2.c (constructor_name_full): Simplify. (constructor_name): Use it. (build_expr_from_tree): Adjust for changes to do new parser. (push_scope): Improve robustness. (validate_nonmember_using_decl): Process declarations, not names. (do_class_using_decl): Likewise. (handle_class_head): Do not mess with CLASSTYPE_DECLARED_CLASS here. * error.c (dump_expr): Handle IDENTIFIER_NODEs and BASELINKs. * expr.c (cxx_expand_expr): Handle BASELINKs. * init.c (member_init_ok_or_else): Issue more errors. (build_offset_ref): Tweak handling of FUNCTION_DECLs. * lex.c: Do not include parse.h. (yypring): Do not declare. (yylval): Likewise. (make_reference_declarator): Remove error-generating code. (rid_to_yy): Remove. (cxx_init): Do not call init_spew. (yypring): Remove. (check_for_missing_semicolon): Remove. * lex.h (got_scope): Remove. (got_object): Remove. * method.c (hack_identifier): Use finish_non_static_data_member. (implicitly_declare_fn): Adjust use of constructor_name. * parser.c: New file. * pt.c (parse.h): Do not include it. (maybe_get_template_decl_from_template): Do not declare it. (finish_member_template_decl): Tweak. (begin_explicit_instantiation): Adjust for processing_explicit_instantiation being boolean. (end_explicit_instantiation): Likewise. (maybe_process_partial_specialization): Tighten specialization test. (retrieve_local_specialization): Adjust ue of hash table. (eq_local_specializations): New function. (register_local_specialization): Likewise. (push_template_decl_real): Remove unnecessary test. (maybe_get_template_decl_from_type_decl): Don't make it static. (for_each_template_parm_r): Handle TYPEOF_TYPE. (tsubst_copy): Use retrieive_local_specialization to handle PARM_DECL. Adjust handling of CONST_DECLs. Handle BASELINKs. Handle COMPONENT_REFs with pseudo-destructor-expressions. Simplify handling of CALL_EXPR and METHOD_CALL_EXPR. (tsubst_expr): Pass decls, not names, to do_local_using_decl. (unify): Tweak handling of CONST_DECLs. (regenerate_decl_from_template): Use push_nested_class. (template_for_substitution): New funciton. (instantiate_decl): Use it. Register parameters as local specializations. * rtti.c (init_rtti_processing): Set type_info_ref_type. (build_typeid): Use it. (get_typeid): Likeise. * search.c (accessible_p): Use check_access, not flag_access_control. (adjust_result_of_qualified_name_lookup): Pay attention to the context_class. * semantics.c (finish_asm_stmt): Adjust error handling. (finish_label_stmt): Return the statement. (finish_non_static_data_member): New function. (finish_class_expr): Handle BASELINKs. (finish_call_expr): Handle PSEUDO_DTOR_EXPR. (finish_object_call_expr): Simplify handling during templates. (finish_pseudo_destructor_call_expr): Rename to ... (finish_pseudo_dtor_expr): ... this. (finish_compound_literal): New function. (begin_inline_definitions): Remove. (finish_sizeof): Remove special template handling. * spew.c: Do not include parse.h. * tree.c (get_overloaded_fn): Remove. * typeck.c (build_class_member_access_expr): Handle PSEUDO_DTOR_EXPR. Adjust handling of static member functions. (lookup_destructor): New function. (finish_class_member_access_expr): Use it. (convert_arguments): Simplify. (build_unary_op): Handle BASELINKs. From-SVN: r60560
2002-12-28 09:03:42 +01:00
cp/class.o cp/decl2.o cp/error.o cp/lex.o cp/parser.o cp/ptree.o cp/rtti.o \
cp/typeck.o cp/cvt.o cp/except.o cp/friend.o cp/init.o cp/method.o \
pretty-print.h (pp_set_line_maximum_length): Make macro. * pretty-print.h (pp_set_line_maximum_length): Make macro. (pp_set_prefix): Likewise. (pp_destroy_prefix): Likewise. (pp_remaining_character_count_for_line): Likewise. (pp_clear_output_area): Likewise. (pp_formatted_text): Likewise. (pp_last_position_in_text): Likewise. (pp_emit_prefix): Likewise. (pp_append_text): Likewise. (pp_flush): Likewise. (pp_format_text): Likewise. (pp_format_verbatim): Likewise. (pp_tree_identifier): Tidy. * pretty-print.c (pp_base_format_text): Rename from pp_format_text. (pp_base_format_verbatim): Rename from pp_format_verbatim. (pp_base_flush): Rename from pp_flush. (pp_base_set_line_maximum_length): Rename from pp_set_line_maximum_length. (pp_base_clear_output_area): Rename from pp_clear_output_area. (pp_base_set_prefix): Rename from pp_set_prefix. (pp_base_destroy_prefix): Rename from pp_destroy_prefix. (pp_base_emit_prefix): Rename from pp_emit_prefix. (pp_base_append_text): Rename from pp_append_text. (pp_base_formatted_text): Rename from pp_formatted_text. (pp_base_last_position_in_text): Rename from pp_last_position_in_text. (pp_base_remaining_character_count_for_line): Rename from pp_remaining_character_count_for_line. * diagnostic.h (diagnostic_format_decoder): Tidy. (diagnostic_flush_buffer): Likewise. * c-pretty-print.h: (pp_c_string_literal): Declare. (pp_c_real_literal): Likewise. (pp_c_integer_literal): Likewise. * c-pretty-print.c (pp_c_char): Use pp_string in lieu of pp_identifier. (pp_c_character_literal): Tidy. (pp_c_string_literal): Make public. (pp_c_bool_literal): Likewise. (pp_c_integer_literal): Likewise. (pp_c_real_literal): Likewise. * Makefile.in (C_PRETTY_PRINT_H): New variable. (c-pretty-print.o): Update dependence. cp/ * cxx-pretty-print.h: New file. * cxx-pretty-print.c: Likewise. * error.c (scratch_pretty_printer): Change type. (init_error): Tidy. (dump_aggr_type): Likewise. (dump_global_iord): Likewise. (dump_expr): Likewise. (dump_char): Remove. * cp-lang.c (LANG_HOOKS_INITIALIZE_DIAGNOSTITCS): Define. (cxx_initialize_diagnostics): New function. * Make-lang.in (CXX_OBJS): Add cp/cxx-pretty-print.o (CXX_PRETTY_PRINT_H): New variable. (cp/cxx-pretty-print.o): New rule. (cp/cp-lang.o): Update dependence. (cp/error.o): Likewise. From-SVN: r70182
2003-08-05 21:23:14 +02:00
cp/search.o cp/semantics.o cp/tree.o cp/repo.o cp/dump.o cp/optimize.o \
cp/mangle.o cp/cp-lang.o cp/name-lookup.o cp/cxx-pretty-print.o \
cp/cp-simplify.o tree-mudflap.o cp/cp-mudflap.o
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
# Use strict warnings for this front end.
cp-warn = $(STRICT_WARN) $(WERROR)
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
cc1plus$(exeext): $(CXX_OBJS) $(CXX_C_OBJS) $(BACKEND) \
libcpp.a $(LIBDEPS)
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
$(CC) $(ALL_CFLAGS) $(LDFLAGS) -o $@ \
$(CXX_OBJS) $(CXX_C_OBJS) $(BACKEND) libcpp.a $(LIBS)
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
# Special build rules.
$(srcdir)/cp/cfns.h: $(srcdir)/cp/cfns.gperf
gperf -o -C -E -k '1-6,$$' -j1 -D -N 'libc_name_p' -L ANSI-C \
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
$(srcdir)/cp/cfns.gperf > $(srcdir)/cp/cfns.h
gtype-cp.h gt-cp-call.h gt-cp-decl.h gt-cp-decl2.h : s-gtype; @true
gt-cp-pt.h gt-cp-repo.h gt-cp-parser.h gt-cp-method.h : s-gtype; @true
gt-cp-tree.h gt-cp-mangle.h gt-cp-name-lookup.h: s-gtype; @true
#
1994-04-22 09:25:56 +02:00
# Build hooks:
c++.all.build: g++$(exeext)
c++.all.cross: g++-cross$(exeext)
c++.start.encap: g++$(exeext)
c++.rest.encap:
re PR other/12730 (manual page install broken with old Pod::man) gcc/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> PR bootstrap/12730 * configure.ac: Delete definition and subsitution of docdir. Add info, man, srcman and srcinfo to target hooks. Create doc/ directory. * configure: Regenerate. * Makefile.in: Don't substitute docdir and delete all references throughout. (MAKEINFOFLAGS): Define. (stmp-docobjdir): Delete. (INFOFILES, MANFILES): Define. (info): Call lang.info, srcinfo and lang.srcinfo. (generated-manpages): Call lang.man, srcman and lang.srcman. (srcinfo, srcman): New rules to copy back files to source directory. (doc/%.info, doc/%.dvi, doc/%.1, doc/%.7): New implict rule. (install-man): Revamp rule. (clean): Update dvi directory. (distclean): Delete TAGS from front end directorys. (maintainer-clean): Delete all document files in source directory. objc/Make-lang.in (objc.man, objc.info): Dummy entries. (objc.srcman, objc.srcinfo): Likewise. gcc/ada/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (doc/gnat_ug_unx.info, doc/gnat_ug_vwx.info, doc/gnat_ug_vms.info doc/gnat_ug_wnt.info, doc/gnat_rm.info, doc/gnat-style.info): Update to use consistent MAKEINFO rule. (ada.man, ada.srcman): Dummy entry. (ADA_INFOFILES): Define. (ada.info, ada.srcinfo): New rules. gcc/cp/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (c++.info, c++.srcinfo): Dummy entry. (c++.man, c++.srcman): New rules. (c++.install-man): Revamp rule. gcc/f/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (TEXI_G77_FILES): Define. (f77.rebuilt): Delete. (f77.srcextra): Add dependencies on f/BUGS and f/NEWS. (f77.srcman, f77.srcinfo, f77.man, f77.info): New rules. (doc/g77.info, doc/g77.dvi): Depend on TEXI_G77_FILES. Always build in doc directory. Use $(MAKEINFOFLAGS). (info, dvi, generated_manpages): Update to look in doc directory. (f/BUGS, f/NEWS): Generate in build directory. (f77.mostlyclean): Delete BUGS and NEWS from build directory. (f77.maintainer-clean): Adjust to delete from source directory. (f77.install-man): Revamp rule. gcc/java/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (java.info, java.srcinfo, java.man, java.srcman): New rules. (java.install-man): Revamp rule. gcc/treelang/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (treelang.info, treelang.srcinfo): New rules. (treelang.man, treelang.man): Dummy entries. maintainer-scripts/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * gcc_release (build_sources): Delete call to make f77.rebuilt. From-SVN: r76249
2004-01-21 03:01:55 +01:00
c++.info:
c++.srcinfo:
re PR bootstrap/12744 (A GCC release tarball can no longer be built without bison/flex) gcc/ 2004-01-15 Kelley Cook <kcook@gcc.gnu.org> PR bootstrap/12744 * configure.in: Revamp enable-generated-files-in-srcdir rule to define GENINSRC and not parsedir. Define srcextra as a langhook. * configure: Regenerate. * Makefile.in: Suppress default .l.c rule. Don't substitute parsedir and delete all references throughout. Conditionally define rule for srcextra dependent on GENINSRC. (stmp-docobjdir): Delete. (c-parse.o, gengtype-lex.o, gengtype-yacc.o): Use implicit build rule. (srcextra): Copy c-parse.y, c-parse.c, gengtype-lex.c, gengtype-yacc.c, and gengtype-yacc.h back to source directory. (maintainer-clean): Delete all parse files in source directory. (distclean): Delete generated files. * objc/Make-lang.in (objc-parse.o): Use implicit build rule. (objc-parse.c, objc-parse.y): Don't use parsedir. (objc.srcextra): Copy objc-parse.y and objc-parse.c back to source directory if requested. (po-generated): Don't use parsedir. (objc.maintainer-clean): Delete above files from source directory. gcc/ada/ 2004-01-15 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in (ada.srcextra): Dummy entry. gcc/cp/ 2004-01-15 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in (c++.srcextra): Dummy entry. gcc/f/ 2004-01-15 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in (f77.srcextra): Dummy entry. gcc/java/ 2004-01-15 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in (parse.c, parse-scan.c): Always build in doc directory. (java.srcextra): Copy above back to source directory if requested. (po-generated): Delete reference to $(parsedir). (java/parse.o, java/parse-scan.o): Delete reference to $(parsedir). Use implicit rule. gcc/treelang/ 2004-01-15 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in (TREE_GENERATED): Delete reference to $(parsedir). (treelang/parse.o, treelang/lex.o): Look for sources in build directory. Use implicit rule. (treelang/parse.c, treelang/parse.h treelang/lex.c): Always build in doc directory. (treelang.srcextra): Copy above back to source directory if requested. From-SVN: r75903
2004-01-15 05:02:24 +01:00
c++.srcextra:
1994-04-22 09:25:56 +02:00
c++.tags: force
cd $(srcdir)/cp; etags -o TAGS.sub *.c *.h --language=none \
--regex='/DEFTREECODE [(]\([A-Z_]+\)/\1/' cp-tree.def; \
etags --include TAGS.sub --include ../TAGS.sub
re PR other/12730 (manual page install broken with old Pod::man) gcc/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> PR bootstrap/12730 * configure.ac: Delete definition and subsitution of docdir. Add info, man, srcman and srcinfo to target hooks. Create doc/ directory. * configure: Regenerate. * Makefile.in: Don't substitute docdir and delete all references throughout. (MAKEINFOFLAGS): Define. (stmp-docobjdir): Delete. (INFOFILES, MANFILES): Define. (info): Call lang.info, srcinfo and lang.srcinfo. (generated-manpages): Call lang.man, srcman and lang.srcman. (srcinfo, srcman): New rules to copy back files to source directory. (doc/%.info, doc/%.dvi, doc/%.1, doc/%.7): New implict rule. (install-man): Revamp rule. (clean): Update dvi directory. (distclean): Delete TAGS from front end directorys. (maintainer-clean): Delete all document files in source directory. objc/Make-lang.in (objc.man, objc.info): Dummy entries. (objc.srcman, objc.srcinfo): Likewise. gcc/ada/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (doc/gnat_ug_unx.info, doc/gnat_ug_vwx.info, doc/gnat_ug_vms.info doc/gnat_ug_wnt.info, doc/gnat_rm.info, doc/gnat-style.info): Update to use consistent MAKEINFO rule. (ada.man, ada.srcman): Dummy entry. (ADA_INFOFILES): Define. (ada.info, ada.srcinfo): New rules. gcc/cp/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (c++.info, c++.srcinfo): Dummy entry. (c++.man, c++.srcman): New rules. (c++.install-man): Revamp rule. gcc/f/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (TEXI_G77_FILES): Define. (f77.rebuilt): Delete. (f77.srcextra): Add dependencies on f/BUGS and f/NEWS. (f77.srcman, f77.srcinfo, f77.man, f77.info): New rules. (doc/g77.info, doc/g77.dvi): Depend on TEXI_G77_FILES. Always build in doc directory. Use $(MAKEINFOFLAGS). (info, dvi, generated_manpages): Update to look in doc directory. (f/BUGS, f/NEWS): Generate in build directory. (f77.mostlyclean): Delete BUGS and NEWS from build directory. (f77.maintainer-clean): Adjust to delete from source directory. (f77.install-man): Revamp rule. gcc/java/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (java.info, java.srcinfo, java.man, java.srcman): New rules. (java.install-man): Revamp rule. gcc/treelang/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (treelang.info, treelang.srcinfo): New rules. (treelang.man, treelang.man): Dummy entries. maintainer-scripts/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * gcc_release (build_sources): Delete call to make f77.rebuilt. From-SVN: r76249
2004-01-21 03:01:55 +01:00
c++.man: doc/g++.1
c++.srcman: doc/g++.1
-cp -p $^ $(srcdir)/doc
check-c++ : check-g++
lang_checks += check-g++
#
1994-04-22 09:25:56 +02:00
# Install hooks:
# cc1plus is installed elsewhere as part of $(COMPILERS).
# Nothing to do here.
c++.install-normal:
# Install the driver program as $(target)-g++
# and also as either g++ (if native) or $(tooldir)/bin/g++.
c++.install-common: installdirs
-rm -f $(DESTDIR)$(bindir)/$(GXX_INSTALL_NAME)$(exeext)
-$(INSTALL_PROGRAM) g++$(exeext) $(DESTDIR)$(bindir)/$(GXX_INSTALL_NAME)$(exeext)
-chmod a+x $(DESTDIR)$(bindir)/$(GXX_INSTALL_NAME)$(exeext)
-rm -f $(DESTDIR)$(bindir)/$(CXX_INSTALL_NAME)$(exeext)
-( cd $(DESTDIR)$(bindir) && \
$(LN) $(GXX_INSTALL_NAME)$(exeext) $(CXX_INSTALL_NAME)$(exeext) )
-if [ -f cc1plus$(exeext) ] ; then \
if [ -f g++-cross$(exeext) ] ; then \
if [ -d $(DESTDIR)$(gcc_tooldir)/bin/. ] ; then \
rm -f $(DESTDIR)$(gcc_tooldir)/bin/g++$(exeext); \
$(INSTALL_PROGRAM) g++-cross$(exeext) $(DESTDIR)$(gcc_tooldir)/bin/g++$(exeext); \
rm -f $(DESTDIR)$(gcc_tooldir)/bin/c++$(exeext); \
( cd $(DESTDIR)$(gcc_tooldir)/bin && \
$(LN) g++$(exeext) c++$(exeext) ); \
else true; fi; \
1994-04-22 09:25:56 +02:00
else \
rm -f $(DESTDIR)$(bindir)/$(GXX_TARGET_INSTALL_NAME)$(exeext); \
( cd $(DESTDIR)$(bindir) && \
$(LN) $(GXX_INSTALL_NAME)$(exeext) $(GXX_TARGET_INSTALL_NAME)$(exeext) ); \
rm -f $(DESTDIR)$(bindir)/$(CXX_TARGET_INSTALL_NAME)$(exeext); \
( cd $(DESTDIR)$(bindir) && \
$(LN) $(CXX_INSTALL_NAME)$(exeext) $(CXX_TARGET_INSTALL_NAME)$(exeext) ); \
1994-04-22 09:25:56 +02:00
fi ; \
fi
# We can't use links because not everyone supports them, and we can't use
# .so because Irix 6.5 doesn't support them. So just copy the manpage.
re PR other/12730 (manual page install broken with old Pod::man) gcc/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> PR bootstrap/12730 * configure.ac: Delete definition and subsitution of docdir. Add info, man, srcman and srcinfo to target hooks. Create doc/ directory. * configure: Regenerate. * Makefile.in: Don't substitute docdir and delete all references throughout. (MAKEINFOFLAGS): Define. (stmp-docobjdir): Delete. (INFOFILES, MANFILES): Define. (info): Call lang.info, srcinfo and lang.srcinfo. (generated-manpages): Call lang.man, srcman and lang.srcman. (srcinfo, srcman): New rules to copy back files to source directory. (doc/%.info, doc/%.dvi, doc/%.1, doc/%.7): New implict rule. (install-man): Revamp rule. (clean): Update dvi directory. (distclean): Delete TAGS from front end directorys. (maintainer-clean): Delete all document files in source directory. objc/Make-lang.in (objc.man, objc.info): Dummy entries. (objc.srcman, objc.srcinfo): Likewise. gcc/ada/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (doc/gnat_ug_unx.info, doc/gnat_ug_vwx.info, doc/gnat_ug_vms.info doc/gnat_ug_wnt.info, doc/gnat_rm.info, doc/gnat-style.info): Update to use consistent MAKEINFO rule. (ada.man, ada.srcman): Dummy entry. (ADA_INFOFILES): Define. (ada.info, ada.srcinfo): New rules. gcc/cp/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (c++.info, c++.srcinfo): Dummy entry. (c++.man, c++.srcman): New rules. (c++.install-man): Revamp rule. gcc/f/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (TEXI_G77_FILES): Define. (f77.rebuilt): Delete. (f77.srcextra): Add dependencies on f/BUGS and f/NEWS. (f77.srcman, f77.srcinfo, f77.man, f77.info): New rules. (doc/g77.info, doc/g77.dvi): Depend on TEXI_G77_FILES. Always build in doc directory. Use $(MAKEINFOFLAGS). (info, dvi, generated_manpages): Update to look in doc directory. (f/BUGS, f/NEWS): Generate in build directory. (f77.mostlyclean): Delete BUGS and NEWS from build directory. (f77.maintainer-clean): Adjust to delete from source directory. (f77.install-man): Revamp rule. gcc/java/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (java.info, java.srcinfo, java.man, java.srcman): New rules. (java.install-man): Revamp rule. gcc/treelang/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (treelang.info, treelang.srcinfo): New rules. (treelang.man, treelang.man): Dummy entries. maintainer-scripts/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * gcc_release (build_sources): Delete call to make f77.rebuilt. From-SVN: r76249
2004-01-21 03:01:55 +01:00
doc/g++.1: doc/gcc.1
cp doc/gcc.1 doc/g++.1
re PR other/12730 (manual page install broken with old Pod::man) gcc/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> PR bootstrap/12730 * configure.ac: Delete definition and subsitution of docdir. Add info, man, srcman and srcinfo to target hooks. Create doc/ directory. * configure: Regenerate. * Makefile.in: Don't substitute docdir and delete all references throughout. (MAKEINFOFLAGS): Define. (stmp-docobjdir): Delete. (INFOFILES, MANFILES): Define. (info): Call lang.info, srcinfo and lang.srcinfo. (generated-manpages): Call lang.man, srcman and lang.srcman. (srcinfo, srcman): New rules to copy back files to source directory. (doc/%.info, doc/%.dvi, doc/%.1, doc/%.7): New implict rule. (install-man): Revamp rule. (clean): Update dvi directory. (distclean): Delete TAGS from front end directorys. (maintainer-clean): Delete all document files in source directory. objc/Make-lang.in (objc.man, objc.info): Dummy entries. (objc.srcman, objc.srcinfo): Likewise. gcc/ada/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (doc/gnat_ug_unx.info, doc/gnat_ug_vwx.info, doc/gnat_ug_vms.info doc/gnat_ug_wnt.info, doc/gnat_rm.info, doc/gnat-style.info): Update to use consistent MAKEINFO rule. (ada.man, ada.srcman): Dummy entry. (ADA_INFOFILES): Define. (ada.info, ada.srcinfo): New rules. gcc/cp/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (c++.info, c++.srcinfo): Dummy entry. (c++.man, c++.srcman): New rules. (c++.install-man): Revamp rule. gcc/f/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (TEXI_G77_FILES): Define. (f77.rebuilt): Delete. (f77.srcextra): Add dependencies on f/BUGS and f/NEWS. (f77.srcman, f77.srcinfo, f77.man, f77.info): New rules. (doc/g77.info, doc/g77.dvi): Depend on TEXI_G77_FILES. Always build in doc directory. Use $(MAKEINFOFLAGS). (info, dvi, generated_manpages): Update to look in doc directory. (f/BUGS, f/NEWS): Generate in build directory. (f77.mostlyclean): Delete BUGS and NEWS from build directory. (f77.maintainer-clean): Adjust to delete from source directory. (f77.install-man): Revamp rule. gcc/java/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (java.info, java.srcinfo, java.man, java.srcman): New rules. (java.install-man): Revamp rule. gcc/treelang/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (treelang.info, treelang.srcinfo): New rules. (treelang.man, treelang.man): Dummy entries. maintainer-scripts/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * gcc_release (build_sources): Delete call to make f77.rebuilt. From-SVN: r76249
2004-01-21 03:01:55 +01:00
c++.install-man: installdirs $(DESTDIR)$(man1dir)/$(GXX_INSTALL_NAME)$(man1ext)
$(DESTDIR)$(man1dir)/$(GXX_INSTALL_NAME)$(man1ext): doc/g++.1
-rm -f $@
-$(INSTALL_DATA) $< $@
-chmod a-x $@
1994-04-22 09:25:56 +02:00
c++.uninstall:
-rm -rf $(DESTDIR)$(bindir)/$(CXX_INSTALL_NAME)$(exeext)
-rm -rf $(DESTDIR)$(bindir)/$(GXX_INSTALL_NAME)$(exeext)
-rm -rf $(DESTDIR)$(man1dir)/$(GXX_INSTALL_NAME)$(man1ext)
#
1994-04-22 09:25:56 +02:00
# Clean hooks:
# A lot of the ancillary files are deleted by the main makefile.
# We just have to delete files specific to us.
c++.mostlyclean:
re PR other/12730 (manual page install broken with old Pod::man) gcc/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> PR bootstrap/12730 * configure.ac: Delete definition and subsitution of docdir. Add info, man, srcman and srcinfo to target hooks. Create doc/ directory. * configure: Regenerate. * Makefile.in: Don't substitute docdir and delete all references throughout. (MAKEINFOFLAGS): Define. (stmp-docobjdir): Delete. (INFOFILES, MANFILES): Define. (info): Call lang.info, srcinfo and lang.srcinfo. (generated-manpages): Call lang.man, srcman and lang.srcman. (srcinfo, srcman): New rules to copy back files to source directory. (doc/%.info, doc/%.dvi, doc/%.1, doc/%.7): New implict rule. (install-man): Revamp rule. (clean): Update dvi directory. (distclean): Delete TAGS from front end directorys. (maintainer-clean): Delete all document files in source directory. objc/Make-lang.in (objc.man, objc.info): Dummy entries. (objc.srcman, objc.srcinfo): Likewise. gcc/ada/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (doc/gnat_ug_unx.info, doc/gnat_ug_vwx.info, doc/gnat_ug_vms.info doc/gnat_ug_wnt.info, doc/gnat_rm.info, doc/gnat-style.info): Update to use consistent MAKEINFO rule. (ada.man, ada.srcman): Dummy entry. (ADA_INFOFILES): Define. (ada.info, ada.srcinfo): New rules. gcc/cp/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (c++.info, c++.srcinfo): Dummy entry. (c++.man, c++.srcman): New rules. (c++.install-man): Revamp rule. gcc/f/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (TEXI_G77_FILES): Define. (f77.rebuilt): Delete. (f77.srcextra): Add dependencies on f/BUGS and f/NEWS. (f77.srcman, f77.srcinfo, f77.man, f77.info): New rules. (doc/g77.info, doc/g77.dvi): Depend on TEXI_G77_FILES. Always build in doc directory. Use $(MAKEINFOFLAGS). (info, dvi, generated_manpages): Update to look in doc directory. (f/BUGS, f/NEWS): Generate in build directory. (f77.mostlyclean): Delete BUGS and NEWS from build directory. (f77.maintainer-clean): Adjust to delete from source directory. (f77.install-man): Revamp rule. gcc/java/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (java.info, java.srcinfo, java.man, java.srcman): New rules. (java.install-man): Revamp rule. gcc/treelang/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * Make-lang.in: Replace $(docdir) with doc. (treelang.info, treelang.srcinfo): New rules. (treelang.man, treelang.man): Dummy entries. maintainer-scripts/ 2004-01-20 Kelley Cook <kcook@gcc.gnu.org> * gcc_release (build_sources): Delete call to make f77.rebuilt. From-SVN: r76249
2004-01-21 03:01:55 +01:00
-rm -f doc/g++.1
-rm -f cp/*$(objext)
-rm -f cp/*$(coverageexts)
1994-04-22 09:25:56 +02:00
c++.clean:
c++.distclean:
-rm -f cp/config.status cp/Makefile
c++.maintainer-clean:
#
1994-04-22 09:25:56 +02:00
# Stage hooks:
# The main makefile has already created stage?/cp.
c++.stage1: stage1-start
-mv cp/*$(objext) stage1/cp
c++.stage2: stage2-start
-mv cp/*$(objext) stage2/cp
c++.stage3: stage3-start
-mv cp/*$(objext) stage3/cp
c++.stage4: stage4-start
-mv cp/*$(objext) stage4/cp
c++.stageprofile: stageprofile-start
-mv cp/*$(objext) stageprofile/cp
c++.stagefeedback: stagefeedback-start
-mv cp/*$(objext) stagefeedback/cp
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
#
# .o: .h dependencies.
CXX_TREE_H = $(TREE_H) cp/name-lookup.h cp/cp-tree.h c-common.h \
cp/cp-tree.def c-common.def \
function.h varray.h $(SYSTEM_H) coretypes.h $(CONFIG_H) $(TARGET_H) \
$(GGC_H) \
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
$(srcdir)/../include/hashtab.h $(srcdir)/../include/splay-tree.h
pretty-print.h (pp_set_line_maximum_length): Make macro. * pretty-print.h (pp_set_line_maximum_length): Make macro. (pp_set_prefix): Likewise. (pp_destroy_prefix): Likewise. (pp_remaining_character_count_for_line): Likewise. (pp_clear_output_area): Likewise. (pp_formatted_text): Likewise. (pp_last_position_in_text): Likewise. (pp_emit_prefix): Likewise. (pp_append_text): Likewise. (pp_flush): Likewise. (pp_format_text): Likewise. (pp_format_verbatim): Likewise. (pp_tree_identifier): Tidy. * pretty-print.c (pp_base_format_text): Rename from pp_format_text. (pp_base_format_verbatim): Rename from pp_format_verbatim. (pp_base_flush): Rename from pp_flush. (pp_base_set_line_maximum_length): Rename from pp_set_line_maximum_length. (pp_base_clear_output_area): Rename from pp_clear_output_area. (pp_base_set_prefix): Rename from pp_set_prefix. (pp_base_destroy_prefix): Rename from pp_destroy_prefix. (pp_base_emit_prefix): Rename from pp_emit_prefix. (pp_base_append_text): Rename from pp_append_text. (pp_base_formatted_text): Rename from pp_formatted_text. (pp_base_last_position_in_text): Rename from pp_last_position_in_text. (pp_base_remaining_character_count_for_line): Rename from pp_remaining_character_count_for_line. * diagnostic.h (diagnostic_format_decoder): Tidy. (diagnostic_flush_buffer): Likewise. * c-pretty-print.h: (pp_c_string_literal): Declare. (pp_c_real_literal): Likewise. (pp_c_integer_literal): Likewise. * c-pretty-print.c (pp_c_char): Use pp_string in lieu of pp_identifier. (pp_c_character_literal): Tidy. (pp_c_string_literal): Make public. (pp_c_bool_literal): Likewise. (pp_c_integer_literal): Likewise. (pp_c_real_literal): Likewise. * Makefile.in (C_PRETTY_PRINT_H): New variable. (c-pretty-print.o): Update dependence. cp/ * cxx-pretty-print.h: New file. * cxx-pretty-print.c: Likewise. * error.c (scratch_pretty_printer): Change type. (init_error): Tidy. (dump_aggr_type): Likewise. (dump_global_iord): Likewise. (dump_expr): Likewise. (dump_char): Remove. * cp-lang.c (LANG_HOOKS_INITIALIZE_DIAGNOSTITCS): Define. (cxx_initialize_diagnostics): New function. * Make-lang.in (CXX_OBJS): Add cp/cxx-pretty-print.o (CXX_PRETTY_PRINT_H): New variable. (cp/cxx-pretty-print.o): New rule. (cp/cp-lang.o): Update dependence. (cp/error.o): Likewise. From-SVN: r70182
2003-08-05 21:23:14 +02:00
CXX_PRETTY_PRINT_H = cp/cxx-pretty-print.h $(C_PRETTY_PRINT_H)
Make-lang.in (po-generated): Remove parse.c. * Make-lang.in (po-generated): Remove parse.c. (CXX_OBJS): Remove parse.o and spew.o. Add parser.o. ($(srcdir)/cp/parse.h): Remove target. ($(srcdir)/cp/parse.c): Likewise. (gt-cp-parse.h): Likewise. (gt-cp-parser.h): New target. (c++.distclean): Do not remove parse.output. (c++.maintainer-clean): Do not remove parse.c or parse.h. (cp/spew.o): Remove target. (cp/lex.o): Adjust dependencies. (cp/pt.o): Likewise. (cp/parse.o): Likewise. (cp/TAGS): Do not mention parse.c. (cp/parser.o): New target. * NEWS: Mention the new parser. * call.c (build_scoped_method_call): Simplify. (build_method_call): Likewise. (build_new_function_call): Adjust calls to add_function_candidate and add_template_candidate. (build_new_op): Improve handling of erroroneous operands. (convert_default_arg): Remove circular argument processing. (name_as_c_string): New function. (build_new_method_call): Use it. (perform_implicit_conversion): Use error_operand_p. * class.c (finish_struct_anon): Use constructor_name_p. (check_field_decls): Likewise. (pop_nested_class): Use OVL_NEXT, not OVL_CHAIN. (resolve_address_of_overloaded_function): Likewise. (instantiate_type): Tweak pointer-to-member handling. (get_primary_binfo): Remove incorrect assertion. * config-lang.in (gtfiles): Add parser.c, remove parse.c. * cp-tree.h (DEFARG_TOKENS): New macro. (default_arg): New structure. (cp_tree_node_structure_enum): Add TS_CP_DEFAULT_ARG. (lang_tree_node): Add default_arg. (cp_tree_index): Add CPTI_TYPE_INFO_REF_TYPE. (type_info_ref_type): New macro. (saved_scope): Make processing_explicit_instantiation a boolean. (check_access): New field. (unparsed_text): Remove. (language_function): Remove unparsed_inlines. (error_operand_p): New macro. (lang_decl): Adjust pending_inline_info. (DEFARG_POINTER): Remove. (tag_types): Add typenames. (lookup_ualified_name): Declare. (lookup_name_real): Likewise. (shadow_tag): Adjust prototype. (get_scope_of_declarator): Declare it. (process_next_inline): Remove it. (check_for_missing_semicolon): Likewise. (maybe_get_template_decl_from_type_decl): Declare it. (finish_label_stmt): Adjust prototype. (finish_non_static_data_meber): Declare it. (finish_pseudo_destructor_call_expr): Rename to ... (finish_pseudo_destructor_expr): ... this. (finish_compound_literal): Declare it. (begin_inline_definitions): Remove it. (init_spew): Remove. (peekyylex): Likewise. (arbitrate_lookup): Likewise. (frob_opname): Likewise. (maybe_snarf_defarg): Likewise. (add_defarg_fn): Likewise. (do_pending_defargs): Likewise. (done_pending_defargs): Likewise. (unprocessed_defarg_fn): Likewise. (replace_defarg): Likewise. (end_input): Likewise. (get_overloaded_fn): Likewise. * cvt.c (convert_to_reference): Improve error handling. * decl.c (lookup_name_real): Do not declare it static. (maybe_push_to_top_level): Set check_access. (identifier_type_value): Adjust call to lookup_name_real. (lookup_qualified_name): New method. (lookup_name_real): Remove special-case parsing code. (lookup_name-nonclass): Adjust call to lookup_name_real. (lookup_name_namespace_only): Likewise. (lookup_name): Likewise. (check_tag_decl): Return the type declared. (shadow_tag): Likewise. (register_dtor_fn): Tweak check_access. (grokfndecl): Use constructor_name_p. (get_scope_of_declarator): New function. (grokdeclarator): Obscure tweaks for slightly different declarator representations. (start_method): Return error_mark_node to indicate failure. (cp_tree_node_structure_enum): Use TS_CP_DEFAULT_ARG for DEFAULT_ARGs. * decl2.c (constructor_name_full): Simplify. (constructor_name): Use it. (build_expr_from_tree): Adjust for changes to do new parser. (push_scope): Improve robustness. (validate_nonmember_using_decl): Process declarations, not names. (do_class_using_decl): Likewise. (handle_class_head): Do not mess with CLASSTYPE_DECLARED_CLASS here. * error.c (dump_expr): Handle IDENTIFIER_NODEs and BASELINKs. * expr.c (cxx_expand_expr): Handle BASELINKs. * init.c (member_init_ok_or_else): Issue more errors. (build_offset_ref): Tweak handling of FUNCTION_DECLs. * lex.c: Do not include parse.h. (yypring): Do not declare. (yylval): Likewise. (make_reference_declarator): Remove error-generating code. (rid_to_yy): Remove. (cxx_init): Do not call init_spew. (yypring): Remove. (check_for_missing_semicolon): Remove. * lex.h (got_scope): Remove. (got_object): Remove. * method.c (hack_identifier): Use finish_non_static_data_member. (implicitly_declare_fn): Adjust use of constructor_name. * parser.c: New file. * pt.c (parse.h): Do not include it. (maybe_get_template_decl_from_template): Do not declare it. (finish_member_template_decl): Tweak. (begin_explicit_instantiation): Adjust for processing_explicit_instantiation being boolean. (end_explicit_instantiation): Likewise. (maybe_process_partial_specialization): Tighten specialization test. (retrieve_local_specialization): Adjust ue of hash table. (eq_local_specializations): New function. (register_local_specialization): Likewise. (push_template_decl_real): Remove unnecessary test. (maybe_get_template_decl_from_type_decl): Don't make it static. (for_each_template_parm_r): Handle TYPEOF_TYPE. (tsubst_copy): Use retrieive_local_specialization to handle PARM_DECL. Adjust handling of CONST_DECLs. Handle BASELINKs. Handle COMPONENT_REFs with pseudo-destructor-expressions. Simplify handling of CALL_EXPR and METHOD_CALL_EXPR. (tsubst_expr): Pass decls, not names, to do_local_using_decl. (unify): Tweak handling of CONST_DECLs. (regenerate_decl_from_template): Use push_nested_class. (template_for_substitution): New funciton. (instantiate_decl): Use it. Register parameters as local specializations. * rtti.c (init_rtti_processing): Set type_info_ref_type. (build_typeid): Use it. (get_typeid): Likeise. * search.c (accessible_p): Use check_access, not flag_access_control. (adjust_result_of_qualified_name_lookup): Pay attention to the context_class. * semantics.c (finish_asm_stmt): Adjust error handling. (finish_label_stmt): Return the statement. (finish_non_static_data_member): New function. (finish_class_expr): Handle BASELINKs. (finish_call_expr): Handle PSEUDO_DTOR_EXPR. (finish_object_call_expr): Simplify handling during templates. (finish_pseudo_destructor_call_expr): Rename to ... (finish_pseudo_dtor_expr): ... this. (finish_compound_literal): New function. (begin_inline_definitions): Remove. (finish_sizeof): Remove special template handling. * spew.c: Do not include parse.h. * tree.c (get_overloaded_fn): Remove. * typeck.c (build_class_member_access_expr): Handle PSEUDO_DTOR_EXPR. Adjust handling of static member functions. (lookup_destructor): New function. (finish_class_member_access_expr): Use it. (convert_arguments): Simplify. (build_unary_op): Handle BASELINKs. From-SVN: r60560
2002-12-28 09:03:42 +01:00
cp/lex.o: cp/lex.c $(CXX_TREE_H) $(TM_H) flags.h cp/lex.h \
2003-06-30 21:36:25 +02:00
c-pragma.h toplev.h output.h input.h cp/operators.def $(TM_P_H)
cp/cp-lang.o: cp/cp-lang.c $(CXX_TREE_H) $(TM_H) toplev.h langhooks.h \
pretty-print.h (pp_set_line_maximum_length): Make macro. * pretty-print.h (pp_set_line_maximum_length): Make macro. (pp_set_prefix): Likewise. (pp_destroy_prefix): Likewise. (pp_remaining_character_count_for_line): Likewise. (pp_clear_output_area): Likewise. (pp_formatted_text): Likewise. (pp_last_position_in_text): Likewise. (pp_emit_prefix): Likewise. (pp_append_text): Likewise. (pp_flush): Likewise. (pp_format_text): Likewise. (pp_format_verbatim): Likewise. (pp_tree_identifier): Tidy. * pretty-print.c (pp_base_format_text): Rename from pp_format_text. (pp_base_format_verbatim): Rename from pp_format_verbatim. (pp_base_flush): Rename from pp_flush. (pp_base_set_line_maximum_length): Rename from pp_set_line_maximum_length. (pp_base_clear_output_area): Rename from pp_clear_output_area. (pp_base_set_prefix): Rename from pp_set_prefix. (pp_base_destroy_prefix): Rename from pp_destroy_prefix. (pp_base_emit_prefix): Rename from pp_emit_prefix. (pp_base_append_text): Rename from pp_append_text. (pp_base_formatted_text): Rename from pp_formatted_text. (pp_base_last_position_in_text): Rename from pp_last_position_in_text. (pp_base_remaining_character_count_for_line): Rename from pp_remaining_character_count_for_line. * diagnostic.h (diagnostic_format_decoder): Tidy. (diagnostic_flush_buffer): Likewise. * c-pretty-print.h: (pp_c_string_literal): Declare. (pp_c_real_literal): Likewise. (pp_c_integer_literal): Likewise. * c-pretty-print.c (pp_c_char): Use pp_string in lieu of pp_identifier. (pp_c_character_literal): Tidy. (pp_c_string_literal): Make public. (pp_c_bool_literal): Likewise. (pp_c_integer_literal): Likewise. (pp_c_real_literal): Likewise. * Makefile.in (C_PRETTY_PRINT_H): New variable. (c-pretty-print.o): Update dependence. cp/ * cxx-pretty-print.h: New file. * cxx-pretty-print.c: Likewise. * error.c (scratch_pretty_printer): Change type. (init_error): Tidy. (dump_aggr_type): Likewise. (dump_global_iord): Likewise. (dump_expr): Likewise. (dump_char): Remove. * cp-lang.c (LANG_HOOKS_INITIALIZE_DIAGNOSTITCS): Define. (cxx_initialize_diagnostics): New function. * Make-lang.in (CXX_OBJS): Add cp/cxx-pretty-print.o (CXX_PRETTY_PRINT_H): New variable. (cp/cxx-pretty-print.o): New rule. (cp/cp-lang.o): Update dependence. (cp/error.o): Likewise. From-SVN: r70182
2003-08-05 21:23:14 +02:00
$(LANGHOOKS_DEF_H) c-common.h $(CXX_PRETTY_PRINT_H) $(DIAGNOSTIC_H)
cp/decl.o: cp/decl.c $(CXX_TREE_H) $(TM_H) flags.h cp/lex.h cp/decl.h stack.h \
output.h $(EXPR_H) except.h toplev.h $(HASHTAB_H) $(RTL_H) \
cp/operators.def $(TM_P_H) tree-inline.h diagnostic.h c-pragma.h \
debug.h gt-cp-decl.h gtype-cp.h timevar.h $(TREE_FLOW_H)
cp/decl2.o: cp/decl2.c $(CXX_TREE_H) $(TM_H) flags.h cp/lex.h cp/decl.h $(EXPR_H) \
output.h except.h toplev.h $(RTL_H) c-common.h gt-cp-decl2.h cgraph.h
cp/typeck2.o: cp/typeck2.c $(CXX_TREE_H) $(TM_H) flags.h toplev.h output.h $(TM_P_H) \
Makefile.in (c-parse.o): Depend on diagnostic.h gcc/ 2001-06-10 Mark Mitchell <mark@codesourcery.com> Gabriel Dos Reis <gdr@codesourcery.com> * Makefile.in (c-parse.o): Depend on diagnostic.h (dwarf2out.o): Likewise. * dwarf2out.c: #include diagnostic.h * toplev.h (warningcount, errorcount, sorrycount): Remove declarations. * toplev.c (warningcount, errorcount, sorrycount): Remove definitions. * diagnostic.h (struct output_buffer): Reorder fields. (diagnostic_kind_count): New macro. (errorcount, warningcount, sorrycount): Define as macros. (diagnostic_report_warnings_p): New macro. (output_state): Add diagnostic_count field. * diagnostic.c (warningcount, errorcount, inhibit_warnings): Remove tentative declaration. (count_error): Use diagnostic_report_warnings_p. * c-parse.in: #include diagnostic.h ch/ 2001-06-10 Gabriel Dos Reis <gdr@codesourcery.com> * decl.c: #include diagnostic.h * actions.c: #include diagnostic.h * Makefile.in (actions.o): Depend on diagnostic.h (decl.o): Depend on diagnostic.h cp/ 2001-06-10 Mark Mitchell <mark@codesourcery.com> Gabriel Dos Reis <gdr@codesourcery.com> * Make-lang.in (cp/call.o): Depend on diagnostic.h (cp/typeck.o): Depend on diagnostic.h (cp/typeck2.o): Depend on diagnostic.h (cp/repo.o): Depend on dignostic.h * typeck.c: #include diagnostic.h (convert_for_initialization): Remove extern declaration for warningcount and errorcount. * call.c: #include diagnostic.h (convert_like_real): Remove extern declaration for warnincount and errorcount. * repo.c: #include diagnostic.h * typeck2.c: #include diagnostic.h From-SVN: r43140
2001-06-10 15:48:04 +02:00
diagnostic.h
cp/typeck.o: cp/typeck.c $(CXX_TREE_H) $(TM_H) flags.h $(RTL_H) $(EXPR_H) toplev.h \
diagnostic.h convert.h
cp/class.o: cp/class.c $(CXX_TREE_H) $(TM_H) flags.h toplev.h $(RTL_H) $(TARGET_H) convert.h
cp/call.o: cp/call.c $(CXX_TREE_H) $(TM_H) flags.h toplev.h $(RTL_H) $(EXPR_H) \
diagnostic.h intl.h gt-cp-call.h convert.h target.h
cp/friend.o: cp/friend.c $(CXX_TREE_H) $(TM_H) flags.h $(RTL_H) toplev.h $(EXPR_H)
cp/init.o: cp/init.c $(CXX_TREE_H) $(TM_H) flags.h $(RTL_H) $(EXPR_H) toplev.h \
except.h
cp/method.o: cp/method.c $(CXX_TREE_H) $(TM_H) toplev.h $(RTL_H) $(EXPR_H) \
$(TM_P_H) $(TARGET_H) gt-cp-method.h
cp/cvt.o: cp/cvt.c $(CXX_TREE_H) $(TM_H) cp/decl.h flags.h toplev.h convert.h
cp/search.o: cp/search.c $(CXX_TREE_H) $(TM_H) stack.h flags.h toplev.h $(RTL_H)
cp/tree.o: cp/tree.c $(CXX_TREE_H) $(TM_H) flags.h toplev.h $(RTL_H) \
insn-config.h integrate.h tree-inline.h real.h gt-cp-tree.h $(TARGET_H)
cp/ptree.o: cp/ptree.c $(CXX_TREE_H) $(TM_H)
cp/rtti.o: cp/rtti.c $(CXX_TREE_H) $(TM_H) flags.h toplev.h convert.h
cp/except.o: cp/except.c $(CXX_TREE_H) $(TM_H) flags.h $(RTL_H) except.h toplev.h \
cp/cfns.h $(EXPR_H) libfuncs.h tree-inline.h
cp/expr.o: cp/expr.c $(CXX_TREE_H) $(TM_H) $(RTL_H) flags.h $(EXPR_H) toplev.h \
configure.in: Prune nonexistent files from build_xm_file, xm_file, and host_xm_file lists. * configure.in: Prune nonexistent files from build_xm_file, xm_file, and host_xm_file lists. Warn unless they're $cpu/xm-$cpu.h. Don't generate *config.h here. AC_SUBST all variables needed to generate *config.h. * configure: Regenerate. * mkconfig.sh: New helper script, from code removed from configure.in. * Makefile.in: Zap all MALLOC variables - no longer used anywhere, and malloc.c doesn't exist. Substitute in variables needed to generate *config.h. Stop lying about the dependencies contained in CONFIG_H and GCONFIG_H. (HCONFIG_H, TCONFIG_H, TM_P_H): New variables. (config.h, hconfig.h, tconfig.h, tm_p.h, cs-config.h, cs-hconfig.h, cs-tconfig.h, cs-tm_p.h): New rules. (all .o): Add dependencies on $(HCONFIG_H), $(TCONFIG_H), $(TM_P_H), etc. as appropriate. * config.gcc: Zap references to deleted files. * ggc-none.c: Don't include rtl.h or tm_p.h. * config/i386/xm-beos.h, config/i386/xm-dgux.h, config/i386/xm-djgpp.h, config/i386/xm-dos.h, config/i386/xm-gnu.h, config/i386/xm-i386-interix.h, config/i386/xm-linux.h, config/i386/xm-linux.h, config/i386/xm-next.h, config/i386/xm-openbsd.h, config/i386/xm-sun.h, config/i386/xm-sysv3.h: Don't include i386/xm-i386.h. * config/elxsi/xm-elxsi.h, config/i386/xm-bsd386.h, config/i386/xm-i386.h, config/i860/xm-i860.h, config/i960/xm-i960.h, config/mcore/xm-mcore.h, config/mn10300/xm-mn10300.h, config/ns32k/xm-ns32k.h, config/pj/xm-pj.h, config/sh/xm-sh.h, config/v850/xm-v850.h: Delete (empty except comments, #includes of other deleted files, and macros used nowhere). cp: * Make-lang.in: Add dependencies on $(TM_P_H) as appropriate. From-SVN: r40350
2001-03-09 21:53:56 +01:00
except.h $(TM_P_H)
Make-lang.in (po-generated): Remove parse.c. * Make-lang.in (po-generated): Remove parse.c. (CXX_OBJS): Remove parse.o and spew.o. Add parser.o. ($(srcdir)/cp/parse.h): Remove target. ($(srcdir)/cp/parse.c): Likewise. (gt-cp-parse.h): Likewise. (gt-cp-parser.h): New target. (c++.distclean): Do not remove parse.output. (c++.maintainer-clean): Do not remove parse.c or parse.h. (cp/spew.o): Remove target. (cp/lex.o): Adjust dependencies. (cp/pt.o): Likewise. (cp/parse.o): Likewise. (cp/TAGS): Do not mention parse.c. (cp/parser.o): New target. * NEWS: Mention the new parser. * call.c (build_scoped_method_call): Simplify. (build_method_call): Likewise. (build_new_function_call): Adjust calls to add_function_candidate and add_template_candidate. (build_new_op): Improve handling of erroroneous operands. (convert_default_arg): Remove circular argument processing. (name_as_c_string): New function. (build_new_method_call): Use it. (perform_implicit_conversion): Use error_operand_p. * class.c (finish_struct_anon): Use constructor_name_p. (check_field_decls): Likewise. (pop_nested_class): Use OVL_NEXT, not OVL_CHAIN. (resolve_address_of_overloaded_function): Likewise. (instantiate_type): Tweak pointer-to-member handling. (get_primary_binfo): Remove incorrect assertion. * config-lang.in (gtfiles): Add parser.c, remove parse.c. * cp-tree.h (DEFARG_TOKENS): New macro. (default_arg): New structure. (cp_tree_node_structure_enum): Add TS_CP_DEFAULT_ARG. (lang_tree_node): Add default_arg. (cp_tree_index): Add CPTI_TYPE_INFO_REF_TYPE. (type_info_ref_type): New macro. (saved_scope): Make processing_explicit_instantiation a boolean. (check_access): New field. (unparsed_text): Remove. (language_function): Remove unparsed_inlines. (error_operand_p): New macro. (lang_decl): Adjust pending_inline_info. (DEFARG_POINTER): Remove. (tag_types): Add typenames. (lookup_ualified_name): Declare. (lookup_name_real): Likewise. (shadow_tag): Adjust prototype. (get_scope_of_declarator): Declare it. (process_next_inline): Remove it. (check_for_missing_semicolon): Likewise. (maybe_get_template_decl_from_type_decl): Declare it. (finish_label_stmt): Adjust prototype. (finish_non_static_data_meber): Declare it. (finish_pseudo_destructor_call_expr): Rename to ... (finish_pseudo_destructor_expr): ... this. (finish_compound_literal): Declare it. (begin_inline_definitions): Remove it. (init_spew): Remove. (peekyylex): Likewise. (arbitrate_lookup): Likewise. (frob_opname): Likewise. (maybe_snarf_defarg): Likewise. (add_defarg_fn): Likewise. (do_pending_defargs): Likewise. (done_pending_defargs): Likewise. (unprocessed_defarg_fn): Likewise. (replace_defarg): Likewise. (end_input): Likewise. (get_overloaded_fn): Likewise. * cvt.c (convert_to_reference): Improve error handling. * decl.c (lookup_name_real): Do not declare it static. (maybe_push_to_top_level): Set check_access. (identifier_type_value): Adjust call to lookup_name_real. (lookup_qualified_name): New method. (lookup_name_real): Remove special-case parsing code. (lookup_name-nonclass): Adjust call to lookup_name_real. (lookup_name_namespace_only): Likewise. (lookup_name): Likewise. (check_tag_decl): Return the type declared. (shadow_tag): Likewise. (register_dtor_fn): Tweak check_access. (grokfndecl): Use constructor_name_p. (get_scope_of_declarator): New function. (grokdeclarator): Obscure tweaks for slightly different declarator representations. (start_method): Return error_mark_node to indicate failure. (cp_tree_node_structure_enum): Use TS_CP_DEFAULT_ARG for DEFAULT_ARGs. * decl2.c (constructor_name_full): Simplify. (constructor_name): Use it. (build_expr_from_tree): Adjust for changes to do new parser. (push_scope): Improve robustness. (validate_nonmember_using_decl): Process declarations, not names. (do_class_using_decl): Likewise. (handle_class_head): Do not mess with CLASSTYPE_DECLARED_CLASS here. * error.c (dump_expr): Handle IDENTIFIER_NODEs and BASELINKs. * expr.c (cxx_expand_expr): Handle BASELINKs. * init.c (member_init_ok_or_else): Issue more errors. (build_offset_ref): Tweak handling of FUNCTION_DECLs. * lex.c: Do not include parse.h. (yypring): Do not declare. (yylval): Likewise. (make_reference_declarator): Remove error-generating code. (rid_to_yy): Remove. (cxx_init): Do not call init_spew. (yypring): Remove. (check_for_missing_semicolon): Remove. * lex.h (got_scope): Remove. (got_object): Remove. * method.c (hack_identifier): Use finish_non_static_data_member. (implicitly_declare_fn): Adjust use of constructor_name. * parser.c: New file. * pt.c (parse.h): Do not include it. (maybe_get_template_decl_from_template): Do not declare it. (finish_member_template_decl): Tweak. (begin_explicit_instantiation): Adjust for processing_explicit_instantiation being boolean. (end_explicit_instantiation): Likewise. (maybe_process_partial_specialization): Tighten specialization test. (retrieve_local_specialization): Adjust ue of hash table. (eq_local_specializations): New function. (register_local_specialization): Likewise. (push_template_decl_real): Remove unnecessary test. (maybe_get_template_decl_from_type_decl): Don't make it static. (for_each_template_parm_r): Handle TYPEOF_TYPE. (tsubst_copy): Use retrieive_local_specialization to handle PARM_DECL. Adjust handling of CONST_DECLs. Handle BASELINKs. Handle COMPONENT_REFs with pseudo-destructor-expressions. Simplify handling of CALL_EXPR and METHOD_CALL_EXPR. (tsubst_expr): Pass decls, not names, to do_local_using_decl. (unify): Tweak handling of CONST_DECLs. (regenerate_decl_from_template): Use push_nested_class. (template_for_substitution): New funciton. (instantiate_decl): Use it. Register parameters as local specializations. * rtti.c (init_rtti_processing): Set type_info_ref_type. (build_typeid): Use it. (get_typeid): Likeise. * search.c (accessible_p): Use check_access, not flag_access_control. (adjust_result_of_qualified_name_lookup): Pay attention to the context_class. * semantics.c (finish_asm_stmt): Adjust error handling. (finish_label_stmt): Return the statement. (finish_non_static_data_member): New function. (finish_class_expr): Handle BASELINKs. (finish_call_expr): Handle PSEUDO_DTOR_EXPR. (finish_object_call_expr): Simplify handling during templates. (finish_pseudo_destructor_call_expr): Rename to ... (finish_pseudo_dtor_expr): ... this. (finish_compound_literal): New function. (begin_inline_definitions): Remove. (finish_sizeof): Remove special template handling. * spew.c: Do not include parse.h. * tree.c (get_overloaded_fn): Remove. * typeck.c (build_class_member_access_expr): Handle PSEUDO_DTOR_EXPR. Adjust handling of static member functions. (lookup_destructor): New function. (finish_class_member_access_expr): Use it. (convert_arguments): Simplify. (build_unary_op): Handle BASELINKs. From-SVN: r60560
2002-12-28 09:03:42 +01:00
cp/pt.o: cp/pt.c $(CXX_TREE_H) $(TM_H) cp/decl.h cp/lex.h \
toplev.h $(RTL_H) except.h tree-inline.h gt-cp-pt.h
Remove pedwarn_with_decl, warning_with_decl and error_with_decl from GCC. Remove pedwarn_with_decl, warning_with_decl and error_with_decl from GCC. * calls.c (try_to_integrate): Don't use xxx_with_decl. (expand_call): Likewise. * dwarfout.c (output_reg_number): Likewise. * expr.c (expand_expr): Likewise. * function.c (assign_temp): Likewise. (uninitialized_vars_warning): Likewise. (setjmp_args_warning): Likewise. (expand_function_end): Likewise. * stmt.c (fixup_gotos): Likewise. (warn_about_unused_variables): Likewise. (expand_end_bindings): Likewise. * stor-layout.c (layout_decl): Likewise. (place_field): Likewise. * toplev.c (check_global_declarations): Likewise. (rest_of_handle_inlining): Likewise. (default_tree_printer): New function. (general_init): Initialize diagnostic machinery before routing signals to the ICE machinery. Set default tree printer. * toplev.h (pedwarn_with_decl): Remove declaration. (warning_with_decl): Likewise. (error_with_decl): Likewise. (pedwarn): Remove attribute for the time being. * tree-inline.c (expand_call_inline): Don't use xxx_with_decl. * varasm.c (named_section): Likewise. (make_decl_rtl): Likewise. (assemble_variable): Likewise. (merge_weak): Likewise. (declare_weak): Likewise. * diagnostic.h: Move non-diagnostic stuff into pretty-print.h. * diagnostic.c: Move non-diagnostic stuff into pretty-print.c. (format_with_decl): Remove. (diagnostic_for_decl): Likewise. (pedwarn_with_decl): Likewise. (warning_with_decl): Likewise. (error_with_decl): Likewise. (diagnostic_initialize): Adjust. (diagnostic_count_diagnostic): Likewise. (announce_function): Likewise. (lhd_print_error_function): Likewise. (diagnostic_report_current_module): Likewise. (default_diagnostic_starter): Likewise. (diagnostic_report_diagnostic): Likewise. (default_diagnostic_finalizer): Likewise. (verbatim): Likewise. (error): Likewise. (warning): Likewise. * opts.c (common_handle_option): Likewise. * pretty-print.c: New file. * c-pretty-print.h (pp_base): Override. * c-pretty-print.c: Adjust use of macros throughout. (pp_buffer): New macro. (pp_newline): Likewise. * c-objc-common.c (c_tree_printer): Adjust prototype. Tidy. * Makefile.in (DIAGNOSTIC_H): New variable. (c-errors.o): Use it. (c-objc-common.o): Likewise. (c-common.o): Likewise. (c-opts.o): Likewise. (c-format.o): Likewise. (diagnostic.o): Likewise. (opts.o): Likewise. (toplev.o): Likewise. (rtl-error.o): Likewise. (dwarf2out.o): Likewise. (jump.o): Likewise. (pretty-print.o): New rule. cp/ * Make-lang.in (cp/error.o): Depend on DIAGNOSTIC_H. * error.c: Use the new pretty-printer fraamework. From-SVN: r69773
2003-07-25 11:52:32 +02:00
cp/error.o: cp/error.c $(CXX_TREE_H) $(TM_H) toplev.h $(DIAGNOSTIC_H) \
pretty-print.h (pp_set_line_maximum_length): Make macro. * pretty-print.h (pp_set_line_maximum_length): Make macro. (pp_set_prefix): Likewise. (pp_destroy_prefix): Likewise. (pp_remaining_character_count_for_line): Likewise. (pp_clear_output_area): Likewise. (pp_formatted_text): Likewise. (pp_last_position_in_text): Likewise. (pp_emit_prefix): Likewise. (pp_append_text): Likewise. (pp_flush): Likewise. (pp_format_text): Likewise. (pp_format_verbatim): Likewise. (pp_tree_identifier): Tidy. * pretty-print.c (pp_base_format_text): Rename from pp_format_text. (pp_base_format_verbatim): Rename from pp_format_verbatim. (pp_base_flush): Rename from pp_flush. (pp_base_set_line_maximum_length): Rename from pp_set_line_maximum_length. (pp_base_clear_output_area): Rename from pp_clear_output_area. (pp_base_set_prefix): Rename from pp_set_prefix. (pp_base_destroy_prefix): Rename from pp_destroy_prefix. (pp_base_emit_prefix): Rename from pp_emit_prefix. (pp_base_append_text): Rename from pp_append_text. (pp_base_formatted_text): Rename from pp_formatted_text. (pp_base_last_position_in_text): Rename from pp_last_position_in_text. (pp_base_remaining_character_count_for_line): Rename from pp_remaining_character_count_for_line. * diagnostic.h (diagnostic_format_decoder): Tidy. (diagnostic_flush_buffer): Likewise. * c-pretty-print.h: (pp_c_string_literal): Declare. (pp_c_real_literal): Likewise. (pp_c_integer_literal): Likewise. * c-pretty-print.c (pp_c_char): Use pp_string in lieu of pp_identifier. (pp_c_character_literal): Tidy. (pp_c_string_literal): Make public. (pp_c_bool_literal): Likewise. (pp_c_integer_literal): Likewise. (pp_c_real_literal): Likewise. * Makefile.in (C_PRETTY_PRINT_H): New variable. (c-pretty-print.o): Update dependence. cp/ * cxx-pretty-print.h: New file. * cxx-pretty-print.c: Likewise. * error.c (scratch_pretty_printer): Change type. (init_error): Tidy. (dump_aggr_type): Likewise. (dump_global_iord): Likewise. (dump_expr): Likewise. (dump_char): Remove. * cp-lang.c (LANG_HOOKS_INITIALIZE_DIAGNOSTITCS): Define. (cxx_initialize_diagnostics): New function. * Make-lang.in (CXX_OBJS): Add cp/cxx-pretty-print.o (CXX_PRETTY_PRINT_H): New variable. (cp/cxx-pretty-print.o): New rule. (cp/cp-lang.o): Update dependence. (cp/error.o): Likewise. From-SVN: r70182
2003-08-05 21:23:14 +02:00
flags.h real.h $(LANGHOOKS_DEF_H) $(CXX_PRETTY_PRINT_H)
cp/repo.o: cp/repo.c $(CXX_TREE_H) $(TM_H) toplev.h diagnostic.h \
gt-cp-repo.h
cp/semantics.o: cp/semantics.c $(CXX_TREE_H) $(TM_H) cp/lex.h except.h toplev.h \
flags.h debug.h output.h $(RTL_H) $(TIMEVAR_H) $(EXPR_H) \
tree-inline.h cgraph.h
cp/dump.o: cp/dump.c $(CXX_TREE_H) $(TM_H) tree-dump.h
cp/optimize.o: cp/optimize.c $(CXX_TREE_H) $(TM_H) rtl.h integrate.h insn-config.h \
input.h $(PARAMS_H) debug.h tree-inline.h tree-simple.h
cp/mangle.o: cp/mangle.c $(CXX_TREE_H) $(TM_H) toplev.h real.h gt-cp-mangle.h \
$(TARGET_H) $(TM_P_H)
configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. * configure.in: If not NO_MINUS_C_MINUS_O, substitute OUTPUT_OPTION with '-o $@'. Make zlibdir, zlibinc relative to top level. Kill oldstyle_subdirs. Do not include $srcdir/$s/Makefile.in in all_lang_makefiles, but do include $outputs. Do not run configure.lang from config.status. Rearrange warning-flag logic to correspond to what the makefile wants. Put special vax stage1 options in @stage1_flags@ not @stage1_warn_cflags@. Don't do anything with extra_c_objs, extra_cxx_objs, or extra_cpp_objs. (--enable-c-cpplib): AC_SUBST(maybe_cpplib) with "libcpp.a" if switch is given, nothing otherwise. * configure.lang: Delete. * Makefile.in: Expunge all traces of extra_c_objs, extra_cxx_objs, and extra_cpp_objs. Set MAYBE_CPPLIB from @maybe_cpplib@. Add $(MAYBE_CPPLIB) to C_AND_OBJC_OBJS. Set warning options via a three level scheme so that -pedantic and -Wtraditional are not used for non-C front ends: LOOSE_WARN, STRICT1_WARN, STRICT2_WARN -> $(@D)-warn, GCC_WARN_CFLAGS -> WARN_CFLAGS. Distinguish STAGE1_CFLAGS from BOOT_CFLAGS. Add -I$(@D) and -I$(srcdir)/$(@D) to INCLUDES. Set OUTPUT_OPTION, ZLIB, ZLIBINC. Do not set P, LANG_FLAGS_TO_PASS. Add OUTPUT_OPTION to all object-file generation rules. Wrap all rules that change the current directory in parentheses; pmake doesn't spawn a new shell for each command. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add libgcc_s$(SHLIB_EXT) to files deleted on make clean. Force OUTPUT_OPTION='-o $@' in stage2 and beyond. * cp/Make-lang.in, f/Make-lang.in, java/Make-lang.in, objc/Make-lang.in: Wrap all rules that change the current directory in parentheses. Expunge all references to $(P). When one command depends on another and they're run all at once, use && to separate them, not ;. Add OUTPUT_OPTION to all object-file generation rules. Delete obsolete variables. Move all build rules here from the corresponding Makefile.in and adapt to the new environment. * cp/Makefile.in, f/Makefile.in, java/Makefile.in, objc/Makefile.in: Delete. * cp/config-lang.in, f/config-lang.in, java/config-lang.in: Delete outputs= line. From-SVN: r37088
2000-10-27 22:22:28 +02:00
Makefile.in (dwarf2out.o): Depend on input.h 2004-01-27 Devang Patel <dpatel@apple.com> * Makefile.in (dwarf2out.o): Depend on input.h * dbxout.c (dbx_debug_hooks): Add new empty hook for imported_module_or_decl. (xcoff_debug_hooks): Same. * sdbout.c (sdb_debug_hooks): Same. * vmsdbgout.c (vmsdbg_debug_hooks): Same. * debug.c (do_nothing_debug_hooks): Same. (debug_nothing_tree_tree): New function. * debug.h (gcc_debug_hooks): New hook, imported_module_or_decl. * dwarf2out.c: Include input.h. (dwarf2_debug_hooks): Add new hook for imported_module_or_decl. (remove_child_TAG): New function. (dwarf_tag_name): Handle DW_TAG_imported_module. (gen_subprogram_die): Equate decl number to declaration die. Do not remove all children dies while reusing declaration die for definition. Instead, selectively remove only formal parameters. (gen_variable_die): Equate variable decl to declaration die. (gen_field_die): Equate field decl to line number. (force_namespace_die): Replace it with ... (force_decl_die): ... this. (force_type_die): New function. (setup_namespace_context): Replace use of force_namespace_die() with force_decl_die(). (gen_namespace_die): Same. (dwarf2out_imported_module_or_decl): New function. testsuite: * g++.dg/debug/namespace1.C: New test. cp: * name-lookup.c: Include "debug.h" (do_namespace_alias): Invoke debug_hooks to emit debug info for namespace alias. (do_local_using_decl): Invoke debug_hooks to emit debug info for using decl. (do_class_using_decl): Same. (do_toplevel_using_decl): Same. (do_using_directive): Same. (cp_emit_debug_info_for_using): New function. * Make-lang.in (cp/parser.o): Depend on debug.h (cp/name-lookup.o): Same. From-SVN: r76746
2004-01-27 21:36:02 +01:00
cp/parser.o: cp/parser.c $(CXX_TREE_H) $(TM_H) diagnostic.h gt-cp-parser.h \
output.h
cp/cp-simplify.o: cp/cp-simplify.c $(CXX_TREE_H) toplev.h c-common.h \
$(TM_H) coretypes.h
cp/cp-mudflap.o: cp/cp-mudflap.c $(CXX_TREE_H) toplev.h c-common.h \
$(TM_H) coretypes.h
cp/name-lookup.o: cp/name-lookup.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
Break out decl.c (2/n) Break out decl.c (2/n) * name-lookup.c: Include diagnostic.h (cxx_binding_free): Make static. (cxx_binding_make): Likewise. (binding_table_new): Likewise (binding_table_free): Likewise. (binding_table_insert): Likewise. (binding_table_find_anon_type): Likewise. (binding_table_reverse_maybe_remap): Likewise. (supplement_binding): Likewise. * name-lookup.h (global_scope_name): Declare extern. (global_type_node): Likewise. (cxx_binding_free): Don't export. (cxx_binding_make): Likewise. (binding_table_new): Likewise. (binding_table_free): Likewise. (binding_table_insert): Likewise. (binding_table_find_anon_type): Likewise. (binding_table_reverse_maybe_remap): Likewise. * Make-lang.in (cp/name-lookup.o): Depend on $(DIAGNOSTIC_H) * decl.c (lookup_namespace_name): Move to name-lookup.c (select_decl): Likewise. (unqualified_namespace_lookup): Likewise. (lookup_qualified_name): Likewise. (lookup_name_real): Likewise. (lookup_name_nonclass): Likewise. (lookup_function_nonclass): Likewise. (lookup_name): Likewise. (lookup_name_current_level): Likewise. (lookup_type_current_level): Likewise. (lookup_flags): Likewise. (qualify_lookup): Likewise. (lookup_tag): Likewise. (lookup_tag_reverse): Likewise. (getdecls): Likewise. (storedecls): Remove. (cxx_remember_type_decls): Likewise. (global_bindings_p): Likewise. (innermost_nonclass_level): Likewise. (toplevel_bindings_p): Likewise. (namespace_bindings_p): Likewise. (kept_level_p): Likewise. (innermost_scope_kind): Likewise. (template_parm_scope_p): Likewise. (push_binding): Likewise. (push_local_binding): Likewise. (add_decl_to_level): Likewise. Make extern. (push_class_binding): Move to name-lookup.c. (resume_level): Likewise. Rename to resume_scope. (begin_scope): Likewise. (indent): Likewise. (binding_depth): Likewise. (is_class_level): Likewise. (cxx_scope_descriptor): Likewise. (cxx_scope_debug): Likewise. (namespace_scope_ht_size): Likewise. (leave_scope): Likewise. (pushlevel_class): Likewise. (poplevel_class): Likewise. (clear_identifier_class_values): Likewise. (pushdecl_with_scope): Likewise. (pushdecl_namespace_level): Likewise. (pushdecl_class_level): Likewise. (push_class_level_binding): Likewise. (push_using_directive): Likewise. (identifier_global_value): Likewise. (keep_next_level_flag): Likewise. (keep_next_level): Likewise. (free_binding_level): Likewise. (set_class_shadows): Likewise. (maybe_push_cleanup_level): Likewise. (cp_namespace_decls): Likewise. (bt_print_entry): Likewise. (print_binding_level): Likewise. (print_other_binding_stack): Likewise. (print_binding_stack): Likewise. (push_namespace): Likewise. (pop_namespace): Likewise. (push_nested_namespace): Likewise. (pop_nested_namespace): Likewise. (cxx_saved_binding_make): Likewise. (struct cxx_saved_binding_make): Likewise. (store_bindings): Likewise. (maybe_push_to_top_level): Likewise. (push_to_top_level): Likewise. (pop_from_top_level): Likewise. (identifier_type_value): Likewise. (set_identifier_type_value): Likewise. (set_identifier_type_value_with_scope): Likewise. (pop_everything): Likewise. (pushtag): Likewise. (follow_tag_typedef): Likewise. (maybe_process_template_type_declaration): Likewise. (pop_binding): Likewise. * cp-tree.h: Move corresponding declarations to name-lookup.h From-SVN: r72426
2003-10-13 12:26:36 +02:00
$(TM_H) $(CXX_TREE_H) timevar.h gt-cp-name-lookup.h toplev.h \
Makefile.in (dwarf2out.o): Depend on input.h 2004-01-27 Devang Patel <dpatel@apple.com> * Makefile.in (dwarf2out.o): Depend on input.h * dbxout.c (dbx_debug_hooks): Add new empty hook for imported_module_or_decl. (xcoff_debug_hooks): Same. * sdbout.c (sdb_debug_hooks): Same. * vmsdbgout.c (vmsdbg_debug_hooks): Same. * debug.c (do_nothing_debug_hooks): Same. (debug_nothing_tree_tree): New function. * debug.h (gcc_debug_hooks): New hook, imported_module_or_decl. * dwarf2out.c: Include input.h. (dwarf2_debug_hooks): Add new hook for imported_module_or_decl. (remove_child_TAG): New function. (dwarf_tag_name): Handle DW_TAG_imported_module. (gen_subprogram_die): Equate decl number to declaration die. Do not remove all children dies while reusing declaration die for definition. Instead, selectively remove only formal parameters. (gen_variable_die): Equate variable decl to declaration die. (gen_field_die): Equate field decl to line number. (force_namespace_die): Replace it with ... (force_decl_die): ... this. (force_type_die): New function. (setup_namespace_context): Replace use of force_namespace_die() with force_decl_die(). (gen_namespace_die): Same. (dwarf2out_imported_module_or_decl): New function. testsuite: * g++.dg/debug/namespace1.C: New test. cp: * name-lookup.c: Include "debug.h" (do_namespace_alias): Invoke debug_hooks to emit debug info for namespace alias. (do_local_using_decl): Invoke debug_hooks to emit debug info for using decl. (do_class_using_decl): Same. (do_toplevel_using_decl): Same. (do_using_directive): Same. (cp_emit_debug_info_for_using): New function. * Make-lang.in (cp/parser.o): Depend on debug.h (cp/name-lookup.o): Same. From-SVN: r76746
2004-01-27 21:36:02 +01:00
$(DIAGNOSTIC_H) flags.h debug.h
pretty-print.h (pp_set_line_maximum_length): Make macro. * pretty-print.h (pp_set_line_maximum_length): Make macro. (pp_set_prefix): Likewise. (pp_destroy_prefix): Likewise. (pp_remaining_character_count_for_line): Likewise. (pp_clear_output_area): Likewise. (pp_formatted_text): Likewise. (pp_last_position_in_text): Likewise. (pp_emit_prefix): Likewise. (pp_append_text): Likewise. (pp_flush): Likewise. (pp_format_text): Likewise. (pp_format_verbatim): Likewise. (pp_tree_identifier): Tidy. * pretty-print.c (pp_base_format_text): Rename from pp_format_text. (pp_base_format_verbatim): Rename from pp_format_verbatim. (pp_base_flush): Rename from pp_flush. (pp_base_set_line_maximum_length): Rename from pp_set_line_maximum_length. (pp_base_clear_output_area): Rename from pp_clear_output_area. (pp_base_set_prefix): Rename from pp_set_prefix. (pp_base_destroy_prefix): Rename from pp_destroy_prefix. (pp_base_emit_prefix): Rename from pp_emit_prefix. (pp_base_append_text): Rename from pp_append_text. (pp_base_formatted_text): Rename from pp_formatted_text. (pp_base_last_position_in_text): Rename from pp_last_position_in_text. (pp_base_remaining_character_count_for_line): Rename from pp_remaining_character_count_for_line. * diagnostic.h (diagnostic_format_decoder): Tidy. (diagnostic_flush_buffer): Likewise. * c-pretty-print.h: (pp_c_string_literal): Declare. (pp_c_real_literal): Likewise. (pp_c_integer_literal): Likewise. * c-pretty-print.c (pp_c_char): Use pp_string in lieu of pp_identifier. (pp_c_character_literal): Tidy. (pp_c_string_literal): Make public. (pp_c_bool_literal): Likewise. (pp_c_integer_literal): Likewise. (pp_c_real_literal): Likewise. * Makefile.in (C_PRETTY_PRINT_H): New variable. (c-pretty-print.o): Update dependence. cp/ * cxx-pretty-print.h: New file. * cxx-pretty-print.c: Likewise. * error.c (scratch_pretty_printer): Change type. (init_error): Tidy. (dump_aggr_type): Likewise. (dump_global_iord): Likewise. (dump_expr): Likewise. (dump_char): Remove. * cp-lang.c (LANG_HOOKS_INITIALIZE_DIAGNOSTITCS): Define. (cxx_initialize_diagnostics): New function. * Make-lang.in (CXX_OBJS): Add cp/cxx-pretty-print.o (CXX_PRETTY_PRINT_H): New variable. (cp/cxx-pretty-print.o): New rule. (cp/cp-lang.o): Update dependence. (cp/error.o): Likewise. From-SVN: r70182
2003-08-05 21:23:14 +02:00
cp/cxx-pretty-print.o: cp/cxx-pretty-print.c $(CXX_PRETTY_PRINT_H) \
$(CONFIG_H) $(SYSTEM_H) $(TM_H) coretypes.h $(CXX_TREE_H)