Allow variables from indirect dependencies to bubble up

The previous implementation was a function, which although OK from an
implementation standpoint -- the local variables doesn't pollute the
global namespace -- would not allow variables that were set in indirect
dependencies to bubble up to the main module. This is a problem for
modules which are dependent on configuration variables to be present.