Added functionality for separate cap files.