fix build issues with ncurses and qt