From 6f1ceafbe7f081487a8b63b852e715c9ecaf0ac4 Mon Sep 17 00:00:00 2001 From: Chul Lee Date: Thu, 15 Dec 2016 13:07:12 +0900 Subject: [PATCH] Added build option to decide whether include libocpmapi.so when build liboctbstack.so This option may helpful in case of only server stack used. This patch was reviewed from https://gerrit.iotivity.org/gerrit/#/c/15185/ Change-Id: Ibb8eabe3c2e0ffb5370977d11a648886eb4b70ab Signed-off-by: Chul Lee Reviewed-on: https://gerrit.iotivity.org/gerrit/15663 Tested-by: jenkins-iotivity Reviewed-by: Kevin Kane Reviewed-by: Randeep Singh --- build_common/SConscript | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build_common/SConscript b/build_common/SConscript index 25fb2fd..d1206c0 100644 --- a/build_common/SConscript +++ b/build_common/SConscript @@ -113,6 +113,7 @@ else: help_vars.Add(EnumVariable('TARGET_ARCH', 'Target architecture', default_arch, os_arch_map[target_os])) help_vars.Add(EnumVariable('SECURED', 'Build with DTLS', '0', allowed_values=('0', '1'))) help_vars.Add(EnumVariable('MULTIPLE_OWNER', 'Enable multiple owner', '0', allowed_values=('0', '1'))) +help_vars.Add(EnumVariable('EXC_PROV_SUPPORT', 'Except OCPMAPI library(libocpmapi.so)', '0', allowed_values=('0', '1'))) help_vars.Add(EnumVariable('TEST', 'Run unit tests', '0', allowed_values=('0', '1'))) help_vars.Add(BoolVariable('LOGGING', 'Enable stack logging', logging_default)) help_vars.Add(BoolVariable('UPLOAD', 'Upload binary ? (For Arduino)', require_upload)) @@ -350,8 +351,9 @@ if env.get('WITH_TCP'): defines.append('-D__WITH_TLS__=1') if env.get('SECURED') == '1': - libs.append('-locpmapi') defines.append('-D_WITH_DTLS_=1') + if not env.get('EXC_PROV_SUPPORT'): + libs.append('-locpmapi') pc_vars = { '\@VERSION\@': project_version, -- 2.7.4