public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built
@ 2020-06-16 19:01 egorenar at linux dot ibm.com
  2020-06-16 19:02 ` [Bug libgcc/95712] " egorenar at linux dot ibm.com
                   ` (23 more replies)
  0 siblings, 24 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-16 19:01 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

            Bug ID: 95712
           Summary: configure-target-libgcc fails on s390x target because
                    xgcc is not being built
           Product: gcc
           Version: 9.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libgcc
          Assignee: unassigned at gcc dot gnu.org
          Reporter: egorenar at linux dot ibm.com
  Target Milestone: ---

Created attachment 48744
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48744&action=edit
Console output

Hi all,

i'm trying to build buildroot on s390x machine for s390x machine and
the toolchain build step fails. I attached the build.log and the config.log
of the failing target configure-target-libgcc. It seems that xgcc
is not being built prior to configuring the target configure-target-libgcc.
When i build on host x86_64 for s390x target then everything works with the
same configuration.

Regards

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

* [Bug libgcc/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
@ 2020-06-16 19:02 ` egorenar at linux dot ibm.com
  2020-06-16 19:05 ` egorenar at linux dot ibm.com
                   ` (22 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-16 19:02 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #1 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
Created attachment 48745
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48745&action=edit
config.log for configure-target-libgcc

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

* [Bug libgcc/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
  2020-06-16 19:02 ` [Bug libgcc/95712] " egorenar at linux dot ibm.com
@ 2020-06-16 19:05 ` egorenar at linux dot ibm.com
  2020-06-16 19:08 ` egorenar at linux dot ibm.com
                   ` (21 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-16 19:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #2 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
Created attachment 48746
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48746&action=edit
config.log for configure-target-libgcc gcc 9.3.0

Sorry attached gcc 8.4.0 log previosuly, but the same issue for gcc 9.3.0

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

* [Bug libgcc/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
  2020-06-16 19:02 ` [Bug libgcc/95712] " egorenar at linux dot ibm.com
  2020-06-16 19:05 ` egorenar at linux dot ibm.com
@ 2020-06-16 19:08 ` egorenar at linux dot ibm.com
  2020-06-16 19:09 ` egorenar at linux dot ibm.com
                   ` (20 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-16 19:08 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #3 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
The config.log of configure-target-libgcc says:

... build/host-gcc-initial-9.3.0/build/./gcc/xgcc: No such file or directory

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

* [Bug libgcc/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (2 preceding siblings ...)
  2020-06-16 19:08 ` egorenar at linux dot ibm.com
@ 2020-06-16 19:09 ` egorenar at linux dot ibm.com
  2020-06-16 19:16 ` pinskia at gcc dot gnu.org
                   ` (19 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-16 19:09 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #4 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
I also have the same issue with gcc 8.4.0

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

* [Bug libgcc/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (3 preceding siblings ...)
  2020-06-16 19:09 ` egorenar at linux dot ibm.com
@ 2020-06-16 19:16 ` pinskia at gcc dot gnu.org
  2020-06-17 19:59 ` egorenar at linux dot ibm.com
                   ` (18 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-16 19:16 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Target|s390x-linux-gnu             |
               Host|s390x-linux-gnu             |
         Resolution|---                         |INVALID
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
This is what I do:
${PMAKE} all-gas all-binutils all-ld || return 1
make install-gas install-ld install-binutils || return 1
# glibc will provide ssp as it is new enough
gcc_cv_libc_provides_ssp=yes  ${PMAKE} configure-gcc || return 1
${PMAKE} all-gcc all-target-libgcc || return 1
make install-gcc install-target-libgcc || return 1

I don't trust buildroot to do the right thing.

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

* [Bug libgcc/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (4 preceding siblings ...)
  2020-06-16 19:16 ` pinskia at gcc dot gnu.org
@ 2020-06-17 19:59 ` egorenar at linux dot ibm.com
  2020-06-18  4:05 ` [Bug bootstrap/95712] " pinskia at gcc dot gnu.org
                   ` (17 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-17 19:59 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

Alexander Egorenkov <egorenar at linux dot ibm.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|INVALID                     |---

--- Comment #6 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
Ok, i understand, therefore, i reproduced the problem without buildroot.

My steps:

$ mkdir compiler
$ cd compiler

$ tar xvjf gmp-6.1.0.tar.bz2
$ cd gmp-6.1.0
$ ./configure --prefix=$HOME/compiler/install --disable-shared
$ make -j81
$ make install
$ cd ..

$ tar xvjf mpfr-3.1.4.tar.bz2
$ cd mpfr-3.1.4
$ ./configure --prefix=$HOME/compiler/install --disable-shared
--with-gmp=$HOME/compiler/install
$ make -j81
$ make install
$ cd ..

$ tar xvzf mpc-1.0.3.tar.gz
$ cd mpc-1.0.3
$ ./configure --prefix=$HOME/compiler/install --disable-shared
--with-gmp=$HOME/compiler/install --with-mpfr=$HOME/compiler/install
$ make -j81
$ make install
$ cd ..


$ tar xvzf gcc-9.3.0.tar.xz
$ mkdir build-gcc
$ cd build-gcc
$ ../gcc-9.3.0/configure --prefix=$HOME/compiler/install --enable-shared
--disable-static \
                         --disable-gtk-doc --disable-gtk-doc-html --disable-doc
--disable-docs \
                         --disable-documentation --disable-debug
--with-xmlto=no --with-fop=no \
                         --disable-nls --disable-dependency-tracking 
--target=s390x-buildroot-linux-gnu  \
                         --enable-__cxa_atexit --with-gnu-ld --disable-libssp
--disable-multilib \
                         --disable-decimal-float
--with-gmp=$HOME/compiler/install \
                         --with-mpc=$HOME/compiler/install
--with-mpfr=$HOME/compiler/install \
                         --with-pkgversion="Buildroot 2020.08-git-g2d8407f8ab"
\
                         --with-bugurl="http://bugs.buildroot.net/"
--disable-libquadmath --enable-tls \
                         --enable-threads --without-isl --without-cloog
--with-arch="z196" \
                         --with-long-double-128 --enable-languages=c
--disable-shared --without-headers \
                         --disable-threads --with-newlib --disable-largefile

$ make -j81 gcc_cv_libc_provides_ssp=yes all-gcc all-target-libgcc


The above steps were executed manually w/o any buildroot infrastructure. 
And i get the same problem, almost the same commands are executed by buildroot.

Again, xgcc is not being built and libgcc fails. I patched nothing, everything
was vanilla.

What i did notice, is that everything seems to work fine and the make commands
succeeds, if i drop "-j81" in the last step.
I did all these steps on a s390x machine with 80 cores, it is a highly parallel
machine.
So the issue seems to depend on it somehow, my guess is that maybe some
dependencies are not correctly
done in libgcc Makefile ? Another workaround i found is to split the last maske
command into 2 like this:
$ make -j81 all-gcc
$ make -j81 all-target-libgcc
This seems to fix it also.

I'm ready to do more test if required. I really want to fix it, it is very
annoying and blocking me.

Regards

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (5 preceding siblings ...)
  2020-06-17 19:59 ` egorenar at linux dot ibm.com
@ 2020-06-18  4:05 ` pinskia at gcc dot gnu.org
  2020-06-18  6:55 ` egorenar at linux dot ibm.com
                   ` (16 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-18  4:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |build
          Component|libgcc                      |bootstrap

--- Comment #7 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
@if gcc-no-bootstrap
....
configure-target-libgcc: maybe-all-gcc
...
@endif gcc-no-bootstrap

What version of GNU make are you using?
Can you attach the toplevel Makefile?  I checked the version that is generated
for aarch64-linux-gnu that I configured for and it has:

# Generic dependencies for target modules on host stuff, especially gcc
....
configure-target-libgcc: maybe-all-gcc
...

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (6 preceding siblings ...)
  2020-06-18  4:05 ` [Bug bootstrap/95712] " pinskia at gcc dot gnu.org
@ 2020-06-18  6:55 ` egorenar at linux dot ibm.com
  2020-06-18  6:56 ` egorenar at linux dot ibm.com
                   ` (15 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18  6:55 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #8 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---

$ make --version
GNU Make 4.1
Built for s390x-ibm-linux-gnu

In my top Makefile the dependecny on maybe-all-gcc is missing:
....
configure-target-libgcc:
...

I attached the top Makefile.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (7 preceding siblings ...)
  2020-06-18  6:55 ` egorenar at linux dot ibm.com
@ 2020-06-18  6:56 ` egorenar at linux dot ibm.com
  2020-06-18  6:57 ` egorenar at linux dot ibm.com
                   ` (14 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18  6:56 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #9 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
Created attachment 48751
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48751&action=edit
top gcc Makefile

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (8 preceding siblings ...)
  2020-06-18  6:56 ` egorenar at linux dot ibm.com
@ 2020-06-18  6:57 ` egorenar at linux dot ibm.com
  2020-06-18  7:19 ` schwab@linux-m68k.org
                   ` (13 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18  6:57 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #10 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
When i add the dependency in Makefile manually, then the parallel build works.

Regards

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (9 preceding siblings ...)
  2020-06-18  6:57 ` egorenar at linux dot ibm.com
@ 2020-06-18  7:19 ` schwab@linux-m68k.org
  2020-06-18  8:07 ` egorenar at linux dot ibm.com
                   ` (12 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: schwab@linux-m68k.org @ 2020-06-18  7:19 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #11 from Andreas Schwab <schwab@linux-m68k.org> ---
> generated for aarch64-linux-gnu that I configured for and it has:

You have used --disable-bootstrap.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (10 preceding siblings ...)
  2020-06-18  7:19 ` schwab@linux-m68k.org
@ 2020-06-18  8:07 ` egorenar at linux dot ibm.com
  2020-06-18  9:08 ` pinskia at gcc dot gnu.org
                   ` (11 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18  8:07 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #12 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
Indeed, adding --disable-bootstrap helps also.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (11 preceding siblings ...)
  2020-06-18  8:07 ` egorenar at linux dot ibm.com
@ 2020-06-18  9:08 ` pinskia at gcc dot gnu.org
  2020-06-18  9:08 ` pinskia at gcc dot gnu.org
                   ` (10 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-18  9:08 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED

--- Comment #13 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Andreas Schwab from comment #11)
> > generated for aarch64-linux-gnu that I configured for and it has:
> 
> You have used --disable-bootstrap.

No I did not, --disable-bootstrap is the default for the case where we are
doing cross.

OH I did not notice it was s390 to s390 cross building but buildroot is not
handling that case correctly.  Rather it is thinking it is always building a
cross even when build==host==target .

> --build=s390x-ibm-linux-gnu --host=s390x-buildroot-linux-gnu --target=s390x-buildroot-linux-gnu

That is broken.  This is not a cross compiler but rather a build of the native
gcc and therefor is not the correct options.

So the problem is rather how buildroot is not doing the right configure options
to gcc for building a cross build.  NOT A BUG.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (12 preceding siblings ...)
  2020-06-18  9:08 ` pinskia at gcc dot gnu.org
@ 2020-06-18  9:08 ` pinskia at gcc dot gnu.org
  2020-06-18  9:12 ` pinskia at gcc dot gnu.org
                   ` (9 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-18  9:08 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|FIXED                       |INVALID

--- Comment #14 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (13 preceding siblings ...)
  2020-06-18  9:08 ` pinskia at gcc dot gnu.org
@ 2020-06-18  9:12 ` pinskia at gcc dot gnu.org
  2020-06-18  9:17 ` pinskia at gcc dot gnu.org
                   ` (8 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-18  9:12 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #15 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
This should have caught it:
case "$have_compiler:$host:$target:$enable_bootstrap" in
  *:*:*:no) ;;

  # Default behavior.  Enable bootstrap if we have a compiler
  # and we are in a native configuration.
  yes:$build:$build:default)
    enable_bootstrap=yes ;;

  *:*:*:default)
    enable_bootstrap=no ;;

  # We have a compiler and we are in a native configuration, bootstrap is ok
  yes:$build:$build:yes)
    ;;

  # Other configurations, but we have a compiler.  Assume the user knows
  # what he's doing.
  yes:*:*:yes)
    AC_MSG_WARN([trying to bootstrap a cross compiler])
    ;;

  # No compiler: if they passed --enable-bootstrap explicitly, fail
  no:*:*:yes)
    AC_MSG_ERROR([cannot bootstrap without a compiler]) ;;

  # Fail if wrong command line
  *)
    AC_MSG_ERROR([invalid option for --enable-bootstrap])
    ;;
esac

It does seem like buildroot does the incorrect thing if the target and the
build/host are the same arch.  THIS IS a buildroot issue and not a GCC issue.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (14 preceding siblings ...)
  2020-06-18  9:12 ` pinskia at gcc dot gnu.org
@ 2020-06-18  9:17 ` pinskia at gcc dot gnu.org
  2020-06-18  9:23 ` egorenar at linux dot ibm.com
                   ` (7 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-18  9:17 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #16 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
build_alias=s390x-ibm-linux-gnu
build_vendor=ibm
build_os=linux-gnu
build=s390x-ibm-linux-gnu
host_alias=s390x-ibm-linux-gnu
host_vendor=ibm
host_os=linux-gnu
host=s390x-ibm-linux-gnu
target_alias=s390x-buildroot-linux-gnu
target_vendor=ibm
target_os=linux-gnu
target=s390x-ibm-linux-gnu

If anything this is a config.guess bug and not directly a GCC bug :).
config.guess sets the target_vendor to being ibm for always.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (15 preceding siblings ...)
  2020-06-18  9:17 ` pinskia at gcc dot gnu.org
@ 2020-06-18  9:23 ` egorenar at linux dot ibm.com
  2020-06-18 12:35 ` egorenar at linux dot ibm.com
                   ` (6 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18  9:23 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #17 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
(In reply to Andrew Pinski from comment #13)
> (In reply to Andreas Schwab from comment #11)
> > > generated for aarch64-linux-gnu that I configured for and it has:
> > 
> > You have used --disable-bootstrap.
> 
> No I did not, --disable-bootstrap is the default for the case where we are
> doing cross.
> 
> OH I did not notice it was s390 to s390 cross building but buildroot is not
> handling that case correctly.  Rather it is thinking it is always building a
> cross even when build==host==target .
> 
> > --build=s390x-ibm-linux-gnu --host=s390x-buildroot-linux-gnu --target=s390x-buildroot-linux-gnu
> 
> That is broken.  This is not a cross compiler but rather a build of the
> native gcc and therefor is not the correct options.
> 
> So the problem is rather how buildroot is not doing the right configure
> options to gcc for building a cross build.  NOT A BUG.

But i did not use those configure options in my test.
And now i also removed option "--target=" in my test and it is still failing
with the same problem. I'm not talking about buildroot, i got rid of it. Please
see my test.

Thanks

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (16 preceding siblings ...)
  2020-06-18  9:23 ` egorenar at linux dot ibm.com
@ 2020-06-18 12:35 ` egorenar at linux dot ibm.com
  2020-06-18 16:48 ` pinskia at gcc dot gnu.org
                   ` (5 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18 12:35 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

Alexander Egorenkov <egorenar at linux dot ibm.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|INVALID                     |---
             Status|RESOLVED                    |UNCONFIRMED

--- Comment #18 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
I reopened the problem because i reproduced this w/o buildroot and
--host,--target and --build configure options.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (17 preceding siblings ...)
  2020-06-18 12:35 ` egorenar at linux dot ibm.com
@ 2020-06-18 16:48 ` pinskia at gcc dot gnu.org
  2020-06-18 17:15 ` egorenar at linux dot ibm.com
                   ` (4 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-18 16:48 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |MOVED
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #19 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
This is a config.sub issue where the vendor is always rest/set to ibm. Not
directly a gcc issue.  Gcc does not maintain config.sub.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (18 preceding siblings ...)
  2020-06-18 16:48 ` pinskia at gcc dot gnu.org
@ 2020-06-18 17:15 ` egorenar at linux dot ibm.com
  2020-06-18 17:31 ` egorenar at linux dot ibm.com
                   ` (3 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18 17:15 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #20 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
(In reply to Andrew Pinski from comment #19)
> This is a config.sub issue where the vendor is always rest/set to ibm. Not
> directly a gcc issue.  Gcc does not maintain config.sub.

Ok, sorry, thank you :)

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (19 preceding siblings ...)
  2020-06-18 17:15 ` egorenar at linux dot ibm.com
@ 2020-06-18 17:31 ` egorenar at linux dot ibm.com
  2020-06-18 18:32 ` pinskia at gcc dot gnu.org
                   ` (2 subsequent siblings)
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-18 17:31 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #21 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
Could you please point me to the bug report it was moved to ? Thanks

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (20 preceding siblings ...)
  2020-06-18 17:31 ` egorenar at linux dot ibm.com
@ 2020-06-18 18:32 ` pinskia at gcc dot gnu.org
  2020-06-19  4:51 ` egorenar at linux dot ibm.com
  2020-06-20 10:52 ` egorenar at linux dot ibm.com
  23 siblings, 0 replies; 25+ messages in thread
From: pinskia at gcc dot gnu.org @ 2020-06-18 18:32 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #22 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Alexander Egorenkov from comment #21)
> Could you please point me to the bug report it was moved to ? Thanks

Can you file it?  Well they don't have a bug database, just an email list:
Report bugs and patches to <config-patches@gnu.org>.

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (21 preceding siblings ...)
  2020-06-18 18:32 ` pinskia at gcc dot gnu.org
@ 2020-06-19  4:51 ` egorenar at linux dot ibm.com
  2020-06-20 10:52 ` egorenar at linux dot ibm.com
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-19  4:51 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #23 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
I would gladly if i understood the real problem. Sorry i'm not very familiar
with config.guess & config.sub. Could you please elaborate what the problem is
and how it should be fixed ? Thanks

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

* [Bug bootstrap/95712] configure-target-libgcc fails on s390x target because xgcc is not being built
  2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
                   ` (22 preceding siblings ...)
  2020-06-19  4:51 ` egorenar at linux dot ibm.com
@ 2020-06-20 10:52 ` egorenar at linux dot ibm.com
  23 siblings, 0 replies; 25+ messages in thread
From: egorenar at linux dot ibm.com @ 2020-06-20 10:52 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95712

--- Comment #24 from Alexander Egorenkov <egorenar at linux dot ibm.com> ---
I finally figured it out and fixed buildroot.
This info is for posterity, in case somebody will have the same issue.
If i understood it correctly, then the problem was that buildroot
wrongly tried to build a native compiler on s390x host for s390 target instead
of a cross-compiler due to a problem is config.sub which is fixed by this path:

@@ -1138,14 +1138,6 @@ case $cpu-$vendor in
                cpu=nsx
                vendor=tandem
                ;;
-       s390-*)
-               cpu=s390
-               vendor=ibm
-               ;;
-       s390x-*)
-               cpu=s390x
-               vendor=ibm
-               ;;
        tile*-*)
                os=${os:-linux-gnu}
                ;;
@@ -1229,6 +1221,7 @@ case $cpu-$vendor in
                        | pyramid \
                        | riscv | riscv32 | riscv64 \
                        | rl78 | romp | rs6000 | rx \
+                       | s390 | s390x \
                        | score \
                        | sh | shl \
                        | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb]
| sh[lb]e \



After fixing config.sub everything builds just fine and works great :)
I'm going to try to submit this fix to the config mailing list.
Best regard & thank you

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

end of thread, other threads:[~2020-06-20 10:52 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-16 19:01 [Bug libgcc/95712] New: configure-target-libgcc fails on s390x target because xgcc is not being built egorenar at linux dot ibm.com
2020-06-16 19:02 ` [Bug libgcc/95712] " egorenar at linux dot ibm.com
2020-06-16 19:05 ` egorenar at linux dot ibm.com
2020-06-16 19:08 ` egorenar at linux dot ibm.com
2020-06-16 19:09 ` egorenar at linux dot ibm.com
2020-06-16 19:16 ` pinskia at gcc dot gnu.org
2020-06-17 19:59 ` egorenar at linux dot ibm.com
2020-06-18  4:05 ` [Bug bootstrap/95712] " pinskia at gcc dot gnu.org
2020-06-18  6:55 ` egorenar at linux dot ibm.com
2020-06-18  6:56 ` egorenar at linux dot ibm.com
2020-06-18  6:57 ` egorenar at linux dot ibm.com
2020-06-18  7:19 ` schwab@linux-m68k.org
2020-06-18  8:07 ` egorenar at linux dot ibm.com
2020-06-18  9:08 ` pinskia at gcc dot gnu.org
2020-06-18  9:08 ` pinskia at gcc dot gnu.org
2020-06-18  9:12 ` pinskia at gcc dot gnu.org
2020-06-18  9:17 ` pinskia at gcc dot gnu.org
2020-06-18  9:23 ` egorenar at linux dot ibm.com
2020-06-18 12:35 ` egorenar at linux dot ibm.com
2020-06-18 16:48 ` pinskia at gcc dot gnu.org
2020-06-18 17:15 ` egorenar at linux dot ibm.com
2020-06-18 17:31 ` egorenar at linux dot ibm.com
2020-06-18 18:32 ` pinskia at gcc dot gnu.org
2020-06-19  4:51 ` egorenar at linux dot ibm.com
2020-06-20 10:52 ` egorenar at linux dot ibm.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).