Add basic getopt code