Last change
on this file since 1908 was 1135, checked in by mar637, 18 years ago |
more work on a modular scons set up
|
File size:
840 bytes
|
Line | |
---|
1 | import os,glob,shutil
|
---|
2 |
|
---|
3 | # import root environment
|
---|
4 | Import( "env")
|
---|
5 | myenv = env.Copy()
|
---|
6 |
|
---|
7 | # gather cpp files
|
---|
8 | cpps = env.SGlob("*.cpp")
|
---|
9 | pycpps = env.SGlob("python_*.cpp")
|
---|
10 | for pf in pycpps: cpps.remove(pf)
|
---|
11 |
|
---|
12 | casalibd = os.path.join(myenv['CASAROOT'],myenv['CASAARCH'],'lib')
|
---|
13 |
|
---|
14 | # location of libcasav.a
|
---|
15 | myenv.Prepend( LIBPATH = ['#/build'] )
|
---|
16 | myenv.Install('#build', os.path.join(casalibd, 'libwcs.a'))
|
---|
17 | myenv['SHLIBPREFIX']="" #gets rid of lib prefix
|
---|
18 |
|
---|
19 | # need to create library here to fool scons linker
|
---|
20 | casav = myenv.StaticLibrary(target = "casav", source = os.path.join(casalibd, 'version.o'))
|
---|
21 | libasap = myenv.StaticLibrary(target = "asap", source = cpps)
|
---|
22 | myenv.Prepend( LIBS = ['asap'] )
|
---|
23 |
|
---|
24 | # Finally create the library for the module
|
---|
25 | so = myenv.SharedLibrary( target = "_asap", source = pycpps )
|
---|
26 | #test = myenv.Program("test", cpps)
|
---|
27 | Return("so")
|
---|
28 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.