Use separate opts object for each file

This seems to fix #134. I am not sure about the performance implications (will this make things significantly slower?).