From 5195a7fb79b5b1c711377c11f5f5755e3e67b8c3 Mon Sep 17 00:00:00 2001 From: "bernard.xiong" Date: Thu, 15 Apr 2010 01:41:10 +0000 Subject: [PATCH] change version number git-svn-id: https://rt-thread.googlecode.com/svn/trunk@622 bbd45198-f89e-11dd-88c7-29a3b14d5316 --- include/rtdef.h | 16 ++++++++++++++-- include/rtthread.h | 10 ---------- src/kservice.c | 4 ++-- 3 files changed, 16 insertions(+), 14 deletions(-) diff --git a/include/rtdef.h b/include/rtdef.h index 8307ff666c..442f9ecd5d 100644 --- a/include/rtdef.h +++ b/include/rtdef.h @@ -22,8 +22,8 @@ extern "C" { #endif /* RT-Thread version information */ -#define RT_VERSION 3 -#define RT_SUBVERSION 0 +#define RT_VERSION 4L +#define RT_SUBVERSION 0L /* date type defination */ typedef signed char rt_int8_t; @@ -56,12 +56,19 @@ typedef rt_uint32_t rt_off_t; /* Type for offset. */ #define RT_UINT16_MAX 0xffff /* Maxium number of UINT16. */ #define RT_UINT32_MAX 0xffffffff /* Maxium number of UINT32. */ +/* Compiler Related Definitions */ #ifdef __CC_ARM /* ARM Compiler */ #include #define SECTION(x) __attribute__((section(x))) #define UNUSED __attribute__((unused)) #define ALIGN(n) __attribute__((aligned(n))) #define rt_inline static __inline + /* module compiling */ + #ifdef RT_USING_MODULE + #define RTT_API __declspec(dllimport) + #else + #define RTT_API __declspec(dllexport) + #endif #elif defined (__ICCARM__) /* for IAR Compiler */ #include @@ -69,6 +76,7 @@ typedef rt_uint32_t rt_off_t; /* Type for offset. */ #define UNUSED #define ALIGN(n) #pragma pack(n) #define rt_inline inline + #define RTT_API #elif defined (__GNUC__) /* GNU GCC Compiler */ #ifdef RT_USING_NEWLIB @@ -91,11 +99,15 @@ typedef rt_uint32_t rt_off_t; /* Type for offset. */ #define UNUSED __attribute__((unused)) #define ALIGN(n) __attribute__((aligned(n))) #define rt_inline static __inline + #define RTT_API + #elif defined (__ICCM16C__) /* for IAR EW M16C Compiler */ #include #define SECTION(x) @ x #define UNUSED #define rt_inline inline + #define RTT_API + #endif /* event length */ diff --git a/include/rtthread.h b/include/rtthread.h index b3d6621e22..152b9556e6 100644 --- a/include/rtthread.h +++ b/include/rtthread.h @@ -27,16 +27,6 @@ extern "C" { #endif -#if defined(__CC_ARM) -#ifdef RT_USING_MODULE -#define RTT_API __declspec(dllimport) -#else -#define RTT_API __declspec(dllexport) -#endif -#elif defined(__GNUC__) -#define RTT_API -#endif - /** * @addtogroup KernelObject */ diff --git a/src/kservice.c b/src/kservice.c index e1aa3ffb51..0d0190c4e2 100644 --- a/src/kservice.c +++ b/src/kservice.c @@ -922,13 +922,13 @@ rt_device_t rt_console_set_device(const char* name) #if defined(__GNUC__) void rt_hw_console_output(const char* str) __attribute__((weak)); - - void rt_hw_console_output(const char* str) #elif defined(__CC_ARM) __weak void rt_hw_console_output(const char* str) #elif defined(__ICCARM__) __weak void rt_hw_console_output(const char* str) +#elif defined(__ICCM16C__) +__weak void rt_hw_console_output(const char* str) #endif { /* empty console output */ -- GitLab