From 1e1e4980874d7689507777db8ce61c2fb4ba0413 Mon Sep 17 00:00:00 2001 From: mazze Date: Mon, 8 Sep 2014 22:19:40 +0000 Subject: [PATCH] Updated to current SDL_lib.h. git-svn-id: https://svn.aros.org/svn/aros/trunk/AROS@49592 fb15a70f-31f2-0310-bbcc-cdcc74a49acc --- .../include => compiler/include/SDI}/SDI_lib.h | 54 +++++++++++++++------- test/sdi/SDI_lib.h | 53 ++++++++++++++------- .../zune/betterstring}/include/SDI_lib.h | 54 +++++++++++++++------- workbench/classes/zune/nlist/include/SDI_lib.h | 41 +++++++++++++++- .../zune/texteditor}/include/SDI_lib.h | 54 +++++++++++++++------- .../codesets => devs/diskimage}/include/SDI_lib.h | 54 +++++++++++++++------- workbench/libs/codesets/include/SDI_lib.h | 54 +++++++++++++++------- 7 files changed, 262 insertions(+), 102 deletions(-) copy {workbench/libs/codesets/include => compiler/include/SDI}/SDI_lib.h (83%) copy workbench/{libs/codesets => classes/zune/betterstring}/include/SDI_lib.h (83%) copy workbench/{libs/codesets => classes/zune/texteditor}/include/SDI_lib.h (83%) copy workbench/{libs/codesets => devs/diskimage}/include/SDI_lib.h (83%) diff --git a/workbench/libs/codesets/include/SDI_lib.h b/compiler/include/SDI/SDI_lib.h similarity index 83% copy from workbench/libs/codesets/include/SDI_lib.h copy to compiler/include/SDI/SDI_lib.h index 9c94d18c3b..a7fb68111c 100644 --- a/workbench/libs/codesets/include/SDI_lib.h +++ b/compiler/include/SDI/SDI_lib.h @@ -43,7 +43,7 @@ version (Thore Böckelmann) 1.12 01.04.14 : removed the necessity of stub functions for AmigaOS4 (Thore Böckelmann) - 1.13 28.08.14 : adapted to AROS (AROS Development Team) + 1.13 07.09.14 : adapted to AROS (AROS Development Team) */ /* @@ -175,23 +175,43 @@ #define LFUNC_VA_(name) #define LFUNC(name) LIBSTUB_##name #elif defined(__AROS__) - #define LIBFUNC - #if !defined(__cplusplus) && \ - (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ - (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) - #define LIBPROTO(name, ret, ...) \ - LIBFUNC ret LIB_##name(__VA_ARGS__) - #define LIBPROTOVA(name, ret, ...) - #define LIBSTUB(name, ret, ...) \ - LIBFUNC ret LIBSTUB_0_##name(void) - #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) - #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #if defined(AROS_ABI_V1) + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_0_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_0_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_0_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_0_##name + #else + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_##name #endif - #define LFUNC_FAS(name) LIBSTUB_0_##name - #define LFUNC_VAS(name) - #define LFUNC_FA_(name) ,LIBSTUB_0_##name - #define LFUNC_VA_(name) - #define LFUNC(name) LIBSTUB_0_##name #else #define LIBFUNC SAVEDS ASM #if !defined(__cplusplus) && \ diff --git a/test/sdi/SDI_lib.h b/test/sdi/SDI_lib.h index 9a2a5812ab..a7fb68111c 100644 --- a/test/sdi/SDI_lib.h +++ b/test/sdi/SDI_lib.h @@ -43,6 +43,7 @@ version (Thore Böckelmann) 1.12 01.04.14 : removed the necessity of stub functions for AmigaOS4 (Thore Böckelmann) + 1.13 07.09.14 : adapted to AROS (AROS Development Team) */ /* @@ -174,23 +175,43 @@ #define LFUNC_VA_(name) #define LFUNC(name) LIBSTUB_##name #elif defined(__AROS__) - #define LIBFUNC - #if !defined(__cplusplus) && \ - (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ - (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) - #define LIBPROTO(name, ret, ...) \ - LIBFUNC ret LIB_##name(__VA_ARGS__) - #define LIBPROTOVA(name, ret, ...) - #define LIBSTUB(name, ret, ...) \ - LIBFUNC ret LIBSTUB_0_##name(void) - #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) - #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #if defined(AROS_ABI_V1) + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_0_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_0_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_0_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_0_##name + #else + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_##name #endif - #define LFUNC_FAS(name) LIBSTUB_0_##name - #define LFUNC_VAS(name) - #define LFUNC_FA_(name) ,LIBSTUB_0_##name - #define LFUNC_VA_(name) - #define LFUNC(name) LIBSTUB_0_##name #else #define LIBFUNC SAVEDS ASM #if !defined(__cplusplus) && \ diff --git a/workbench/libs/codesets/include/SDI_lib.h b/workbench/classes/zune/betterstring/include/SDI_lib.h similarity index 83% copy from workbench/libs/codesets/include/SDI_lib.h copy to workbench/classes/zune/betterstring/include/SDI_lib.h index 9c94d18c3b..a7fb68111c 100644 --- a/workbench/libs/codesets/include/SDI_lib.h +++ b/workbench/classes/zune/betterstring/include/SDI_lib.h @@ -43,7 +43,7 @@ version (Thore Böckelmann) 1.12 01.04.14 : removed the necessity of stub functions for AmigaOS4 (Thore Böckelmann) - 1.13 28.08.14 : adapted to AROS (AROS Development Team) + 1.13 07.09.14 : adapted to AROS (AROS Development Team) */ /* @@ -175,23 +175,43 @@ #define LFUNC_VA_(name) #define LFUNC(name) LIBSTUB_##name #elif defined(__AROS__) - #define LIBFUNC - #if !defined(__cplusplus) && \ - (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ - (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) - #define LIBPROTO(name, ret, ...) \ - LIBFUNC ret LIB_##name(__VA_ARGS__) - #define LIBPROTOVA(name, ret, ...) - #define LIBSTUB(name, ret, ...) \ - LIBFUNC ret LIBSTUB_0_##name(void) - #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) - #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #if defined(AROS_ABI_V1) + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_0_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_0_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_0_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_0_##name + #else + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_##name #endif - #define LFUNC_FAS(name) LIBSTUB_0_##name - #define LFUNC_VAS(name) - #define LFUNC_FA_(name) ,LIBSTUB_0_##name - #define LFUNC_VA_(name) - #define LFUNC(name) LIBSTUB_0_##name #else #define LIBFUNC SAVEDS ASM #if !defined(__cplusplus) && \ diff --git a/workbench/classes/zune/nlist/include/SDI_lib.h b/workbench/classes/zune/nlist/include/SDI_lib.h index 33cab86f9a..a7fb68111c 100644 --- a/workbench/classes/zune/nlist/include/SDI_lib.h +++ b/workbench/classes/zune/nlist/include/SDI_lib.h @@ -10,7 +10,7 @@ Project page: http://sf.net/p/adtools/code/HEAD/tree/trunk/sdi/ Description: defines to hide OS specific library function definitions Id: $Id$ - URL: $URL: https://svn.code.sf.net/p/adtools/code/trunk/sdi/SDI_lib.h $ + URL: $URL: svn://svn.code.sf.net/p/adtools/code/trunk/sdi/SDI_lib.h $ 1.0 09.05.04 : initial version which allows to hide OS specific shared library function definition like it has been introduced with @@ -43,6 +43,7 @@ version (Thore Böckelmann) 1.12 01.04.14 : removed the necessity of stub functions for AmigaOS4 (Thore Böckelmann) + 1.13 07.09.14 : adapted to AROS (AROS Development Team) */ /* @@ -173,6 +174,44 @@ #define LFUNC_FA_(name) ,LIBSTUB_##name #define LFUNC_VA_(name) #define LFUNC(name) LIBSTUB_##name +#elif defined(__AROS__) + #if defined(AROS_ABI_V1) + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_0_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_0_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_0_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_0_##name + #else + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_##name + #endif #else #define LIBFUNC SAVEDS ASM #if !defined(__cplusplus) && \ diff --git a/workbench/libs/codesets/include/SDI_lib.h b/workbench/classes/zune/texteditor/include/SDI_lib.h similarity index 83% copy from workbench/libs/codesets/include/SDI_lib.h copy to workbench/classes/zune/texteditor/include/SDI_lib.h index 9c94d18c3b..a7fb68111c 100644 --- a/workbench/libs/codesets/include/SDI_lib.h +++ b/workbench/classes/zune/texteditor/include/SDI_lib.h @@ -43,7 +43,7 @@ version (Thore Böckelmann) 1.12 01.04.14 : removed the necessity of stub functions for AmigaOS4 (Thore Böckelmann) - 1.13 28.08.14 : adapted to AROS (AROS Development Team) + 1.13 07.09.14 : adapted to AROS (AROS Development Team) */ /* @@ -175,23 +175,43 @@ #define LFUNC_VA_(name) #define LFUNC(name) LIBSTUB_##name #elif defined(__AROS__) - #define LIBFUNC - #if !defined(__cplusplus) && \ - (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ - (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) - #define LIBPROTO(name, ret, ...) \ - LIBFUNC ret LIB_##name(__VA_ARGS__) - #define LIBPROTOVA(name, ret, ...) - #define LIBSTUB(name, ret, ...) \ - LIBFUNC ret LIBSTUB_0_##name(void) - #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) - #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #if defined(AROS_ABI_V1) + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_0_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_0_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_0_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_0_##name + #else + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_##name #endif - #define LFUNC_FAS(name) LIBSTUB_0_##name - #define LFUNC_VAS(name) - #define LFUNC_FA_(name) ,LIBSTUB_0_##name - #define LFUNC_VA_(name) - #define LFUNC(name) LIBSTUB_0_##name #else #define LIBFUNC SAVEDS ASM #if !defined(__cplusplus) && \ diff --git a/workbench/libs/codesets/include/SDI_lib.h b/workbench/devs/diskimage/include/SDI_lib.h similarity index 83% copy from workbench/libs/codesets/include/SDI_lib.h copy to workbench/devs/diskimage/include/SDI_lib.h index 9c94d18c3b..a7fb68111c 100644 --- a/workbench/libs/codesets/include/SDI_lib.h +++ b/workbench/devs/diskimage/include/SDI_lib.h @@ -43,7 +43,7 @@ version (Thore Böckelmann) 1.12 01.04.14 : removed the necessity of stub functions for AmigaOS4 (Thore Böckelmann) - 1.13 28.08.14 : adapted to AROS (AROS Development Team) + 1.13 07.09.14 : adapted to AROS (AROS Development Team) */ /* @@ -175,23 +175,43 @@ #define LFUNC_VA_(name) #define LFUNC(name) LIBSTUB_##name #elif defined(__AROS__) - #define LIBFUNC - #if !defined(__cplusplus) && \ - (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ - (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) - #define LIBPROTO(name, ret, ...) \ - LIBFUNC ret LIB_##name(__VA_ARGS__) - #define LIBPROTOVA(name, ret, ...) - #define LIBSTUB(name, ret, ...) \ - LIBFUNC ret LIBSTUB_0_##name(void) - #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) - #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #if defined(AROS_ABI_V1) + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_0_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_0_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_0_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_0_##name + #else + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_##name #endif - #define LFUNC_FAS(name) LIBSTUB_0_##name - #define LFUNC_VAS(name) - #define LFUNC_FA_(name) ,LIBSTUB_0_##name - #define LFUNC_VA_(name) - #define LFUNC(name) LIBSTUB_0_##name #else #define LIBFUNC SAVEDS ASM #if !defined(__cplusplus) && \ diff --git a/workbench/libs/codesets/include/SDI_lib.h b/workbench/libs/codesets/include/SDI_lib.h index 9c94d18c3b..a7fb68111c 100644 --- a/workbench/libs/codesets/include/SDI_lib.h +++ b/workbench/libs/codesets/include/SDI_lib.h @@ -43,7 +43,7 @@ version (Thore Böckelmann) 1.12 01.04.14 : removed the necessity of stub functions for AmigaOS4 (Thore Böckelmann) - 1.13 28.08.14 : adapted to AROS (AROS Development Team) + 1.13 07.09.14 : adapted to AROS (AROS Development Team) */ /* @@ -175,23 +175,43 @@ #define LFUNC_VA_(name) #define LFUNC(name) LIBSTUB_##name #elif defined(__AROS__) - #define LIBFUNC - #if !defined(__cplusplus) && \ - (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ - (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) - #define LIBPROTO(name, ret, ...) \ - LIBFUNC ret LIB_##name(__VA_ARGS__) - #define LIBPROTOVA(name, ret, ...) - #define LIBSTUB(name, ret, ...) \ - LIBFUNC ret LIBSTUB_0_##name(void) - #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) - #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #if defined(AROS_ABI_V1) + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_0_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_0_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_0_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_0_##name + #else + #define LIBFUNC + #if !defined(__cplusplus) && \ + (__STDC_VERSION__ >= 199901L || __GNUC__ >= 3 || \ + (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)) + #define LIBPROTO(name, ret, ...) \ + LIBFUNC ret LIB_##name(__VA_ARGS__) + #define LIBPROTOVA(name, ret, ...) + #define LIBSTUB(name, ret, ...) \ + LIBFUNC ret LIBSTUB_##name(void) + #define CALL_LFUNC_NP(name, ...) LIB_##name(__BASE_OR_IFACE_VAR) + #define CALL_LFUNC(name, ...) LIB_##name(__BASE_OR_IFACE_VAR, __VA_ARGS__) + #endif + #define LFUNC_FAS(name) LIBSTUB_##name + #define LFUNC_VAS(name) + #define LFUNC_FA_(name) ,LIBSTUB_##name + #define LFUNC_VA_(name) + #define LFUNC(name) LIBSTUB_##name #endif - #define LFUNC_FAS(name) LIBSTUB_0_##name - #define LFUNC_VAS(name) - #define LFUNC_FA_(name) ,LIBSTUB_0_##name - #define LFUNC_VA_(name) - #define LFUNC(name) LIBSTUB_0_##name #else #define LIBFUNC SAVEDS ASM #if !defined(__cplusplus) && \ -- 2.11.4.GIT