Okay, I messed with these settings a bit and did some diffs of the generated build.ninja files, and it seems like this:
If you build a lib with include dirs and whatnot, you can put the include_directories and links_with in a declare_dependency object and just pass that as a dependency to the executable and it's exactly the same as if you'd separately passed the include_directories and links_with to the executable, so the declare_dependency object is just a way to wrap up the various params to another target so you don't have to have them all separate?
Chris