From acce4e77382b198a70f1044724bda19b01997657 Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Wed, 6 Apr 2011 12:08:17 +0100 Subject: tm.texi.in: Document C target hooks as separate from general target hooks. * doc/tm.texi.in: Document C target hooks as separate from general target hooks. * doc/tm.texi: Regenerate. * genhooks.c (struct hook_desc): Add docname field. (HOOK_VECTOR_1, DEFHOOKPOD, DEFHOOK, DEFHOOK_UNDOC). Initialize docname field. (hook_array): Include c-target.def. (emit_documentation): Use docname field in output. (emit_init_macros): Take docname argument. Only emit definitions for hooks matching docname. (main): Expect additional arguments in all cases. Pass argument to emit_init_macros. * target.def: Move initial macro definitions and comments to target-hooks-macros.h. (gcc_targetcm): Move to c-family/c-target.def. * target.h (targetcm): Move declaration to c-family/c-target.h. * targhooks.c (default_handle_c_option): Move to c-family/c-opts.c. * targhooks.h (default_handle_c_option): Move declaration to c-family/c-common.h. * target-hooks-macros.h: New file. * config.gcc (target_has_targetcm): Define and use to add to c_target_objs and cxx_target_objs. * config/default-c.c: New file. * config/darwin-c.c: Include c-target.h and c-target-def.h instead of target.h and target-def.h. (TARGET_HANDLE_C_OPTION, targetcm): Define later in file. (darwin_objc_construct_string, darwin_cfstring_ref_p, darwin_check_cfstring_format_arg): Make static. (TARGET_OBJC_CONSTRUCT_STRING_OBJECT, TARGET_STRING_OBJECT_REF_TYPE_P, TARGET_CHECK_STRING_OBJECT_FORMAT_ARG): Define here. * config/darwin-protos.h (darwin_objc_construct_string, darwin_cfstring_ref_p, darwin_check_cfstring_format_arg): Don't declare. * config/darwin.h (TARGET_OBJC_CONSTRUCT_STRING_OBJECT, TARGET_STRING_OBJECT_REF_TYPE_P, TARGET_CHECK_STRING_OBJECT_FORMAT_ARG, TARGET_HAS_TARGETCM): Remove. * config/t-darwin (darwin-c.o): Update dependencies. * system.h (TARGET_HAS_TARGETCM): Poison. * Makefile.in (TARGET_H): Update. (TARGET_DEF, C_TARGET_DEF, C_TARGET_H, C_TARGET_DEF_H): Define. (c-family/c-format.o, c-family/c-opts.o): Update dependencies. (default-c.o): New target. (s-target-hooks-def-h): Pass "Target Hook" string to genhooks. (c-family/c-target-hooks-def.h, s-c-target-hooks-def-h): New targets. (s-tm-texi): Pass -d option to genhooks. Also test timestamp on c-target.def. (build/genhooks.o): Update dependencies. c-family: * c-target-def.h: New file. * c-target.def: New file. * c-target.h: New file. * c-common.c (targetcm): Don't define here. * c-common.h (default_handle_c_option): Declare. * c-format.c: Include c-target.h instead of target.h. * c-opts.c: Include c-target.h instead of target.h. Explicitly include tm.h. (default_handle_c_option): Move from targhooks.c. objc: * objc-act.c: Include c-target.h instead of target.h. * Make-lang.in (objc/objc-act.o): Update dependencies. From-SVN: r172035 --- gcc/objc/ChangeLog | 5 +++++ gcc/objc/Make-lang.in | 3 ++- gcc/objc/objc-act.c | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) (limited to 'gcc/objc') diff --git a/gcc/objc/ChangeLog b/gcc/objc/ChangeLog index 5194347..5e0d5ab 100644 --- a/gcc/objc/ChangeLog +++ b/gcc/objc/ChangeLog @@ -1,3 +1,8 @@ +2011-04-06 Joseph Myers + + * objc-act.c: Include c-target.h instead of target.h. + * Make-lang.in (objc/objc-act.o): Update dependencies. + 2011-03-06 Joseph Myers * lang-specs.h: Match -save-temps* instead of -save-temps. diff --git a/gcc/objc/Make-lang.in b/gcc/objc/Make-lang.in index 6544bcc..182ebf4 100644 --- a/gcc/objc/Make-lang.in +++ b/gcc/objc/Make-lang.in @@ -98,7 +98,8 @@ objc/objc-next-runtime-abi-02.o: objc/objc-next-runtime-abi-02.c $(START_HDRS) \ objc/objc-act.o : objc/objc-act.c $(START_HDRS) $(GGC_H) \ $(DIAGNOSTIC_CORE_H) toplev.h $(FLAGS_H) input.h $(FUNCTION_H) output.h debug.h \ $(LANGHOOKS_DEF_H) $(HASHTAB_H) $(C_PRAGMA_H) gt-objc-objc-act.h $(OBSTACK_H) \ - $(GIMPLE_H) objc/objc-runtime-shared-support.h objc/objc-runtime-hooks.h + $(GIMPLE_H) objc/objc-runtime-shared-support.h objc/objc-runtime-hooks.h \ + $(C_TARGET_H) objc.srcextra: diff --git a/gcc/objc/objc-act.c b/gcc/objc/objc-act.c index 4511435..26a5aa9 100644 --- a/gcc/objc/objc-act.c +++ b/gcc/objc/objc-act.c @@ -46,7 +46,7 @@ along with GCC; see the file COPYING3. If not see #include "toplev.h" #include "ggc.h" #include "debug.h" -#include "target.h" +#include "c-family/c-target.h" #include "diagnostic-core.h" #include "intl.h" #include "cgraph.h" -- cgit v1.1