Attempt at fixing the windows dll build.

It looks like only direct (i.e., explicitly listed) dependencies are
scanned.