public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
@ 2013-09-03 22:00 ` brooks at gcc dot gnu.org
2013-09-03 22:09 ` joseph at codesourcery dot com
` (7 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: brooks at gcc dot gnu.org @ 2013-09-03 22:00 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #1 from Brooks Moses <brooks at gcc dot gnu.org> ---
Jakub, I added you to the cc list in hopes that you may be able to comment on
the original reasoning for this being a runtime check rather than simply a
check for the ability to link a program calling vsnprintf, since you were the
original author.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
2013-09-03 22:00 ` [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers brooks at gcc dot gnu.org
@ 2013-09-03 22:09 ` joseph at codesourcery dot com
2013-09-03 22:17 ` brooks at gcc dot gnu.org
` (6 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: joseph at codesourcery dot com @ 2013-09-03 22:09 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #2 from joseph at codesourcery dot com <joseph at codesourcery dot com> ---
If your target uses glibc, you don't need libssp anyway.
libssp is used by LINK_SSP_SPEC if TARGET_LIBC_PROVIDES_SSP is not
defined. TARGET_LIBC_PROVIDES_SSP is defined when glibc headers are
available when configuring GCC, and they are version 2.4 or later (or some
other conditions for some other C libraries).
The checks for headers do cause problems when bootstrapping a cross
toolchain - you may need to set gcc_cv_libc_provides_ssp=yes to get a
correctly configured bootstrap compiler that can build glibc. See
<http://gcc.gnu.org/ml/gcc/2013-06/msg00112.html> for how I think that
should be fixed - a configure option to specify the target glibc version.
If your target does not use glibc, I have no advice beyond the general
principle that the default should be assuming a function works and then
known-broken systems (if any are supported) can be blacklisted.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
2013-09-03 22:00 ` [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers brooks at gcc dot gnu.org
2013-09-03 22:09 ` joseph at codesourcery dot com
@ 2013-09-03 22:17 ` brooks at gcc dot gnu.org
2013-09-04 2:06 ` brooks at gcc dot gnu.org
` (5 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: brooks at gcc dot gnu.org @ 2013-09-03 22:17 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #3 from Brooks Moses <brooks at gcc dot gnu.org> ---
Thanks, Joseph. This is a straightforward Linux target using glibc, so I'll
investigate to see why the binary in question is relying on libssp rather than
glibc.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2013-09-03 22:17 ` brooks at gcc dot gnu.org
@ 2013-09-04 2:06 ` brooks at gcc dot gnu.org
2022-05-24 15:00 ` egallager at gcc dot gnu.org
` (4 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: brooks at gcc dot gnu.org @ 2013-09-04 2:06 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #4 from Brooks Moses <brooks at gcc dot gnu.org> ---
It turns out that we do need these symbols in libssp despite having a nice
plain x86-Linux environment. We've got some precompiled blobs from
who-knows-where that want the "LIBSSP_1.0" version of the __vsnprintf_chk
symbol -- and, although our glibc exports __vsnprintf_chk, it of course exports
it with a "GLIBC_2.3.4" version. Failure ensues.
So, for consistency for things that either explicitly declare -lssp or
otherwise end up with the LIBSSP symbol versions, I think it's nonetheless
useful to fix the libssp configure file for cross-compilation.
Thus, patch posted:
http://gcc.gnu.org/ml/gcc-patches/2013-09/msg00174.html
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2013-09-04 2:06 ` brooks at gcc dot gnu.org
@ 2022-05-24 15:00 ` egallager at gcc dot gnu.org
2023-08-17 19:55 ` egallager at gcc dot gnu.org
` (3 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: egallager at gcc dot gnu.org @ 2022-05-24 15:00 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
Eric Gallager <egallager at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |egallager at gcc dot gnu.org
Ever confirmed|0 |1
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed| |2022-05-24
--- Comment #7 from Eric Gallager <egallager at gcc dot gnu.org> ---
(In reply to Brooks Moses from comment #6)
> (In reply to Eric Gallager from comment #5)
> > Is that patch still relevant?
>
> The relevant part of the libssp configure.ac hasn't changed much (if at all)
> since I posted the patch, so I think it's still worth applying just on basic
> of general correctness and avoiding unnecessary runtime checks in configure
> files for things that may be cross-compiled.
>
OK, I'll try taking it, then.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2022-05-24 15:00 ` egallager at gcc dot gnu.org
@ 2023-08-17 19:55 ` egallager at gcc dot gnu.org
2023-08-17 20:00 ` egallager at gcc dot gnu.org
` (2 subsequent siblings)
8 siblings, 0 replies; 9+ messages in thread
From: egallager at gcc dot gnu.org @ 2023-08-17 19:55 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #8 from Eric Gallager <egallager at gcc dot gnu.org> ---
So I tried applying the patch against current gcc sources, and got these
results:
$ patch < /Users/ericgallager/Downloads/2013-09-03_libssp-configure.diff
patching file configure.ac
Hunk #1 FAILED at 125.
1 out of 1 hunk FAILED -- saving rejects to file configure.ac.rej
patching file configure
Hunk #1 FAILED at 4505.
Hunk #2 FAILED at 10620.
Hunk #3 FAILED at 10726.
3 out of 3 hunks FAILED -- saving rejects to file configure.rej
$
I'll attach my rejects files next.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
` (5 preceding siblings ...)
2023-08-17 19:55 ` egallager at gcc dot gnu.org
@ 2023-08-17 20:00 ` egallager at gcc dot gnu.org
2023-08-17 20:01 ` egallager at gcc dot gnu.org
2023-08-17 20:01 ` egallager at gcc dot gnu.org
8 siblings, 0 replies; 9+ messages in thread
From: egallager at gcc dot gnu.org @ 2023-08-17 20:00 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #9 from Eric Gallager <egallager at gcc dot gnu.org> ---
(In reply to Eric Gallager from comment #8)
> So I tried applying the patch against current gcc sources, and got these
> results:
>
> $ patch < /Users/ericgallager/Downloads/2013-09-03_libssp-configure.diff
> patching file configure.ac
> Hunk #1 FAILED at 125.
> 1 out of 1 hunk FAILED -- saving rejects to file configure.ac.rej
> patching file configure
> Hunk #1 FAILED at 4505.
> Hunk #2 FAILED at 10620.
> Hunk #3 FAILED at 10726.
> 3 out of 3 hunks FAILED -- saving rejects to file configure.rej
> $
>
> I'll attach my rejects files next.
oh wait I'm stupid, I was applying it from the wrong directory... trying
applying it to libssp specifically still fails, though:
$ patch < /Users/ericgallager/Downloads/2013-09-03_libssp-configure.diff
patching file configure.ac
Hunk #1 FAILED at 125.
1 out of 1 hunk FAILED -- saving rejects to file configure.ac.rej
patching file configure
Hunk #1 succeeded at 4836 (offset 331 lines).
Hunk #2 FAILED at 10951.
Hunk #3 FAILED at 11057.
2 out of 3 hunks FAILED -- saving rejects to file configure.rej
$
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
` (6 preceding siblings ...)
2023-08-17 20:00 ` egallager at gcc dot gnu.org
@ 2023-08-17 20:01 ` egallager at gcc dot gnu.org
2023-08-17 20:01 ` egallager at gcc dot gnu.org
8 siblings, 0 replies; 9+ messages in thread
From: egallager at gcc dot gnu.org @ 2023-08-17 20:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #10 from Eric Gallager <egallager at gcc dot gnu.org> ---
Created attachment 55747
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=55747&action=edit
rejects file for libssp/configure.ac
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers.
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
` (7 preceding siblings ...)
2023-08-17 20:01 ` egallager at gcc dot gnu.org
@ 2023-08-17 20:01 ` egallager at gcc dot gnu.org
8 siblings, 0 replies; 9+ messages in thread
From: egallager at gcc dot gnu.org @ 2023-08-17 20:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58312
--- Comment #11 from Eric Gallager <egallager at gcc dot gnu.org> ---
Created attachment 55748
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=55748&action=edit
rejects file for libssp/configure
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2023-08-17 20:01 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-58312-4@http.gcc.gnu.org/bugzilla/>
2013-09-03 22:00 ` [Bug other/58312] libssp configure check for "usable vsnprintf" is broken on cross-compilers brooks at gcc dot gnu.org
2013-09-03 22:09 ` joseph at codesourcery dot com
2013-09-03 22:17 ` brooks at gcc dot gnu.org
2013-09-04 2:06 ` brooks at gcc dot gnu.org
2022-05-24 15:00 ` egallager at gcc dot gnu.org
2023-08-17 19:55 ` egallager at gcc dot gnu.org
2023-08-17 20:00 ` egallager at gcc dot gnu.org
2023-08-17 20:01 ` egallager at gcc dot gnu.org
2023-08-17 20:01 ` egallager at gcc dot gnu.org
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).