One extlibs/mbedtls/SConscript was passing -fPIC for all compilers,
even the ones, which didn't support it.
Change-Id: Ib946da6f73d3e811e05b8b92bc5315e95a5a3d67
Signed-off-by: Pawel Winogrodzki <pawelwi@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/15295
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Greg Zaverucha <gregz@microsoft.com>
Reviewed-by: Kevin Kane <kkane@microsoft.com>
mbedtls_env = env.Clone()
mbedtls_env.PrependUnique(CPPPATH = [mbedtls_dir])
mbedtls_env.AppendUnique(CPPPATH = [mbedtls_dir+'include/'])
-mbedtls_env.AppendUnique(CFLAGS = ['-fPIC', '-Wall'])
+mbedtls_env.AppendUnique(CFLAGS = ['-Wall'])
+
+if mbedtls_env['CC'] != 'cl':
+ mbedtls_env.AppendUnique(CFLAGS = ['-fPIC'])
######################################################################
# Source files and Target(s)