Added compiler directive to include getopt.h on qt versions >= 4.8