Fix detected flags from ACX_PTHREAD being reset.