I have an SCons project set up as follows:
proj/
SConstruct
src/
c/
h/
app1/SConscript
app2/SConscript
...
All source/header files for each application are located in src/c and src/h.
- At first step I created a SConstruct in app1 which use the Repository function.
...
src=Split("main.c first.c second.c")
env = Environment(CC='g++', CCFLAGS=['-O0', '-ggdb'], CPPPATH=['.'])
env.Program('appone', src)
Repository("../src/c", "../src/h")
All works fine. scons found all necessary source/header files from repository to build the appone application.
But if I try to build appone hierarchical it will not work :-(
I renamed app1/SConstruct to app1/SConscript and put
SConscript('app1/SConscript')
into proj/SConstruct
Now I get following error:
scons: *** [app1/main.o] Source `app1/main.c' not found, needed by target `app1/main.o'.
How do I configure my proj/SConstruct or proj/app1/SConscript to search for all source files in my Repository directory?