Add target flags to ubsan tests