SparkBuild Community

Pushing the envelope of build performance

Environment variables are not getting passed to sub-makes (continued).

EM:

The Forum's reply doesn't seem to allow attaches, so I have continued in a new thread.

XML output from emke is attached.

Thanks.

David

Views: 6

Attachments:

Reply to This

Replies to This Discussion

I see that the submake that is missing the environment variable is actually created as a subbuild job, which means that the environment it uses is coming from the subbuild db. That means that your subbuild db may be invalid -- is it possible that it was generated from an incomplete or incorrect build?

I suggest you try deleting the subbuild db, then regenerate it from a new clean full build.

Let us know if that helps.
EM:

Did a clean and a full build. Now I can't get it to even try to build targets in other makefiles. After the full build, I deleted a library that is built in a different makefile to see if it would be rebuilt, but all I get is an error.

W:\dward_JELProject\JEL\jel\state\unittest>C:\SparkBuild\i686_win32\bin\emake.exe --emake-subbuild-db=W:\dward_JELProject\JEL\emake.subbuild.db -
-win32 buildType=debug
make: *** No rule to make target `W:/dward_JELProject/JEL/x86-win32-msvc90/debug/lib/libjeltrace.lib', needed by `W:/dward_JELProject/JEL/x86-win
32-msvc90/debug/bin/unittest/TestJelState.exe'. Stop.

I guess our make environment is just too convoluted to be figured out by SparkBuild.

David
EM:

I did one more thing. Instead of doing a clean first, I just built everything with gen=1. I didn't build much because not much was changed, but it did go through all of the makefiles. This built the database, but gives me the original problem I had with missing environment variables.

Maybe I misunderstood when I watched the tutorial.

Does SparkBuild require a full build after a complete clean to successfully rebuild its database? If that's the case, I think that means you have to rebuild the database everytime you add a *.cpp file to a makefile. I think that also means you have to do it every time you add a new header file.

If that's the case, that's not very productive because full system builds take very long periods of time.

David
The dependencies tracked in the sparkbuild db depends on how you structured your makefiles. If you made *.cpp files depend on outputs generated by other submakes, then yes, every time you add a .cpp file to your build you have to regenerate the database. Generally you wouldn't make .cpp files depend on other outputs but instead make outputs depend on outputs (e.g. foo.o depending on bar/bar.o).

Can you please attach the subbuild db that was generated from a full build that was done after a clean build? And please also generate a debug log using --emake-debug=jpn --emake-logfile=dlog and then attach the dlog file as well.

RSS

Share

© 2012   Created by Electric Cloud Administrator.

Badges  |  Report an Issue  |  Terms of Service