diff options
-rw-r--r-- | SConstruct | 2 | ||||
-rw-r--r-- | source/SConscript | 3 | ||||
-rw-r--r-- | source/icons/SConscript | 6 | ||||
-rw-r--r-- | source/icons/winblender.rcscons | 2 | ||||
-rw-r--r-- | tools/Blender.py | 20 |
5 files changed, 32 insertions, 1 deletions
diff --git a/SConstruct b/SConstruct index d16fd9a292b..62c41d0c331 100644 --- a/SConstruct +++ b/SConstruct @@ -228,7 +228,7 @@ for tp in B.possible_types: if B.arguments.get('BF_PRIORITYLIST', '0')=='1': B.propose_priorities() -dobj = B.buildinfo(env, "dynamic") +dobj = B.buildinfo(env, "dynamic") + B.resources thestatlibs, thelibincs = B.setup_staticlibs(env) thesyslibs = B.setup_syslibs(env) diff --git a/source/SConscript b/source/SConscript index fb215ba3796..ca264579f6e 100644 --- a/source/SConscript +++ b/source/SConscript @@ -6,3 +6,6 @@ SConscript(['blender/SConscript', 'creator/SConscript']) if env['WITH_BF_GAMEENGINE'] == 1: SConscript (['gameengine/SConscript']) + +if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw'): + SConscript (['icons/SConscript']) diff --git a/source/icons/SConscript b/source/icons/SConscript new file mode 100644 index 00000000000..ccd7591b2bb --- /dev/null +++ b/source/icons/SConscript @@ -0,0 +1,6 @@ +#!/usr/bin/python +Import ('env') + +source = 'winblender_scons.rc' + +env.BlenderRes('winresource', source, ['core', 'player'], priority=[95 , 100])
\ No newline at end of file diff --git a/source/icons/winblender.rcscons b/source/icons/winblender.rcscons new file mode 100644 index 00000000000..97579f1ffe0 --- /dev/null +++ b/source/icons/winblender.rcscons @@ -0,0 +1,2 @@ +APPICON ICON "source\\icons\\winblender.ico" +BLENDERFILE ICON "source\\icons\\winblenderfile.ico" diff --git a/tools/Blender.py b/tools/Blender.py index f87cbacf142..bf938686af8 100644 --- a/tools/Blender.py +++ b/tools/Blender.py @@ -39,6 +39,7 @@ quicklist = [] # The list of libraries/programs to compile during a quickie program_list = [] # A list holding Nodes to final binaries, used to create installs arguments = None targets = None +resources = [] #some internals blenderdeps = [] # don't manipulate this one outside this module! @@ -47,6 +48,10 @@ blenderdeps = [] # don't manipulate this one outside this module! possible_types = ['core'] # can be set in ie. SConstruct libs = {} + +def getresources(): + return resources + def init_lib_dict(): for pt in possible_types: libs[pt] = {} @@ -317,6 +322,21 @@ def AppIt(target=None, source=None, env=None): class BlenderEnvironment(SConsEnvironment): + def BlenderRes(self=None, libname=None, source=None, libtype=['core'], priority=[100]): + global libs + if not self or not libname or not source: + print bc.FAIL+'Cannot continue. Missing argument for BlenderRes '+libname+bc.ENDC + Exit() + if self['OURPLATFORM'] not in ('win32-vc','win32-mingw'): + print bc.FAIL+'BlenderRes is for windows only!'+bc.END + Exit() + + print bc.HEADER+'Configuring resource '+bc.ENDC+bc.OKGREEN+libname+bc.ENDC + lenv = self.Copy() + res = lenv.RES('#'+root_build_dir+'lib/'+libname, source) + + SConsEnvironment.Default(self, res) + resources.append(res) def BlenderLib(self=None, libname=None, sources=None, includes=[], defines=[], libtype='common', priority = 100, compileflags=None): if not self or not libname or not sources: |