Adding GFX_COMPILER_ARMCC and GFX_COMPILER_KEIL
This commit is contained in:
parent
6397a56e0b
commit
ff01cc0212
3 changed files with 10 additions and 5 deletions
9
gfx.h
9
gfx.h
|
@ -35,7 +35,12 @@
|
|||
* @brief Generic 'true' boolean constant.
|
||||
*/
|
||||
#if !defined(TRUE) || defined(__DOXYGEN__)
|
||||
#define TRUE -1
|
||||
// Keil/ARMCC requires some special threatment. can probably be generalized to always be 1.
|
||||
#if (GFX_COMPILER == GFX_COMPILER_ARMCC) || (GFX_COMPILER == GFX_COMPILER_KEIL)
|
||||
#define TRUE 1
|
||||
#else
|
||||
#define TRUE -1
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/**
|
||||
|
@ -57,7 +62,7 @@
|
|||
#if GFX_NO_INLINE
|
||||
#define GFXINLINE
|
||||
#else
|
||||
#if defined(__KEIL__) || defined(__C51__)
|
||||
#if (GFX_COMPILER == GFX_COMPILER_ARMCC) || (GFX_COMPILER == GFX_COMPILER_KEIL)
|
||||
#define GFXINLINE __inline
|
||||
#else
|
||||
#define GFXINLINE inline
|
||||
|
|
|
@ -203,12 +203,12 @@ static thread mainthread; // The main thread context
|
|||
* If they don't exist compile them to be the standard setjmp() function.
|
||||
* Similarly for longjmp().
|
||||
*/
|
||||
#if (!defined(setjmp) && !defined(_setjmp)) || defined(__KEIL__) || defined(__C51__)
|
||||
#if (!defined(setjmp) && !defined(_setjmp)) || (GFX_COMPILER == GFX_COMPILER_ARMCC) || (GFX_COMPILER == GFX_COMPILER_KEIL)
|
||||
#define CXT_SAVE setjmp
|
||||
#else
|
||||
#define CXT_SAVE _setjmp
|
||||
#endif
|
||||
#if (!defined(longjmp) && !defined(_longjmp)) || defined(__KEIL__) || defined(__C51__)
|
||||
#if (!defined(longjmp) && !defined(_longjmp)) || (GFX_COMPILER == GFX_COMPILER_ARMCC) || (GFX_COMPILER == GFX_COMPILER_KEIL)
|
||||
#define CXT_RESTORE longjmp
|
||||
#else
|
||||
#define CXT_RESTORE _longjmp
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
|
||||
#if GFX_USE_GWIN || defined(__DOXYGEN__)
|
||||
|
||||
#if defined(__KEIL__) || defined(__C51__)
|
||||
#if (GFX_COMPILER == GFX_COMPILER_ARMCC) || (GFX_COMPILER == GFX_COMPILER_KEIL)
|
||||
#pragma anon_unions
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue