Delay program validation until Texture units are asigned.

Hopefully this fixes #459. Also see #458.

Ping @izaid
I wondered why `self._build()` showed up twice in this function (here and on line ~202)