34 lines
936 B
Python
34 lines
936 B
Python
# -*- mode: python -*-
|
|
|
|
Import("env")
|
|
Import("endian")
|
|
|
|
env = env.Clone()
|
|
|
|
if env['TARGET_ARCH'] == 's390x':
|
|
env.Append(CPPPATH=["build_linux_s390x"])
|
|
elif env.TargetOSIs('linux'):
|
|
env.Append(CPPPATH=["build_linux"])
|
|
elif env.TargetOSIs('windows'):
|
|
# C4996: 'memccpy': The POSIX name for this item is deprecated. Instead, use the ISO C and C++
|
|
# conformant name: _memccpy. See online help for details
|
|
env.Append(CCFLAGS=['/wd4996'])
|
|
# C4018: '<': signed/unsigned mismatch
|
|
env.Append(CCFLAGS=['/wd4018'])
|
|
env.Append(CPPPATH=["build_windows"])
|
|
elif not env.TargetOSIs('windows'):
|
|
env.Append(CPPPATH=["build_posix"])
|
|
|
|
env.Append( CPPDEFINES=[ "HAVE_CONFIG_H", ] )
|
|
|
|
if env.ToolchainIs('clang', 'GCC'):
|
|
env.Append(CCFLAGS=['-Wno-sign-compare', '-Wno-unused-function'])
|
|
|
|
env.Library(
|
|
target='snappy',
|
|
source=[
|
|
'snappy-c.cc',
|
|
'snappy.cc',
|
|
'snappy-sinksource.cc',
|
|
])
|