public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers
@ 2013-08-08  0:03 brooks at gcc dot gnu.org
  2013-08-08  0:06 ` [Bug build/15823] " brooks at gcc dot gnu.org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: brooks at gcc dot gnu.org @ 2013-08-08  0:03 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

            Bug ID: 15823
           Summary: Host rpcgen is sort of fundamentally broken for
                    cross-compilers
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: build
          Assignee: unassigned at sourceware dot org
          Reporter: brooks at gcc dot gnu.org
                CC: carlos at redhat dot com

The rpggen program will, by default, call "/lib/cpp" as the cpp executable (see
line 81 of rpc-main.c).

If a user passes a -Y option defining a directory, it will instead append
"/cpp" to that directory name, and use that instead.  (line 1319, rpc-main.c)

Thus, it is hardcoded that the name of the cpp executable must be "cpp".

However, we find that, due to
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42955, GCC does not ship a working
executable named "cpp" -- and has not for many years.  (The bug is that GCC's
$target/bin/cpp is broken; only bin/$target-cpp works.)

There are of course workarounds; the glibc sunrpc/Makefile itself uses one by
defining a CPP variable and then pointing -Y at a "scripts" directory
containing a "cpp" shell script that simply executes ${CPP} $@.  However, this
workaround requires every user of rpcgen to set up such a wrapper script.

It would be notably better if we could simply provide a true cpp executable
name to rpcgen directly.  I note that there is not even any apparent benefit to
having the user specify a directory rather than a complete path to the
executable; the path is used for nothing else.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
@ 2013-08-08  0:06 ` brooks at gcc dot gnu.org
  2013-08-08  0:07 ` carlos at redhat dot com
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: brooks at gcc dot gnu.org @ 2013-08-08  0:06 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #1 from Brooks Moses <brooks at gcc dot gnu.org> ---
Correction: GCC _when compiled as a cross-compiler_ does not ship a working
executable named "cpp".  I inadvertently left out that caveat.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
  2013-08-08  0:06 ` [Bug build/15823] " brooks at gcc dot gnu.org
