am 30090e41: Set the intermediate dirs before using them.

Merge commit '30090e41e31e7db34a1092d8173c1413c036b49d' into gingerbread-plus-aosp

* commit '30090e41e31e7db34a1092d8173c1413c036b49d':
  Set the intermediate dirs before using them.