- XCode project
- Scons :
scons stopped working for Os X in the last month (dont know when) :
* the '.' and '..' keywords in CCPPATH
are not recognized anymore for sconscripts compiling files at
a sub level
* when doing a scons clean, the 3 subdirs in build dir are removed
and scons then fail to recreate them (exten, intern, source)
this commit solve the first problem as a temp workaround
for the latter simply recreate the dirs manually
I will investigate that further when on vacations, which i should already
be.
;(
all 3 build systems are now working on Os X
35 lines
1.2 KiB
Python
35 lines
1.2 KiB
Python
#!/usr/bin/python
|
|
import sys
|
|
import os
|
|
|
|
Import ('cflags')
|
|
Import ('defines')
|
|
Import ('user_options_dict')
|
|
|
|
# TODO: make sure the makesdna program does not get installed on the system.
|
|
source_files = ['makesdna.c']
|
|
|
|
makesdna_tool = Environment (ENV = os.environ, CCFLAGS='-DBASE_HEADER="\\"source/blender/makesdna/\\"" ')
|
|
|
|
makesdna_tool.Append (CPPPATH = ['#/intern/guardedalloc',
|
|
'../../makesdna'])
|
|
|
|
makesdna_tool.Replace (CC = user_options_dict['HOST_CC'])
|
|
makesdna_tool.Replace (PATH = user_options_dict['PATH'])
|
|
|
|
if sys.platform != 'cygwin':
|
|
makesdna_tool.Append (CCFLAGS = cflags)
|
|
makesdna_tool.Append (LINKFLAGS = user_options_dict['PLATFORM_LINKFLAGS'])
|
|
makesdna_tool.Append (CPPDEFINES = defines)
|
|
makesdna_tool.Append (LIBPATH = '#'+user_options_dict['BUILD_DIR']+'/lib')
|
|
makesdna_tool.Append (LIBS = 'blender_guardedalloc')
|
|
makesdna_tool.Program (target = '#'+user_options_dict['BUILD_DIR']+'makesdna', source = source_files)
|
|
|
|
dna = Environment (ENV = os.environ)
|
|
dna_dict = dna.Dictionary()
|
|
makesdna_name = user_options_dict['BUILD_DIR']+'makesdna' + dna_dict['PROGSUFFIX']
|
|
dna.Depends ('dna.c', '#'+makesdna_name)
|
|
dna.Command ('dna.c', '', user_options_dict['BUILD_DIR']+"makesdna $TARGET")
|
|
obj = 'intern/dna.c'
|
|
Return ('obj')
|