From 7a477d70cabe15fa66fd0f32fab5e95841a500e5 Mon Sep 17 00:00:00 2001 From: grischka Date: Wed, 6 Feb 2013 19:01:07 +0100 Subject: lib/Makefile: use CC, add bcheck to libtcc1.a Also: - fix "make tcc_p" (profiling version) - remove old gcc flags: -mpreferred-stack-boundary=2 -march=i386 -falign-functions=0 - remove test "hello" for Darwin (cannot compile to file) --- libtcc.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libtcc.c') diff --git a/libtcc.c b/libtcc.c index 79542b3..0242dc4 100644 --- a/libtcc.c +++ b/libtcc.c @@ -105,12 +105,14 @@ static void tcc_set_lib_path_w32(TCCState *s) tcc_set_lib_path(s, path); } +#ifdef TCC_TARGET_PE static void tcc_add_systemdir(TCCState *s) { char buf[1000]; GetSystemDirectory(buf, sizeof buf); tcc_add_library_path(s, normalize_slashes(buf)); } +#endif #ifndef CONFIG_TCC_STATIC void dlclose(void *p) @@ -1169,9 +1171,11 @@ ST_FUNC int tcc_add_file_internal(TCCState *s1, const char *filename, int flags) #ifndef TCC_TARGET_PE if (ehdr.e_type == ET_DYN) { if (s1->output_type == TCC_OUTPUT_MEMORY) { +#ifdef TCC_IS_NATIVE void *h; h = dlopen(filename, RTLD_GLOBAL | RTLD_LAZY); if (h) +#endif ret = 0; } else { ret = tcc_load_dll(s1, fd, filename, -- cgit v1.3.1