- Added options to link staticly against oiio/boost
- Also changed buildbot settings so now linking should happe staticly
This commit is contained in:
parent
2a747e8b03
commit
f09f5eec57
|
@ -96,16 +96,18 @@ WITH_BF_JACK = True
|
|||
WITH_BF_CYCLES = True
|
||||
|
||||
WITH_BF_OIIO = True
|
||||
WITH_BF_STATICOIIO = True
|
||||
BF_OIIO = '/opt/oiio'
|
||||
BF_OIIO_INC = '/opt/oiio/include'
|
||||
BF_OIIO_LIB = 'OpenImageIO IlmImf'
|
||||
BF_OIIO_LIBPATH = '/opt/oiio/lib'
|
||||
BF_OIIO_INC = '${BF_OIIO}/include'
|
||||
BF_OIIO_LIB_STATIC = '${BF_OIIO_LIBPATH}/libOpenImageIO.a'
|
||||
BF_OIIO_LIBPATH = '${BF_OIIO}/lib'
|
||||
|
||||
WITH_BF_BOOST = True
|
||||
WITH_BF_STATICBOOST = True
|
||||
BF_BOOST = '/opt/boost'
|
||||
BF_BOOST_INC = '/opt/boost/include'
|
||||
BF_BOOST_LIB = 'libboost_date_time libboost_filesystem libboost_regex libboost_system libboost_thread'
|
||||
BF_BOOST_LIBPATH = '/opt/boost/lib'
|
||||
BF_BOOST_INC = '${BF_BOOST}/include'
|
||||
BF_BOOST_LIB_STATIC = '${BF_BOOST_LIBPATH}/libboost_filesystem.a ${BF_BOOST_LIBPATH}/libboost_date_time.a ${BF_BOOST_LIBPATH}/libboost_regex.a ${BF_BOOST_LIBPATH}/libboost_system.a ${BF_BOOST_LIBPATH}/libboost_thread.a'
|
||||
BF_BOOST_LIBPATH = '${BF_BOOST}/lib'
|
||||
|
||||
# Compilation and optimization
|
||||
BF_DEBUG = False
|
||||
|
|
|
@ -96,16 +96,18 @@ WITH_BF_JACK = True
|
|||
WITH_BF_CYCLES = True
|
||||
|
||||
WITH_BF_OIIO = True
|
||||
WITH_BF_STATICOIIO = True
|
||||
BF_OIIO = '/opt/oiio'
|
||||
BF_OIIO_INC = '/opt/oiio/include'
|
||||
BF_OIIO_LIB = 'OpenImageIO IlmImf'
|
||||
BF_OIIO_LIBPATH = '/opt/oiio/lib'
|
||||
BF_OIIO_INC = '${BF_OIIO}/include'
|
||||
BF_OIIO_LIB_STATIC = '${BF_OIIO_LIBPATH}/libOpenImageIO.a'
|
||||
BF_OIIO_LIBPATH = '${BF_OIIO}/lib'
|
||||
|
||||
WITH_BF_BOOST = True
|
||||
WITH_BF_STATICBOOST = True
|
||||
BF_BOOST = '/opt/boost'
|
||||
BF_BOOST_INC = '/opt/boost/include'
|
||||
BF_BOOST_LIB = 'libboost_date_time libboost_filesystem libboost_regex libboost_system libboost_thread'
|
||||
BF_BOOST_LIBPATH = '/opt/boost/lib'
|
||||
BF_BOOST_INC = '${BF_BOOST}/include'
|
||||
BF_BOOST_LIB_STATIC = '${BF_BOOST_LIBPATH}/libboost_filesystem.a ${BF_BOOST_LIBPATH}/libboost_date_time.a ${BF_BOOST_LIBPATH}/libboost_regex.a ${BF_BOOST_LIBPATH}/libboost_system.a ${BF_BOOST_LIBPATH}/libboost_thread.a'
|
||||
BF_BOOST_LIBPATH = '${BF_BOOST}/lib'
|
||||
|
||||
# Compilation and optimization
|
||||
BF_DEBUG = False
|
||||
|
|
|
@ -195,8 +195,13 @@ def setup_staticlibs(lenv):
|
|||
|
||||
if lenv['WITH_BF_OIIO']:
|
||||
libincs += Split(lenv['BF_OIIO_LIBPATH'])
|
||||
if lenv['WITH_BF_STATICOIIO']:
|
||||
statlibs += Split(lenv['BF_OIIO_LIB_STATIC'])
|
||||
|
||||
if lenv['WITH_BF_BOOST']:
|
||||
libincs += Split(lenv['BF_BOOST_LIBPATH'])
|
||||
if lenv['WITH_BF_STATICBOOST']:
|
||||
statlibs += Split(lenv['BF_BOOST_LIB_STATIC'])
|
||||
|
||||
# setting this last so any overriding of manually libs could be handled
|
||||
if lenv['OURPLATFORM'] not in ('win32-vc', 'win32-mingw', 'win64-vc', 'linuxcross'):
|
||||
|
@ -238,7 +243,8 @@ def setup_syslibs(lenv):
|
|||
if lenv['WITH_BF_ICONV']:
|
||||
syslibs += Split(lenv['BF_ICONV_LIB'])
|
||||
if lenv['WITH_BF_OIIO']:
|
||||
syslibs += Split(lenv['BF_OIIO_LIB'])
|
||||
if not lenv['WITH_BF_STATICOIIO']:
|
||||
syslibs += Split(lenv['BF_OIIO_LIB'])
|
||||
|
||||
if lenv['WITH_BF_OPENEXR'] and not lenv['WITH_BF_STATICOPENEXR']:
|
||||
syslibs += Split(lenv['BF_OPENEXR_LIB'])
|
||||
|
@ -279,7 +285,7 @@ def setup_syslibs(lenv):
|
|||
if not lenv['WITH_BF_STATIC3DMOUSE']:
|
||||
syslibs += Split(lenv['BF_3DMOUSE_LIB'])
|
||||
|
||||
if lenv['WITH_BF_BOOST']:
|
||||
if lenv['WITH_BF_BOOST'] and not lenv['WITH_BF_STATICBOOST']:
|
||||
syslibs += Split(lenv['BF_BOOST_LIB'])
|
||||
|
||||
syslibs += Split(lenv['BF_JPEG_LIB'])
|
||||
|
|
|
@ -157,8 +157,8 @@ def validate_arguments(args, bc):
|
|||
'BUILDBOT_BRANCH',
|
||||
'WITH_BF_3DMOUSE', 'WITH_BF_STATIC3DMOUSE', 'BF_3DMOUSE', 'BF_3DMOUSE_INC', 'BF_3DMOUSE_LIB', 'BF_3DMOUSE_LIBPATH', 'BF_3DMOUSE_LIB_STATIC',
|
||||
'WITH_BF_CYCLES',
|
||||
'WITH_BF_OIIO', 'BF_OIIO', 'BF_OIIO_INC', 'BF_OIIO_LIB', 'BF_OIIO_LIBPATH',
|
||||
'WITH_BF_BOOST', 'BF_BOOST', 'BF_BOOST_INC', 'BF_BOOST_LIB', 'BF_BOOST_LIBPATH'
|
||||
'WITH_BF_OIIO', 'WITH_BF_STATICOIIO', 'BF_OIIO', 'BF_OIIO_INC', 'BF_OIIO_LIB', 'BF_OIIO_LIB_STATIC', 'BF_OIIO_LIBPATH',
|
||||
'WITH_BF_BOOST', 'WITH_BF_STATICBOOST', 'BF_BOOST', 'BF_BOOST_INC', 'BF_BOOST_LIB', 'BF_BOOST_LIB_STATIC', 'BF_BOOST_LIBPATH'
|
||||
]
|
||||
|
||||
# Have options here that scons expects to be lists
|
||||
|
@ -538,20 +538,26 @@ def read_opts(env, cfg, args):
|
|||
(BoolVariable('WITH_BF_CXX_GUARDEDALLOC', 'Enable GuardedAlloc for C++ memory allocation tracking.', False)),
|
||||
|
||||
('BUILDBOT_BRANCH', 'Buildbot branch name', ''),
|
||||
|
||||
) # end of opts.AddOptions()
|
||||
|
||||
localopts.AddVariables(
|
||||
(BoolVariable('WITH_BF_CYCLES', 'Build with the Cycles engine', True)),
|
||||
|
||||
|
||||
(BoolVariable('WITH_BF_OIIO', 'Build with OpenImageIO', False)),
|
||||
(BoolVariable('WITH_BF_STATICOIIO', 'Staticly link to OpenImageIO', False)),
|
||||
('BF_OIIO', 'OIIO root path', ''),
|
||||
('BF_OIIO_INC', 'OIIO include path', ''),
|
||||
('BF_OIIO_LIB', 'OIIO library', ''),
|
||||
('BF_OIIO_LIBPATH', 'OIIO library path', ''),
|
||||
|
||||
('BF_OIIO_LIB_STATIC', 'OIIO static library', ''),
|
||||
|
||||
(BoolVariable('WITH_BF_BOOST', 'Build with Boost', False)),
|
||||
(BoolVariable('WITH_BF_STATICBOOST', 'Staticly link to boost', False)),
|
||||
('BF_BOOST', 'Boost root path', ''),
|
||||
('BF_BOOST_INC', 'Boost include path', ''),
|
||||
('BF_BOOST_LIB', 'Boost library', ''),
|
||||
('BF_BOOST_LIBPATH', 'Boost library path', '')
|
||||
('BF_BOOST_LIBPATH', 'Boost library path', ''),
|
||||
('BF_BOOST_LIB_STATIC', 'Boost static library', '')
|
||||
) # end of opts.AddOptions()
|
||||
|
||||
return localopts
|
||||
|
|
Loading…
Reference in New Issue