From 5d7684ba829c5afebf037e83c2d7ed33936748a9 Mon Sep 17 00:00:00 2001 From: Richard Kreckel Date: Sun, 7 May 2006 21:05:24 +0000 Subject: [PATCH] * include/cln/modules.h (CL_JUMP_TO): Fix for Intel Mac. --- ChangeLog | 4 ++++ include/cln/modules.h | 6 +++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index fd8e33e..e9080bd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2006-05-07 Richard B. Kreckel + + * include/cln/modules.h (CL_JUMP_TO): Fix for Intel Mac. + 2006-04-25 Ralf Wildenhues Prepare for autoconf-2.60. diff --git a/include/cln/modules.h b/include/cln/modules.h index ee64fc0..befd60a 100644 --- a/include/cln/modules.h +++ b/include/cln/modules.h @@ -126,7 +126,11 @@ // in gcc-2.95. For new CPUs, look for "jump" and "indirect_jump" in gcc's // machine description. #if defined(__i386__) - #define CL_JUMP_TO(addr) ASM_VOLATILE("jmp %*%0" : : "rm" ((void*)(addr))) + #if defined(__APPLE__) && defined(__MACH__) + #define CL_JUMP_TO(addr) ASM_VOLATILE("jmp " ASM_UNDERSCORE_PREFIX #addr) + #else + #define CL_JUMP_TO(addr) ASM_VOLATILE("jmp %*%0" : : "rm" ((void*)(addr))) + #endif #endif #if defined(__x86_64__) #define CL_JUMP_TO(addr) ASM_VOLATILE("jmp " ASM_UNDERSCORE_PREFIX #addr)