[IoT-1523] Add environments for MQ build
authorjaesick.shin <jaesick.shin@samsung.com>
Wed, 2 Nov 2016 03:42:04 +0000 (12:42 +0900)
committerUze Choi <uzchoi@samsung.com>
Thu, 17 Nov 2016 08:24:12 +0000 (08:24 +0000)
This patch inlcude,
Add environments for MQ build in SConScripts.

Change-Id: Iab8939f2f26d43f6d238eee071aa6b8aafa232fb
Signed-off-by: jaesick.shin <jaesick.shin@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/13941
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
service/notification/SConscript
service/notification/examples/linux/SConscript

index f7f8edf..4a0b19e 100755 (executable)
@@ -86,6 +86,20 @@ if env.get('WITH_CLOUD') == True:
 
 if env.get('SECURED') == '1':
        notification_env.AppendUnique(CPPDEFINES = ['SECURED'])
+       
+with_mq = env.get('WITH_MQ')
+if 'SUB' in with_mq:
+    notification_env.AppendUnique(CPPDEFINES = ['MQ_SUBSCRIBER', 'WITH_MQ'])
+    print "MQ SUB support"
+
+if 'PUB' in with_mq:
+    notification_env.AppendUnique(CPPDEFINES = ['MQ_PUBLISHER', 'WITH_MQ'])
+    print "MQ PUB support"
+
+if 'BROKER' in with_mq:
+    notification_env.AppendUnique(CPPDEFINES = ['MQ_BROKER', 'WITH_MQ'])
+    print "MQ Broker support"
+
 
 ######################################################################
 # Source files and Targets
index 826e60f..1368366 100644 (file)
@@ -65,6 +65,19 @@ 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"
+
 ####################################################################
 # Source files and Targets
 ######################################################################