[crosstool-ng/crosstool-ng] 70a158: Fix variables passing to gdb configure scripts

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[crosstool-ng/crosstool-ng] 70a158: Fix variables passing to gdb configure scripts

Alexey Neyman
  Branch: refs/heads/master
  Home:   https://github.com/crosstool-ng/crosstool-ng
  Commit: 70a1584e151832a347472cb557a72204777c95eb
      https://github.com/crosstool-ng/crosstool-ng/commit/70a1584e151832a347472cb557a72204777c95eb
  Author: Sergey Korolev <[hidden email]>
  Date:   2017-12-14 (Thu, 14 Dec 2017)

  Changed paths:
    M scripts/build/debug/300-gdb.sh

  Log Message:
  -----------
  Fix variables passing to gdb configure scripts

These changes mainly fix static linking errors when building static
native gdb and gdbserver (tested with gcc 7.2.0 + uClibc-ng 1.0.27 +
binutils 2.29.1 for MIPS):

[ALL  ]    .../lib/libstdc++.a(eh_throw.o): In function `__cxa_throw':
[ALL  ]    (.text.__cxa_throw+0x64): undefined reference to `_Unwind_RaiseException'
[ALL  ]    (.text.__cxa_throw+0x6c): undefined reference to `_Unwind_RaiseException'
[ALL  ]    .../lib/libstdc++.a(eh_throw.o): In function `__cxa_rethrow':
[ALL  ]    (.text.__cxa_rethrow+0x78): undefined reference to `_Unwind_Resume_or_Rethrow'
[ALL  ]    (.text.__cxa_rethrow+0x80): undefined reference to `_Unwind_Resume_or_Rethrow'
...

The problem is in mixing of CPP, CC, CXX, and LD with CPPFLAGS, CFLAGS,
CXXFLAGS, and LDFLAGS before passing to configure scripts.
gcc is sensitive to argument order and the scripts are normally responsible
to combine the variables in a proper way.

Signed-off-by: Sergey Korolev <[hidden email]>


  Commit: 37caa3d4d7986e95e71fcfd102d3a02b08f8a6b8
      https://github.com/crosstool-ng/crosstool-ng/commit/37caa3d4d7986e95e71fcfd102d3a02b08f8a6b8
  Author: Alexey Neyman <[hidden email]>
  Date:   2017-12-17 (Sun, 17 Dec 2017)

  Changed paths:
    M scripts/build/debug/300-gdb.sh

  Log Message:
  -----------
  Merge pull request #882 from ksergeyv/gdb-link

Fix variables passing to gdb configure scripts


Compare: https://github.com/crosstool-ng/crosstool-ng/compare/f2db6bff7cd9...37caa3d4d798