/usr/share/alljoyn/build_core/conf/darwin/SConscript is in liballjoyn-common-dev-1604 16.04a-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | # Copyright AllSeen Alliance. All rights reserved.
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#
Import('env', 'CheckCXXFlag')
import os
# Darwin specific flags
env.Append(CPPDEFINES=['QCC_OS_DARWIN'])
config = Configure(env, custom_tests = { 'CheckCXXFlag' : CheckCXXFlag })
if not config.CheckCXXFlag('-std=c++11'):
if not config.CheckCXXFlag('-std=c++0x'):
print '*** Compiler too old to build AllJoyn. Aborting.'
Exit(1)
env = config.Finish()
env.Append(CFLAGS=['-Wall',
'-pipe',
'-std=c99',
'-fno-strict-aliasing',
'-Wno-long-long'])
env.Append(CXXFLAGS=['-Wall',
'-Werror=non-virtual-dtor',
'-pipe',
'-fno-exceptions',
'-fno-strict-aliasing',
'-Wno-deprecated'])
# Debug/Release Variants
if env['VARIANT'] == 'debug':
env.Append(CFLAGS='-g')
env.Append(CXXFLAGS='-g')
env.Append(JAVACFLAGS='-g -Xlint -Xlint:-serial')
print 'Using debug settings for darwin build...'
else:
env.Append(CFLAGS='-O3')
env.Append(CXXFLAGS='-O3')
env.Append(LINKFLAGS='')
env.Append(JAVACFLAGS='-Xlint -Xlint:-serial')
print 'Using release settings for darwin build...'
env.SConscript('${CPU}/SConscript')
env.Append(CPPDEFINES=['MECHANISM_PIPE'])
env.AppendUnique(LIBS =['stdc++', 'pthread'])
if env['CRYPTO'] == 'openssl':
env.AppendUnique(LIBS =['crypto', 'ssl'])
if env['CPU'] in ['arm', 'armv7', 'armv7s', 'arm64']:
vars = Variables()
vars.Add(PathVariable('OPENSSL_ROOT', 'Base OpenSSL directory (darwin only)', os.environ.get('OPENSSL_ROOT')))
vars.Update(env)
Help(vars.GenerateHelpText(env))
if '' == env.subst('$OPENSSL_ROOT'):
# Must specify OPENSSL_ROOT for darwin, arm
print 'Must specify OPENSSL_ROOT when building for OS=darwin, CPU=arm'
if not GetOption('help'):
Exit(1)
env.Append(CPPPATH = ['$OPENSSL_ROOT/include'])
env.Append(LIBPATH = ['$OPENSSL_ROOT/build/' + os.environ.get('CONFIGURATION') + '-' + os.environ.get('PLATFORM_NAME')])
print 'Using OpenSSL crypto'
else:
print 'Using builtin crypto'
|