@ 2013-08-08  0:07 ` carlos at redhat dot com
  2013-08-08  1:08 ` joseph at codesourcery dot com
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: carlos at redhat dot com @ 2013-08-08  0:07 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #2 from Carlos O'Donell <carlos at redhat dot com> ---
(In reply to Brooks Moses from comment #0)
> It would be notably better if we could simply provide a true cpp executable
> name to rpcgen directly.  I note that there is not even any apparent benefit
> to having the user specify a directory rather than a complete path to the
> executable; the path is used for nothing else.

Agreed. I'd accept a patch that does that.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
  2013-08-08  0:06 ` [Bug build/15823] " brooks at gcc dot gnu.org
  2013-08-08  0:07 ` carlos at redhat dot com
@ 2013-08-08  1:08 ` joseph at codesourcery dot com
  2013-08-08  1:15 ` carlos at redhat dot com
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: joseph at codesourcery dot com @ 2013-08-08  1:08 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #3 from joseph at codesourcery dot com <joseph at codesourcery dot com> ---
On Thu, 8 Aug 2013, brooks at gcc dot gnu.org wrote:

> However, we find that, due to
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42955, GCC does not ship a working
> executable named "cpp" -- and has not for many years.  (The bug is that GCC's
> $target/bin/cpp is broken; only bin/$target-cpp works.)

I'd say the bug is installing the files in $target/bin/ at all.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (2 preceding siblings ...)
  2013-08-08  1:08 ` joseph at codesourcery dot com
@ 2013-08-08  1:15 ` carlos at redhat dot com
  2013-08-08  1:20 ` brooks at gcc dot gnu.org
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: carlos at redhat dot com @ 2013-08-08  1:15 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #4 from Carlos O'Donell <carlos at redhat dot com> ---
(In reply to joseph@codesourcery.com from comment #3)
> On Thu, 8 Aug 2013, brooks at gcc dot gnu.org wrote:
> 
> > However, we find that, due to
> > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42955, GCC does not ship a working
> > executable named "cpp" -- and has not for many years.  (The bug is that GCC's
> > $target/bin/cpp is broken; only bin/$target-cpp works.)
> 
> I'd say the bug is installing the files in $target/bin/ at all.

Which is orthogonal to the enhancement of allowing the user to select the cpp
executable to use when running rpcgen.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (3 preceding siblings ...)
  2013-08-08  1:15 ` carlos at redhat dot com
@ 2013-08-08  1:20 ` brooks at gcc dot gnu.org
  2013-08-08  1:34 ` carlos at redhat dot com
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: brooks at gcc dot gnu.org @ 2013-08-08  1:20 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #5 from Brooks Moses <brooks at gcc dot gnu.org> ---
(In reply to joseph@codesourcery.com from comment #3)
> The bug is that GCC's $target/bin/cpp is broken; only bin/$target-cpp works.
> 
> I'd say the bug is installing the files in $target/bin/ at all.

I.e., that there should only be bin/$target-gcc and so forth?

The fun thing there, of course, is that if you remove things like
$target/bin/as, then GCC doesn't know where to find an assembler unless you
explicitly point it at bin/$target-as.  Which is arguably just more of the same
bug.

Anyway, an interesting suggestion, if you want to post it into the GCC bug
report, and I'd be awfully tempted to implement it.

I mildly disagree with Carlos; it is not _entirely_ orthogonal so much as
reinforcing the point that the right fix is the proposed enhancement, rather
than "just go fix the GCC bug".  But I mildly disagree with him only in the
spirit of agreeing with him that it's off-topic.  :)

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (4 preceding siblings ...)
  2013-08-08  1:20 ` brooks at gcc dot gnu.org
@ 2013-08-08  1:34 ` carlos at redhat dot com
  2013-08-08  8:39 ` schwab@linux-m68k.org
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: carlos at redhat dot com @ 2013-08-08  1:34 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #6 from Carlos O'Donell <carlos at redhat dot com> ---
(In reply to Brooks Moses from comment #5)
> I mildly disagree with Carlos; it is not _entirely_ orthogonal so much as
> reinforcing the point that the right fix is the proposed enhancement, rather
> than "just go fix the GCC bug".  But I mildly disagree with him only in the
> spirit of agreeing with him that it's off-topic.  :)

I mildly disagree with your mild disagreement.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (5 preceding siblings ...)
  2013-08-08  1:34 ` carlos at redhat dot com
@ 2013-08-08  8:39 ` schwab@linux-m68k.org
  2013-08-08 15:44 ` joseph at codesourcery dot com
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: schwab@linux-m68k.org @ 2013-08-08  8:39 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #7 from Andreas Schwab <schwab@linux-m68k.org> ---
(In reply to joseph@codesourcery.com from comment #3)
> I'd say the bug is installing the files in $target/bin/ at all.

Interestingly, GCC does that only if $target/bin exists.  It doesn't create
that directory on its own.

(In reply to Brooks Moses from comment #5)
> The fun thing there, of course, is that if you remove things like
> $target/bin/as, then GCC doesn't know where to find an assembler unless you
> explicitly point it at bin/$target-as.  Which is arguably just more of the
> same bug.

This is not a bug, since GCC has been configured to use $target/bin/as (which
isn't part of GCC), so if you remove it it will of course break.  If you
reconfigure GCC to use bin/$target-as it will be happy to use that.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (6 preceding siblings ...)
  2013-08-08  8:39 ` schwab@linux-m68k.org
@ 2013-08-08 15:44 ` joseph at codesourcery dot com
  2013-08-08 16:40 ` brooks at gcc dot gnu.org
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: joseph at codesourcery dot com @ 2013-08-08 15:44 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #8 from joseph at codesourcery dot com <joseph at codesourcery dot com> ---
On Thu, 8 Aug 2013, brooks at gcc dot gnu.org wrote:

> http://sourceware.org/bugzilla/show_bug.cgi?id=15823
> 
> --- Comment #5 from Brooks Moses <brooks at gcc dot gnu.org> ---
> (In reply to joseph@codesourcery.com from comment #3)
> > The bug is that GCC's $target/bin/cpp is broken; only bin/$target-cpp works.
> > 
> > I'd say the bug is installing the files in $target/bin/ at all.
> 
> I.e., that there should only be bin/$target-gcc and so forth?

Yes.  That directory contains executables from binutils for internal use 
by GCC; that's its sole purpose.  The files installed by GCC there aren't 
used by GCC (rather, the public installed copy of the driver gets used 
when collect2 needs to call back to the driver), so shouldn't be 
installed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (7 preceding siblings ...)
  2013-08-08 15:44 ` joseph at codesourcery dot com
@ 2013-08-08 16:40 ` brooks at gcc dot gnu.org
  2013-08-08 18:48 ` carlos at redhat dot com
  2014-06-13 13:13 ` fweimer at redhat dot com
  10 siblings, 0 replies; 12+ messages in thread
From: brooks at gcc dot gnu.org @ 2013-08-08 16:40 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #9 from Brooks Moses <brooks at gcc dot gnu.org> ---
Back on topic: Any opinions or guidance for what flag letter to use for an
option that specifies the CPP executable?

The already-used list is abchiklmnostCDIKLMNSTY5, so what's left is
defgjpqruvwxyzABEFGHJOPQRUVWXZ.

The -Y option seems like it was just a random spare letter, which suggests -X
or -Z for similar reasons.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (8 preceding siblings ...)
  2013-08-08 16:40 ` brooks at gcc dot gnu.org
@ 2013-08-08 18:48 ` carlos at redhat dot com
  2014-06-13 13:13 ` fweimer at redhat dot com
  10 siblings, 0 replies; 12+ messages in thread
From: carlos at redhat dot com @ 2013-08-08 18:48 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=15823

--- Comment #10 from Carlos O'Donell <carlos at redhat dot com> ---
(In reply to Brooks Moses from comment #9)
> Back on topic: Any opinions or guidance for what flag letter to use for an
> option that specifies the CPP executable?
> 
> The already-used list is abchiklmnostCDIKLMNSTY5, so what's left is
> defgjpqruvwxyzABEFGHJOPQRUVWXZ.
> 
> The -Y option seems like it was just a random spare letter, which suggests
> -X or -Z for similar reasons.

Bikeshed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug build/15823] Host rpcgen is sort of fundamentally broken for cross-compilers
  2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
                   ` (9 preceding siblings ...)
  2013-08-08 18:48 ` carlos at redhat dot com
@ 2014-06-13 13:13 ` fweimer at redhat dot com
  10 siblings, 0 replies; 12+ messages in thread
From: fweimer at redhat dot com @ 2014-06-13 13:13 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=15823

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
              Flags|                            |security-

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2014-06-13 13:13 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-08  0:03 [Bug build/15823] New: Host rpcgen is sort of fundamentally broken for cross-compilers brooks at gcc dot gnu.org
2013-08-08  0:06 ` [Bug build/15823] " brooks at gcc dot gnu.org
2013-08-08  0:07 ` carlos at redhat dot com
2013-08-08  1:08 ` joseph at codesourcery dot com
2013-08-08  1:15 ` carlos at redhat dot com
2013-08-08  1:20 ` brooks at gcc dot gnu.org
2013-08-08  1:34 ` carlos at redhat dot com
2013-08-08  8:39 ` schwab@linux-m68k.org
2013-08-08 15:44 ` joseph at codesourcery dot com
2013-08-08 16:40 ` brooks at gcc dot gnu.org
2013-08-08 18:48 ` carlos at redhat dot com
2014-06-13 13:13 ` fweimer at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).