From: cc Date: Wed, 23 Nov 2016 11:12:42 +0000 (+0900) Subject: Merge branch 'master' into notification-service X-Git-Tag: 1.3.0~1022^2^2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=97096e8989556bb8df18ab30284e9428878140d5;p=platform%2Fupstream%2Fiotivity.git Merge branch 'master' into notification-service Conflict resolved: service/notification/examples/linux/SConscript Change-Id: I4481a4fa8b9162a76183faafaac7b6df1aca9e9f Signed-off-by: cc --- 97096e8989556bb8df18ab30284e9428878140d5 diff --cc service/notification/examples/linux/SConscript index 1368366,de1a2ab..b2af2b5 --- a/service/notification/examples/linux/SConscript +++ b/service/notification/examples/linux/SConscript @@@ -65,19 -66,9 +66,22 @@@ if env.get('WITH_TCP') == True if env.get('SECURED') == '1': notification_sample_env.AppendUnique(LIBS = ['mbedtls', 'mbedx509', 'mbedcrypto']) +with_mq = env.get('WITH_MQ') +if 'SUB' in with_mq: + notification_sample_env.AppendUnique(CPPDEFINES = ['MQ_SUBSCRIBER', 'WITH_MQ']) + print "MQ SUB support" + +if 'PUB' in with_mq: + notification_sample_env.AppendUnique(CPPDEFINES = ['MQ_PUBLISHER', 'WITH_MQ']) + print "MQ PUB support" + +if 'BROKER' in with_mq: + notification_sample_env.AppendUnique(CPPDEFINES = ['MQ_BROKER', 'WITH_MQ']) + print "MQ Broker support" + + if 'CLIENT' in rd_mode or 'SERVER' in rd_mode: - notification_sample_env.AppendUnique(LIBS = ['resource_directory']) ++ notification_sample_env.AppendUnique(LIBS = ['resource_directory']) + #################################################################### # Source files and Targets ###################################################################### diff --cc service/notification/src/common/NSConstants.h index 84eba38,e83ed34..f0a3545 --- a/service/notification/src/common/NSConstants.h +++ b/service/notification/src/common/NSConstants.h @@@ -21,16 -21,31 +21,31 @@@ #ifndef _NS_CONSTANTS_H_ #define _NS_CONSTANTS_H_ -#define __PRINTLOG 0 +#define __PRINTLOG 1 #define __NS_FILE__ ( strrchr(__FILE__, '/') ? strrchr(__FILE__, '/') + 1 : __FILE__ ) - #ifdef TB_LOG #include "logger.h" + + #ifdef TB_LOG + #ifdef __TIZEN__ + #include + #ifdef LOG_TAG + #undef LOG_TAG + #endif // LOG_TAG + #define LOG_TAG "NotificationService" + #define NS_CONVERT_LEVEL(level) ( \ + ((level) == 0) ? DLOG_DEBUG : \ + ((level) == 1) ? DLOG_INFO : \ + ((level) == 2) ? DLOG_WARN : \ + ((level) == 3) ? DLOG_ERROR : DLOG_ERROR) + #define NS_LOG_V(level, format, ...) (dlog_print(NS_CONVERT_LEVEL(level), LOG_TAG, (format), __VA_ARGS__)) + #define NS_LOG(level, msg) (dlog_print(NS_CONVERT_LEVEL(level), LOG_TAG, (msg))) + #else // __TIZEN__ #define NS_LOG_V(level, format, ...) (OIC_LOG_V((level), __NS_FILE__, (format), __VA_ARGS__)) #define NS_LOG(level, msg) (OIC_LOG((level), __NS_FILE__, (msg))) - #else + #endif // __TIZEN__ + #else // TB_LOG #if (__PRINTLOG == 1) - #include "logger.h" #define NS_CONVERT_LEVEL(level) ( \ ((level) == 0) ? "DEBUG" : \ ((level) == 1) ? "INFO" : \