Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Musgrove <LetterRip@gmail.com>2010-02-01 21:39:41 +0300
committerTom Musgrove <LetterRip@gmail.com>2010-02-01 21:39:41 +0300
commitf2a8bb34989204dbdfee39cc6279808b5d5a8c9a (patch)
treedf7bfbcac23d77e1d38c5c9a70ff9740c0028aec /SConstruct
parent7fe3ab7e8e23fb8750eead8f53802928b734821c (diff)
this restores building on mingw with Collada support, also it restores cross compiling, thanks to Sergey Sharybin for the patch. Note that the icons for linux cross might not be committed here, if not i'll add them in another commit
Diffstat (limited to 'SConstruct')
-rw-r--r--SConstruct69
1 files changed, 46 insertions, 23 deletions
diff --git a/SConstruct b/SConstruct
index 354915541b8..837edb94d86 100644
--- a/SConstruct
+++ b/SConstruct
@@ -169,7 +169,9 @@ if crossbuild and env['PLATFORM'] != 'win32':
env.Tool('crossmingw', ['tools'])
# todo: determine proper libs/includes etc.
# Needed for gui programs, console programs should do without it
- env.Append(LINKFLAGS=['-mwindows'])
+
+ # Now we don't need this option to have console window
+ # env.Append(LINKFLAGS=['-mwindows'])
userconfig = B.arguments.get('BF_CONFIG', 'user-config.py')
# first read platform config. B.arguments will override
@@ -524,7 +526,11 @@ if env['OURPLATFORM']=='linux2':
# TODO - add more libs, for now this lets blenderlite run
if env['OURPLATFORM']=='linuxcross':
dir=env['BF_INSTALLDIR']
- source = ['../lib/windows/pthreads/lib/pthreadGC2.dll']
+ source = []
+
+ if env['WITH_BF_OPENMP']:
+ source += ['../lib/windows/pthreads/lib/pthreadGC2.dll']
+
scriptinstall.append(env.Install(dir=dir, source=source))
#-- plugins
@@ -577,49 +583,66 @@ elif env['OURPLATFORM']=='linux2':
else:
allinstall = [blenderinstall, dotblenderinstall, scriptinstall, plugininstall, textinstall]
-if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'win64-vc'):
+if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'win64-vc', 'linuxcross'):
dllsources = []
- if env['OURPLATFORM'] != 'win64-vc':
- if env['OURPLATFORM'] != 'win32-mingw':
- # For MinGW static linking will be used
- dllsources += ['${LCGDIR}/gettext/lib/gnu_gettext.dll']
-
- dllsources += ['${BF_PNG_LIBPATH}/libpng.dll',
- '${BF_ZLIB_LIBPATH}/zlib.dll',
- '${BF_TIFF_LIBPATH}/${BF_TIFF_LIB}.dll']
- dllsources += ['${BF_PTHREADS_LIBPATH}/${BF_PTHREADS_LIB}.dll']
+ if not env['OURPLATFORM'] in ('win32-mingw', 'win64-vc', 'linuxcross'):
+ # For MinGW and linuxcross static linking will be used
+ dllsources += ['${LCGDIR}/gettext/lib/gnu_gettext.dll']
+
+ dllsources += ['${BF_PNG_LIBPATH}/libpng.dll',
+ '${BF_ZLIB_LIBPATH}/zlib.dll',
+ '${BF_TIFF_LIBPATH}/${BF_TIFF_LIB}.dll']
+
+ if env['OURPLATFORM'] != 'linuxcross':
+ # pthreads library is already added
+ dllsources += ['${BF_PTHREADS_LIBPATH}/${BF_PTHREADS_LIB}.dll']
+
if env['WITH_BF_SDL']:
if env['OURPLATFORM'] == 'win64-vc':
pass # we link statically already to SDL on win64
else:
dllsources.append('${BF_SDL_LIBPATH}/SDL.dll')
+
if env['WITH_BF_PYTHON']:
if env['BF_DEBUG']:
dllsources.append('${BF_PYTHON_LIBPATH}/${BF_PYTHON_DLL}_d.dll')
else:
dllsources.append('${BF_PYTHON_LIBPATH}/${BF_PYTHON_DLL}.dll')
+
if env['WITH_BF_ICONV']:
if env['OURPLATFORM'] == 'win64-vc':
pass # we link statically to iconv on win64
- elif env['OURPLATFORM'] != 'win32-mingw':
- #gettext for MinGW is compiled staticly
+ elif not env['OURPLATFORM'] in ('win32-mingw', 'linuxcross'):
+ #gettext for MinGW and cross-compilation is compiled staticly
dllsources += ['${BF_ICONV_LIBPATH}/iconv.dll']
+
if env['WITH_BF_OPENAL']:
dllsources.append('${LCGDIR}/openal/lib/OpenAL32.dll')
dllsources.append('${LCGDIR}/openal/lib/wrap_oal.dll')
+
if env['WITH_BF_SNDFILE']:
dllsources.append('${LCGDIR}/sndfile/lib/libsndfile-1.dll')
+
if env['WITH_BF_FFMPEG']:
- dllsources += ['${LCGDIR}/ffmpeg/lib/avcodec-52.dll',
- '${LCGDIR}/ffmpeg/lib/avformat-52.dll',
- '${LCGDIR}/ffmpeg/lib/avdevice-52.dll',
- '${LCGDIR}/ffmpeg/lib/avutil-50.dll',
- '${LCGDIR}/ffmpeg/lib/swscale-0.dll',
- '${LCGDIR}/ffmpeg/lib/libfaac-0.dll',
- '${LCGDIR}/ffmpeg/lib/libfaad-2.dll',
- '${LCGDIR}/ffmpeg/lib/libmp3lame-0.dll',
- '${LCGDIR}/ffmpeg/lib/libx264-67.dll']
+ dllsources += ['${BF_FFMPEG_LIBPATH}/avcodec-52.dll',
+ '${BF_FFMPEG_LIBPATH}/avformat-52.dll',
+ '${BF_FFMPEG_LIBPATH}/avdevice-52.dll',
+ '${BF_FFMPEG_LIBPATH}/avutil-50.dll',
+ '${BF_FFMPEG_LIBPATH}/swscale-0.dll']
+
+ if env['OURPLATFORM'] != 'linuxcross':
+ #
+ # TODO: Does it mean we haven't got support of this codecs if
+ # we're using cross-compilation?
+ # Or in case of native compilation this libraries are
+ # unneccessary to?
+ #
+ dllsources += ['${LCGDIR}/ffmpeg/lib/libfaac-0.dll',
+ '${LCGDIR}/ffmpeg/lib/libfaad-2.dll',
+ '${LCGDIR}/ffmpeg/lib/libmp3lame-0.dll',
+ '${LCGDIR}/ffmpeg/lib/libx264-67.dll']
+
if env['WITH_BF_JACK']:
dllsources += ['${LCGDIR}/jack/lib/libjack.dll']
windlls = env.Install(dir=env['BF_INSTALLDIR'], source = dllsources)