/[ascend]/trunk/base/generic/test/SConscript
ViewVC logotype

Diff of /trunk/base/generic/test/SConscript

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1028 by johnpye, Sat Dec 30 14:27:47 2006 UTC revision 1029 by johnpye, Wed Jan 3 14:00:27 2007 UTC
# Line 1  Line 1 
1  Import('env')  Import('env')
2    import platform
3    
4  testsrcs = ['#test/'+i for i in Split("""  testsrcs = ['#test/'+i for i in Split("""
5    assertimpl.c    assertimpl.c
# Line 21  if env.has_key('CUNIT_LIBPATH'): Line 22  if env.has_key('CUNIT_LIBPATH'):
22      libpath.append(env['CUNIT_LIBPATH'])      libpath.append(env['CUNIT_LIBPATH'])
23      #print "CUNIT_LIBPATH ---> ",libpath      #print "CUNIT_LIBPATH ---> ",libpath
24    
25    cppdefines = []
26    if env.has_key('CPPDEFINES'):
27        cppdefines += env.get('CPPDEFINES')
28    cppdefines += ['-DASC_SHARED']
29    
30    libs = ['ascend','m','cunit']
31    if platform.system()!="Windows":
32        libs += ['dl']
33    
34  objs = []  objs = []
35  for src in srcs+testsrcs:  for src in srcs+testsrcs:
36      objs += env.SharedObject(src      objs += env.SharedObject(src
37          , CPPPATH = cpppath          , CPPPATH = cpppath
38      )      )
39    
40  objs += env.SharedObject('test_ascend_base.c'  objs += env.SharedObject('test_ascend_base.c'
41          , CPPPATH = cpppath          , CPPPATH = cpppath
42      )      )
43    
44    print "OBJS = "
45    for o in objs:
46        print o
47    
48  env.SharedLibrary('asctestsuite',objs  env.SharedLibrary('asctestsuite',objs
49      , CPPPATH = cpppath      , CPPPATH = cpppath
50      , LIBS = ['ascend','m','cunit','dl']      , LIBS = libs
51      , LIBPATH = libpath      , LIBPATH = libpath
52      , CPPDEFINES = env.get('CPPDEFINES') + ['-DASC_SHARED']      , CPPDEFINES = cppdefines
53  )  )
54    
55  env.Program('test',['test.c']  env.Program('test',['test.c']

Legend:
Removed from v.1028  
changed lines
  Added in v.1029

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22