Building base material undump script.

Based on an idea in https://github.com/peterix/dfhack/issues/119