Rewrote option processing library.