Got strip working for Mac OS X

This commit is contained in:
Eric Scharff 2007-11-01 14:37:51 -06:00
parent 625f0006c9
commit eb3bd1ce7c
3 changed files with 2 additions and 10 deletions

View File

@ -5,12 +5,8 @@
#ifdef __MINGW32__ #ifdef __MINGW32__
# define JNIEXPORT __declspec(dllexport) # define JNIEXPORT __declspec(dllexport)
#else #else
#ifdef __APPLE__
# define JNIEXPORT __attribute__ ((used))
#else
# define JNIEXPORT __attribute__ ((visibility("default"))) # define JNIEXPORT __attribute__ ((visibility("default")))
#endif #endif
#endif
namespace { namespace {

View File

@ -82,7 +82,7 @@ ifeq ($(platform),darwin)
build-cflags = $(common-cflags) -fPIC -fvisibility=hidden \ build-cflags = $(common-cflags) -fPIC -fvisibility=hidden \
-I$(JAVA_HOME)/include/linux -I$(src) -I$(JAVA_HOME)/include/linux -I$(src)
lflags = $(common-lflags) -ldl lflags = $(common-lflags) -ldl
strip-all = strip-all = -S -x
endif endif
ifeq ($(platform),windows) ifeq ($(platform),windows)
@ -328,7 +328,7 @@ ifeq ($(platform),windows)
else else
$(cc) $(^) $(lflags) -o $(@) $(cc) $(^) $(lflags) -o $(@)
endif endif
@$(strip) $(strip-all) $(@) $(strip) $(strip-all) $(@)
@$(show-size) $(@) @$(show-size) $(@)
$(generator): $(generator-objects) $(generator): $(generator-objects)

View File

@ -14,12 +14,8 @@
#ifdef __MINGW32__ #ifdef __MINGW32__
# define JNIEXPORT __declspec(dllexport) # define JNIEXPORT __declspec(dllexport)
#else #else
#ifdef __APPLE__
# define JNIEXPORT __attribute__ ((used))
#else
# define JNIEXPORT __attribute__ ((visibility("default"))) # define JNIEXPORT __attribute__ ((visibility("default")))
#endif #endif
#endif
#ifdef __i386__ #ifdef __i386__
# define LD "d" # define LD "d"