On Wed, 5 Sep 2018, Andrew Stubbs wrote:

> +       warning_at (decl ? DECL_SOURCE_LOCATION (decl) : UNKNOWN_LOCATION,
> +                   OPT_Wopenacc_dims,
> +                   (dims[GOMP_DIM_VECTOR]
> +                    ? "using vector_length (64), ignoring %d"
> +                    : "using vector_length (64), ignoring runtime setting"),

In cases like this with alternative diagnostic messages using ?:, you need 
to mark up each message with G_() so they both get extracted for 
translation by exgettext.

> +    fatal_error (input_location, "COLLECT_GCC must be set.");

No '.' at end of diagnostic.

> +#define STR "-foffload-abi="

> +           fatal_error (input_location,
> +                        "unrecognizable argument of option " STR);

This concatenation with a macro won't work with exgettext extracting 
messages for translation.

> +    fatal_error (input_location, "cannot open '%s'", gcn_s2_name);

> +    fatal_error (input_location, "cannot open '%s'", gcn_cfile_name);

Use %qs (presuming this code is using the generic diagnostic machinery 
that supports it).

+gcn-run$(exeext): gcn-run.o
+       +$(LINKER) $(ALL_LINKERFLAGS) $(LDFLAGS) -o $@ $< -ldl

I'd expect this to fail on non-Unix configurations that don't have -ldl, 
and thus to need appropriate conditionals / configure tests to avoid that 
build failure.

A new port should add an appropriate entry to contrib/config-list.mk.  
You should also verify that the port does build using that 
contrib/config-list.mk entry, with the same version of GCC, built 
natively, in the PATH, or equivalently that the port builds with the same 
version of GCC, built natively, in the PATH, when you configure with 
--enable-werror-always and the other options config-list.mk uses - this is 
the cross-compiler equivalent of the native use of -Werror in the later 
stages of bootstrap.  (Preferably verify this building for both 32-bit and 
64-bit hosts, since it's easy to have warnings that only show up for one 
but not the other.)

-- 
Joseph S. Myers
jos...@codesourcery.com

Reply via email to