2011-11-07 12:55:18 +00:00
|
|
|
#!/usr/bin/python
|
2011-12-15 12:44:05 +00:00
|
|
|
|
2012-01-11 07:19:44 +00:00
|
|
|
# NOTE: This file is automatically generated by bundle.sh script
|
2011-12-15 12:44:05 +00:00
|
|
|
# If you're doing changes in this file, please update template
|
|
|
|
# in that script too
|
|
|
|
|
2011-11-07 12:55:18 +00:00
|
|
|
import sys
|
|
|
|
import os
|
2014-05-01 23:52:56 +00:00
|
|
|
from FindSharedPtr import FindSharedPtr
|
2011-11-07 12:55:18 +00:00
|
|
|
|
|
|
|
Import('env')
|
|
|
|
|
|
|
|
defs = []
|
2013-05-12 22:30:34 +00:00
|
|
|
incs = '.'
|
2011-11-07 12:55:18 +00:00
|
|
|
|
2013-05-12 22:17:37 +00:00
|
|
|
if env['WITH_BF_LIBMV']:
|
2014-05-01 23:52:56 +00:00
|
|
|
if not env['WITH_SHARED_PTR_SUPPORT']:
|
|
|
|
print("-- Unable to find shared_ptr which is required for compilation.")
|
|
|
|
exit(1)
|
|
|
|
|
|
|
|
if env['SHARED_PTR_HEADER'] == 'tr1/memory':
|
|
|
|
defs.append('CERES_TR1_MEMORY_HEADER')
|
|
|
|
if env['SHARED_PTR_NAMESPACE'] == 'std::tr1':
|
|
|
|
defs.append('CERES_TR1_SHARED_PTR')
|
|
|
|
|
2013-05-12 22:17:37 +00:00
|
|
|
defs.append('GOOGLE_GLOG_DLL_DECL=')
|
2013-10-09 08:46:02 +00:00
|
|
|
defs.append('WITH_LIBMV_GUARDED_ALLOC')
|
2014-02-06 12:13:12 +00:00
|
|
|
defs.append('LIBMV_NO_FAST_DETECTOR')
|
2013-05-12 22:17:37 +00:00
|
|
|
|
2014-09-25 11:01:06 +00:00
|
|
|
src = env.Glob('intern/*.cc')
|
2014-09-26 08:28:04 +00:00
|
|
|
src.remove('intern' + os.sep + 'stub.cc')
|
2014-04-23 10:02:30 +00:00
|
|
|
src += env.Glob('libmv/base/*.cc')
|
2013-05-12 22:17:37 +00:00
|
|
|
src += env.Glob('libmv/image/*.cc')
|
|
|
|
src += env.Glob('libmv/multiview/*.cc')
|
|
|
|
src += env.Glob('libmv/numeric/*.cc')
|
|
|
|
src += env.Glob('libmv/simple_pipeline/*.cc')
|
|
|
|
src += env.Glob('libmv/tracking/*.cc')
|
|
|
|
src += env.Glob('third_party/gflags/*.cc')
|
|
|
|
|
2014-05-01 23:52:56 +00:00
|
|
|
incs += ' ../Eigen3 third_party/gflags third_party/glog/src third_party/ceres/include third_party/ceres/config ../../intern/guardedalloc'
|
2013-05-12 22:17:37 +00:00
|
|
|
incs += ' ' + env['BF_PNG_INC']
|
|
|
|
incs += ' ' + env['BF_ZLIB_INC']
|
|
|
|
|
|
|
|
if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'linuxcross', 'win64-vc', 'win64-mingw'):
|
|
|
|
incs += ' ./third_party/glog/src/windows ./third_party/glog/src/windows/glog'
|
|
|
|
if env['OURPLATFORM'] in ('win32-vc', 'win64-vc'):
|
|
|
|
incs += ' ./third_party/msinttypes'
|
|
|
|
|
|
|
|
src += ['./third_party/glog/src/logging.cc', './third_party/glog/src/raw_logging.cc', './third_party/glog/src/utilities.cc', './third_party/glog/src/vlog_is_on.cc']
|
|
|
|
src += ['./third_party/glog/src/windows/port.cc']
|
|
|
|
else:
|
|
|
|
src += env.Glob("third_party/glog/src/*.cc")
|
|
|
|
incs += ' ./third_party/glog/src'
|
2011-11-07 12:55:18 +00:00
|
|
|
else:
|
2014-09-25 11:01:06 +00:00
|
|
|
src = env.Glob("intern/stub.cc")
|
2011-11-07 12:55:18 +00:00
|
|
|
|
2014-06-18 12:49:17 +00:00
|
|
|
src = [src for src in src if src.find('_test.cc') == -1]
|
|
|
|
|
2013-09-09 16:24:23 +00:00
|
|
|
env.BlenderLib ( libname = 'extern_libmv', sources=src, includes=Split(incs), defines=defs, libtype=['extern', 'player'], priority=[20,137] )
|
2012-06-10 15:27:41 +00:00
|
|
|
|
2013-05-12 22:17:37 +00:00
|
|
|
if env['WITH_BF_LIBMV']:
|
|
|
|
SConscript(['third_party/SConscript'])
|