Mercurial > fife-parpg
comparison engine/SConscript @ 52:ab8b11adfb70
* Fixing code::blocks support for win32 (thanks to jasoka)
* WIP README for the upcoming release
author | mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Sun, 13 Jul 2008 16:11:24 +0000 |
parents | b3838661971f |
children | ea04dfe54aae |
comparison
equal
deleted
inserted
replaced
51:191654cf9855 | 52:ab8b11adfb70 |
---|---|
223 projtxt = projtxt.replace('__FILE_INSERTION_POINT__', '\n'.join(xmlstr)) | 223 projtxt = projtxt.replace('__FILE_INSERTION_POINT__', '\n'.join(xmlstr)) |
224 open(str(target[0]), 'w').write(projtxt) | 224 open(str(target[0]), 'w').write(projtxt) |
225 print "FIFE code::blocks project file succesfully created (%s)" % os.path.abspath(str(target[0])) | 225 print "FIFE code::blocks project file succesfully created (%s)" % os.path.abspath(str(target[0])) |
226 | 226 |
227 codeblocks_project_builder_win32 = Builder(action = generate_codeblocks_project_win32, suffix = '.cbp') | 227 codeblocks_project_builder_win32 = Builder(action = generate_codeblocks_project_win32, suffix = '.cbp') |
228 env.Append(BUILDERS = {'CodeblocksProject': codeblocks_project_builder_win32}) | 228 env.Append(BUILDERS = {'CodeblocksProjectWin32': codeblocks_project_builder_win32}) |
229 | 229 |
230 | 230 |
231 cbbuildpath_linux = joinpath('build', 'linux', 'code_blocks') | 231 cbbuildpath_linux = joinpath('build', 'linux', 'code_blocks') |
232 | 232 |
233 def generate_codeblocks_project_linux(target, source, env): | 233 def generate_codeblocks_project_linux(target, source, env): |
256 projtxt = projtxt.replace('__FILE_INSERTION_POINT__', '\n'.join(xmlstr)) | 256 projtxt = projtxt.replace('__FILE_INSERTION_POINT__', '\n'.join(xmlstr)) |
257 open(str(target[0]), 'w').write(projtxt) | 257 open(str(target[0]), 'w').write(projtxt) |
258 print "FIFE code::blocks project file succesfully created (%s)" % os.path.abspath(str(target[0])) | 258 print "FIFE code::blocks project file succesfully created (%s)" % os.path.abspath(str(target[0])) |
259 | 259 |
260 codeblocks_project_builder_linux = Builder(action = generate_codeblocks_project_linux, suffix = '.cbp') | 260 codeblocks_project_builder_linux = Builder(action = generate_codeblocks_project_linux, suffix = '.cbp') |
261 env.Append(BUILDERS = {'CodeblocksProject': codeblocks_project_builder_linux}) | 261 env.Append(BUILDERS = {'CodeblocksProjectLinux': codeblocks_project_builder_linux}) |
262 | 262 |
263 | 263 |
264 variated_dirs = eval(open(joinpath('config', 'variated_dirs'), 'r').read()) | 264 variated_dirs = eval(open(joinpath('config', 'variated_dirs'), 'r').read()) |
265 # filter out swigwrappers. fife_wrap.cxx is appended manually | 265 # filter out swigwrappers. fife_wrap.cxx is appended manually |
266 # as it might not exist yet during SConscript parsing | 266 # as it might not exist yet during SConscript parsing |
294 | 294 |
295 projectfiles.append('./swigwrappers/%s/fife_wrap.cxx' % env['script']) | 295 projectfiles.append('./swigwrappers/%s/fife_wrap.cxx' % env['script']) |
296 | 296 |
297 msvcproj = env.MSVCProject(joinpath('..', msvcbuildpath, 'fife'), projectfiles) | 297 msvcproj = env.MSVCProject(joinpath('..', msvcbuildpath, 'fife'), projectfiles) |
298 msvcproj9 = env.MSVCProject9(joinpath('..', msvcbuildpath9, 'fife'), projectfiles) | 298 msvcproj9 = env.MSVCProject9(joinpath('..', msvcbuildpath9, 'fife'), projectfiles) |
299 cbproj_win32 = env.CodeblocksProject(joinpath('..', cbbuildpath_win32, 'fife_engine'), projectfiles) | 299 cbproj_win32 = env.CodeblocksProjectWin32(joinpath('..', cbbuildpath_win32, 'fife_engine'), projectfiles) |
300 cbproj_linux = env.CodeblocksProject(joinpath('..', cbbuildpath_linux, 'fife_engine'), projectfiles) | 300 cbproj_linux = env.CodeblocksProjectLinux(joinpath('..', cbbuildpath_linux, 'fife_engine'), projectfiles) |
301 | 301 |
302 if not env['projectfiles_only']: | 302 if not env['projectfiles_only']: |
303 env.Append(CPPPATH = ['#/engine/core', '#/engine/swigwrappers']) | 303 env.Append(CPPPATH = ['#/engine/core', '#/engine/swigwrappers']) |
304 compilefiles = [str(f) for f in remove_based_on_dir_filter(filteredpaths, implfiles)] | 304 compilefiles = [str(f) for f in remove_based_on_dir_filter(filteredpaths, implfiles)] |
305 compilefiles.append('./swigwrappers/%s/fife_wrap.cxx' % env['script']) | 305 compilefiles.append('./swigwrappers/%s/fife_wrap.cxx' % env['script']) |