0

我想做类似于#ifdef __linux__的操作,但是使用bada SDK。是否有默认定义的常量? 另外,我可以检测何时编译模拟器?在Bada操作系统上检测编译

+0

现在我想我要解决与“-D TARGET_OS_BADA” – Jyaif 2010-07-09 15:56:36

回答

0

用途:

#ifdef _DEBUG 
    // Your code 
#endif 
1

您可以通过检查MinGW的编译器的关键字,这里是一个有趣的link,将指向您在正确的位置......所以理论上你可以有它这样

 
#ifdef __MINGW32__ 
/* we're in the simulator target */ 
#else 
/* we're in the native target */ 
#endif 
1

我使用类似:

#ifdef SHP 
# define CONFIG_SUPPORT_API_Osp 1 // bada 
#endif 

我希望也有一个定义告诉sdk版本或目标api太..