Fixed handling of template options with undefined value; updated build

A template option which exists, but has an undefined value, no longer overwrites a template class property.