Revert part of "fix installation amd bcheck for Windows"

tccelf.c : force linking bcheck by adding elf symbol __bound_init
bcheck.c : use (size_t)1 for x86_64

Fixes 7e7e6148fd
This commit is contained in:
grischka
2016-10-01 20:47:36 +02:00
parent acac35c125
commit 9c5bb16447
8 changed files with 58 additions and 92 deletions

View File

@ -1673,16 +1673,6 @@ LIBTCCAPI int tcc_set_output_type(TCCState *s, int output_type)
tcc_add_crt(s, "crt1.o");
tcc_add_crt(s, "crti.o");
}
#endif
#ifdef CONFIG_TCC_BCHECK
if (s->do_bounds_check && (output_type == TCC_OUTPUT_EXE))
{
/* force a bcheck.o linking */
addr_t func = TOK___bound_init;
Sym *sym = external_global_sym(func, &func_old_type, 0);
if (!sym->c)
put_extern_sym(sym, NULL, 0, 0);
}
#endif
if (s->normalize_inc_dirs)
tcc_normalize_inc_dirs(s);