uses command line options library and other fixes.