/[escript]/branches/arrayview_from_1695_trunk/esysUtils/test/SConscript
ViewVC logotype

Annotation of /branches/arrayview_from_1695_trunk/esysUtils/test/SConscript

Parent Directory Parent Directory | Revision Log Revision Log


Revision 682 - (hide annotations)
Mon Mar 27 02:43:09 2006 UTC (13 years, 5 months ago) by robwdcock
Original Path: trunk/esysUtils/test/EsysException/SConscript
File size: 1061 byte(s)
+ NEW BUILD SYSTEM

This commit contains the new build system with cross-platform support.
Most things work are before though you can have more control.

ENVIRONMENT settings have changed:
+ You no longer require LD_LIBRARY_PATH or PYTHONPATH to point to the
esysroot for building and testing performed via scons
+ ACcESS altix users: It is recommended you change your modules to load
the latest intel compiler and other libraries required by boost to match
the setup in svn (you can override). The correct modules are as follows

module load intel_cc.9.0.026
export
MODULEPATH=${MODULEPATH}:/data/raid2/toolspp4/modulefiles/gcc-3.3.6
module load boost/1.33.0/python-2.4.1
module load python/2.4.1
module load numarray/1.3.3


1 robwdcock 682 Import('*')
2     # FIXME: This whole test should be refactored into the directory above as esysUtils_UnitTest so it is the same as the other modules
3 jgs 455
4 robwdcock 682 program_name = 'EsysExceptionTest'
5 jgs 455
6 robwdcock 682 local_env=env.Copy()
7 jgs 197
8 robwdcock 682 local_env.Append(LIBS=['esysUtils', 'CppUnitTest', sys_libs])
9 jgs 227
10 robwdcock 682 src_dir = local_env.Dir('.').srcnode().abspath
11 jgs 227
12 robwdcock 682 import os
13     filenames = os.listdir(src_dir)
14     sources = [x for x in filenames if os.path.splitext(x)[1] in ['.cpp', '.c']]
15 jgs 227
16 robwdcock 682 local_env.Append(CPPPATH = ['#/tools/CppUnitTest/inc',])
17 jgs 227
18 robwdcock 682 program = local_env.Program(program_name, sources)
19 jgs 197
20 robwdcock 682 Depends(program, dep_lib)
21 jgs 197
22 robwdcock 682 # TODO: Need to decide on how the library paths etc are going to be handled
23     # TODO: For now just install the program to the same location as the libraries so things can run at least
24     test_install = local_env.Install(libinstall, program)
25 jgs 306
26 robwdcock 682 #Add Unit Test to target alias
27 jgs 306
28 robwdcock 682 env.Alias('build_tests', test_install)
29 jgs 197
30 robwdcock 682 # run the tests - but only if test_targets are stale
31     local_env.RunUnitTest(program_name)
32     test_targets = os.path.splitext(program_name)[0]+'.passed'
33     Alias("run_tests", test_targets)

  ViewVC Help
Powered by ViewVC 1.1.26