Merge with -r 22620:23107.
[blender.git] / tools / Blender.py
index 7979003..d0217e8 100644 (file)
@@ -101,7 +101,10 @@ def create_blender_liblist(lenv = None, libtype = None):
                sortlist.sort()
                for sk in sortlist:
                        v = curlib[sk]
-                       target = os.path.abspath(os.getcwd() + os.sep + root_build_dir + 'lib' + os.sep +lenv['LIBPREFIX'] + v + lenv['LIBSUFFIX'])
+                       if not (root_build_dir[0]==os.sep or root_build_dir[1]==':'):
+                               target = os.path.abspath(os.getcwd() + os.sep + root_build_dir + 'lib' + os.sep +lenv['LIBPREFIX'] + v + lenv['LIBSUFFIX'])
+                       else:
+                               target = os.path.abspath(root_build_dir + 'lib' + os.sep +lenv['LIBPREFIX'] + v + lenv['LIBSUFFIX'])
                        lst.append(target)
 
        return lst
@@ -132,6 +135,8 @@ def setup_staticlibs(lenv):
                libincs += Split(lenv['BF_FFMPEG_LIBPATH'])
        if lenv['WITH_BF_JACK']:
                libincs += Split(lenv['BF_JACK_LIBPATH'])
+       if lenv['WITH_BF_SNDFILE']:
+               libincs += Split(lenv['BF_SNDFILE_LIBPATH'])
        if lenv['WITH_BF_OPENEXR']:
                libincs += Split(lenv['BF_OPENEXR_LIBPATH'])
                if lenv['WITH_BF_STATICOPENEXR']:
@@ -167,8 +172,8 @@ def setup_syslibs(lenv):
                ]
 
        syslibs += Split(lenv['BF_FREETYPE_LIB'])
-       if lenv['WITH_BF_UNIT_TEST']:
-               syslibs.append(lenv['BF_CHECK_LIB'])
+       # if lenv['BF_UNIT_TEST']:
+       #       syslibs.append(lenv['BF_CHECK_LIB'])
        if lenv['WITH_BF_PYTHON'] and not lenv['WITH_BF_STATICPYTHON']:
                if lenv['BF_DEBUG'] and lenv['OURPLATFORM'] in ('win32-vc', 'win64-vc'):
                        syslibs.append(lenv['BF_PYTHON_LIB']+'_d')
@@ -195,6 +200,8 @@ def setup_syslibs(lenv):
                        syslibs += Split(lenv['BF_OGG_LIB'])
        if lenv['WITH_BF_JACK']:
                        syslibs += Split(lenv['BF_JACK_LIB'])
+       if lenv['WITH_BF_SNDFILE']:
+                       syslibs += Split(lenv['BF_SNDFILE_LIB'])
        if lenv['WITH_BF_FFTW3']:
                syslibs += Split(lenv['BF_FFTW3_LIB'])
        if lenv['WITH_BF_SDL']:
@@ -465,7 +472,11 @@ class BlenderEnvironment(SConsEnvironment):
                
                print bc.HEADER+'Configuring resource '+bc.ENDC+bc.OKGREEN+libname+bc.ENDC
                lenv = self.Clone()
-               res = lenv.RES('#'+root_build_dir+'lib/'+libname, source)
+               if not (root_build_dir[0]==os.sep or root_build_dir[1]==':'):
+                       res = lenv.RES('#'+root_build_dir+'lib/'+libname, source)
+               else:
+                       res = lenv.RES(root_build_dir+'lib/'+libname, source)
+
                
                SConsEnvironment.Default(self, res)
                resources.append(res)