Ugly hack to get around ELF garbage
This commit is contained in:
parent
58dd553d00
commit
dcf39196d5
|
@ -18,7 +18,7 @@ INCLUDE = -I.
|
|||
ifeq "$(PAWN64)" "true"
|
||||
BINARY = $(NAME)64.so
|
||||
BIN_DIR = Release64
|
||||
CFLAGS += -DPAWN_CELL_SIZE=64 -DHAVE_I64
|
||||
CFLAGS += -DPAWN_CELL_SIZE=64 -DHAVE_I64 -Dpc_printf=pc_printf64
|
||||
else
|
||||
BINARY = $(NAME)32.so
|
||||
BIN_DIR = Release32
|
||||
|
|
|
@ -65,12 +65,16 @@
|
|||
* purpose messages; errors go through pc_error(). The function is modelled
|
||||
* after printf().
|
||||
*/
|
||||
#if PAWN_CELL_SIZE==32
|
||||
#if defined __WIN32__ || defined _WIN32 || defined WIN32
|
||||
__declspec (dllexport)
|
||||
int pc_printf(const char *message,...)
|
||||
#else
|
||||
extern int pc_printf(const char *message,...)
|
||||
#endif
|
||||
#else
|
||||
int pc_printf(const char *message, ...)
|
||||
#endif
|
||||
{
|
||||
#if PAWN_CELL_SIZE==32
|
||||
int ret;
|
||||
|
|
|
@ -63,6 +63,12 @@
|
|||
#define PREPROC_TERM '\x7f'/* termination character for preprocessor expressions (the "DEL" code) */
|
||||
#define sDEF_PREFIX "default.inc" /* default prefix filename */
|
||||
|
||||
#if defined WIN32
|
||||
#define INVISIBLE
|
||||
#else
|
||||
#define INVISIBLE __attribute__((visibility("protected")))
|
||||
#endif
|
||||
|
||||
typedef union {
|
||||
void *pv; /* e.g. a name */
|
||||
int i;
|
||||
|
@ -435,12 +441,16 @@ int pc_enablewarning(int number,int enable);
|
|||
*/
|
||||
|
||||
/* general console output */
|
||||
#if PAWN_CELL_SIZE==32
|
||||
#if defined __WIN32__ || defined _WIN32 || defined WIN32
|
||||
__declspec (dllexport)
|
||||
int pc_printf(const char *message,...);
|
||||
#else
|
||||
extern int pc_printf(const char *message,...);
|
||||
#endif
|
||||
#else
|
||||
int pc_printf(const char *message, ...) INVISIBLE;
|
||||
#endif
|
||||
|
||||
/* error report function */
|
||||
int pc_error(int number,char *message,char *filename,int firstline,int lastline,va_list argptr);
|
||||
|
@ -629,11 +639,6 @@ SC_FUNC void jmp_eq0(int number);
|
|||
SC_FUNC void outval(cell val,int newline);
|
||||
|
||||
/* function prototypes in SC5.C */
|
||||
#if defined WIN32
|
||||
#define INVISIBLE
|
||||
#else
|
||||
#define INVISIBLE __attribute__((visibility("protected")))
|
||||
#endif
|
||||
SC_FUNC int error(int number,...) INVISIBLE;
|
||||
SC_FUNC void errorset(int code);
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user