This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] strict types in code generators.



On 2005-03-02, at 15:16, Marcin Dalecki wrote:
However
you are right the extern stuff isn't strictly required and I can't reproduce any error
without it.



Actually the above is wrong, because I didn't notice that the mudflap source code setup
bug came first.
Here is the fall-out of compiling without the extern declaration. As one would
expect C++ simply doesn't give global scope to the functions in question:


c++ -O2 -fsigned-char -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -fno-common -DHAVE_CONFIG_H -o cc1 \
c-lang.o stub-objc.o attribs.o c-errors.o c-lex.o c-pragma.o c-decl.o c-
typeck.o c-convert.o c-aux-info.o c-common.o c-opts.o c-format.o c-semantics.o c
-incpath.o cppdefault.o c-ppoutput.o c-cppbuiltin.o prefix.o c-objc-common.o c-d
ump.o c-pch.o c-parser.o darwin-c.o rs6000-c.o c-gimplify.o tree-mudflap.o c-pre
tty-print.o main.o tree-browser.o libbackend.a ../libcpp/libcpp.a ../libcpp/libc
pp.a ./../intl/libintl.a -liconv ../libiberty/libiberty.a
ld: warning multiple definitions of symbol _vfprintf
../libiberty/libiberty.a(vfprintf.o) definition of _vfprintf in section (__TEXT,
__text)
/usr/lib/libSystem.dylib(vfprintf.So) definition of _vfprintf
ld: warning multiple definitions of symbol _strncmp
../libiberty/libiberty.a(strncmp.o) definition of _strncmp in section (__TEXT,__
text)
/usr/lib/libSystem.dylib(strncmp.So) definition of _strncmp
ld: warning multiple definitions of symbol _locale_charset
./../intl/libintl.a(localcharset.o) definition of _locale_charset in section (__
TEXT,__text)
/usr/lib/libiconv.dylib(localcharset.o) definition of _locale_charset
ld: Undefined symbols:
_gt_ggc_r_gt_alias_h
_gt_ggc_r_gt_c_common_h
_gt_ggc_r_gt_c_decl_h
_gt_ggc_r_gt_c_parser_h
_gt_ggc_r_gt_c_pragma_h
_gt_ggc_r_gt_cfglayout_h
_gt_ggc_r_gt_cgraph_h
_gt_ggc_r_gt_coverage_h
_gt_ggc_r_gt_cselib_h
_gt_ggc_r_gt_darwin_h
_gt_ggc_r_gt_dbxout_h
_gt_ggc_r_gt_dojump_h
_gt_ggc_r_gt_dwarf2asm_h
_gt_ggc_r_gt_dwarf2out_h
_gt_ggc_r_gt_emit_rtl_h
_gt_ggc_r_gt_except_h
_gt_ggc_r_gt_explow_h
_gt_ggc_r_gt_expr_h
_gt_ggc_r_gt_function_h
_gt_ggc_r_gt_gcse_h
_gt_ggc_r_gt_gimplify_h
_gt_ggc_r_gt_optabs_h
_gt_ggc_r_gt_reg_stack_h
_gt_ggc_r_gt_regclass_h
_gt_ggc_r_gt_rs6000_h
_gt_ggc_r_gt_sdbout_h
_gt_ggc_r_gt_stor_layout_h
_gt_ggc_r_gt_stringpool_h
_gt_ggc_r_gt_tree_cfg_h
_gt_ggc_r_gt_tree_complex_h
_gt_ggc_r_gt_tree_eh_h
_gt_ggc_r_gt_tree_h
_gt_ggc_r_gt_tree_nested_h
_gt_ggc_r_gt_tree_ssa_operands_h
_gt_ggc_r_gt_tree_ssa_propagate_h
_gt_ggc_r_gt_tree_ssanames_h
_gt_ggc_r_gt_varasm_h
_gt_ggc_r_gtype_desc_c
_gt_ggc_rc_gt_emit_rtl_h
_gt_ggc_rc_gt_tree_h
_gt_ggc_rd_gt_alias_h
_gt_ggc_rd_gt_bitmap_h
_gt_ggc_rd_gt_c_decl_h
_gt_ggc_rd_gt_emit_rtl_h
_gt_ggc_rd_gt_lists_h
_gt_ggc_rd_gt_tree_iterator_h
_gt_ggc_rd_gt_tree_phinodes_h
_gt_pch_rc_gt_emit_rtl_h
_gt_pch_rc_gt_tree_h
_gt_pch_rs_gt_alias_h
_gt_pch_rs_gt_c_common_h
_gt_pch_rs_gt_c_decl_h
_gt_pch_rs_gt_darwin_h
_gt_pch_rs_gt_dbxout_h
_gt_pch_rs_gt_dwarf2asm_h
_gt_pch_rs_gt_dwarf2out_h
_gt_pch_rs_gt_emit_rtl_h
_gt_pch_rs_gt_except_h
_gt_pch_rs_gt_function_h
_gt_pch_rs_gt_gimplify_h
_gt_pch_rs_gt_rs6000_h
_gt_pch_rs_gt_sdbout_h
_gt_pch_rs_gt_tree_complex_h
_gt_pch_rs_gt_tree_h
_gt_pch_rs_gt_varasm_h
_gt_pch_rs_gtype_desc_c
mudflap_init()
make[1]: *** [cc1] Error 1
make: *** [all-gcc] Error 2
imac:~/BUILD/gcc-4.1-20050227/obj-ppc-apple-darwin7.8.0 d



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]