This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 4/4] compile: Add 'set compile-gcc'


> From: Jan Kratochvil <jan.kratochvil@redhat.com>
> Cc: Phil Muldoon <pmuldoon@redhat.com>
> Date: Tue, 21 Apr 2015 23:36:57 +0200
> 
> parameter of GCC's set_arguments.  GCC decides on the meaning of the
> triplet_regexp parameter according to the success of:
> 
> +  if (access (triplet_regexp, X_OK) == 0)

Does triplet_regexp include the .exe extension on platforms that need
it?  Otherwise, 'access' will fail on those platforms.  (Sorry,
couldn't see where's the actual code, so couldn't verify that myself.)

> +  add_setshow_string_cmd ("compile-gcc", class_support,
> +			  &compile_gcc,
> +			  _("Set compile command GCC driver filename"),
> +			  _("Show compile command GCC driver filename"),
> +			  _("\
> +It should be absolute pathname to the gcc executable.\n\
> +If empty the default target triplet will be searched in $PATH."),
> +			  NULL, show_compile_gcc, &setlist, &showlist);

This doesn't offer file-name completion, does it?  I think it should.

> +                          By default the environment variable
> +@code{PATH} (@code{PATH} from shell that executed @value{GDBN}, not the
> +one set by @value{GDBN} command @code{set environment}).

This sentence is incomplete, I think you need to combine it with the
next one.  (I suggest to say the simple thing first, and then add the
caveat about which PATH is searched, instead of having the caveat in
the middle, making it harder to comprehend.)

> +Besides the compiler driver @value{GDBN} needs also shared library
> +@file{libcc1.so}.  It is searched in default shared library search path
> +(overridable with usual environment variable @code{LD_LIBRARY_PATH}),
> +unrelated to @code{PATH} or @code{set compile-gcc} settings.

This is Unix logic, btw.  On Windows, libcc1.dll will either be in the
same directory where the GCC driver is, or on PATH, or in libexec.  So
maybe you should qualify the above by saying this is on Posix hosts;
we could then amend it when this is supported on Windows (assuming it
isn't for now).


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]