* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
@ 2022-01-21 5:51 ` unlvsur at live dot com
2022-01-21 8:43 ` pinskia at gcc dot gnu.org
` (11 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: unlvsur at live dot com @ 2022-01-21 5:51 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #1 from cqwrteur <unlvsur at live dot com> ---
D:\hg\fast_io\examples\0001.helloworld>aarch64-linux-android-g++ -o helloworld
helloworld.cc -Ofast -std=c++23 -s -flto -I../../include -Wall -stdlib=libc++
-std=c++2b
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
2022-01-21 5:51 ` [Bug c++/104157] " unlvsur at live dot com
@ 2022-01-21 8:43 ` pinskia at gcc dot gnu.org
2022-01-21 8:47 ` unlvsur at live dot com
` (10 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-21 8:43 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Ever confirmed|0 |1
Status|UNCONFIRMED |WAITING
Last reconfirmed| |2022-01-21
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Where is the target stddef.h located?
Can you add -v while compiling and provide the full output?
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
2022-01-21 5:51 ` [Bug c++/104157] " unlvsur at live dot com
2022-01-21 8:43 ` pinskia at gcc dot gnu.org
@ 2022-01-21 8:47 ` unlvsur at live dot com
2022-01-21 8:51 ` pinskia at gcc dot gnu.org
` (9 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: unlvsur at live dot com @ 2022-01-21 8:47 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #3 from cqwrteur <unlvsur at live dot com> ---
Created attachment 52253
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52253&action=edit
error message on windows
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (2 preceding siblings ...)
2022-01-21 8:47 ` unlvsur at live dot com
@ 2022-01-21 8:51 ` pinskia at gcc dot gnu.org
2022-01-21 8:54 ` unlvsur at live dot com
` (8 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-21 8:51 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
inside d:\x86_64-windows-gnu\aarch64-linux-android can you find all files
called stddef.h and print their path?
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (3 preceding siblings ...)
2022-01-21 8:51 ` pinskia at gcc dot gnu.org
@ 2022-01-21 8:54 ` unlvsur at live dot com
2022-01-21 9:00 ` pinskia at gcc dot gnu.org
` (7 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: unlvsur at live dot com @ 2022-01-21 8:54 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #5 from cqwrteur <unlvsur at live dot com> ---
(In reply to Andrew Pinski from comment #4)
> inside d:\x86_64-windows-gnu\aarch64-linux-android can you find all files
> called stddef.h and print their path?
D:\x86_64-windows-gnu\aarch64-linux-android\aarch64-linux-android\include\c++\v1
D:\x86_64-windows-gnu\aarch64-linux-android\aarch64-linux-android\include\linux
D:\x86_64-windows-gnu\aarch64-linux-android\lib\gcc\aarch64-linux-android\12.0.1\include
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (4 preceding siblings ...)
2022-01-21 8:54 ` unlvsur at live dot com
@ 2022-01-21 9:00 ` pinskia at gcc dot gnu.org
2022-01-21 9:02 ` pinskia at gcc dot gnu.org
` (6 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-21 9:00 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
You say it works with the host as linux, can you show the output of -v while
compiling?
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (5 preceding siblings ...)
2022-01-21 9:00 ` pinskia at gcc dot gnu.org
@ 2022-01-21 9:02 ` pinskia at gcc dot gnu.org
2022-01-21 9:07 ` unlvsur at live dot com
` (5 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-21 9:02 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #7 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
By the way the order looks wrong:
d:\x86_64-windows-gnu\aarch64-linux-android\bin\../lib/gcc/aarch64-linux-android/12.0.1/include
d:\x86_64-windows-gnu\aarch64-linux-android\bin\../lib/gcc/aarch64-linux-android/12.0.1/include-fixed
d:\x86_64-windows-gnu\aarch64-linux-android\bin\../lib/gcc/aarch64-linux-android/12.0.1/../../../../aarch64-linux-android/include
d:/x86_64-windows-gnu/aarch64-linux-android/lib/gcc/../../aarch64-linux-android/include/c++/v1
C++ includes should be first. really
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (6 preceding siblings ...)
2022-01-21 9:02 ` pinskia at gcc dot gnu.org
@ 2022-01-21 9:07 ` unlvsur at live dot com
2022-01-21 9:08 ` unlvsur at live dot com
` (4 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: unlvsur at live dot com @ 2022-01-21 9:07 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #8 from cqwrteur <unlvsur at live dot com> ---
Created attachment 52254
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52254&action=edit
result from linux
Yes on linux include/v1/c++ goes first.
BTW Can we just make
--with-gxx-libcxx-include-dir=$PREFIX/$TARGET/include/c++/v1 by default unless
users set it?
It is annoying to set this every time for configuring. It should by default the
same as libstdc++
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (7 preceding siblings ...)
2022-01-21 9:07 ` unlvsur at live dot com
@ 2022-01-21 9:08 ` unlvsur at live dot com
2022-01-21 9:18 ` [Bug c++/104157] -std=libc++ does not with cross compilers and moving the install around (places the include path last) pinskia at gcc dot gnu.org
` (3 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: unlvsur at live dot com @ 2022-01-21 9:08 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #9 from cqwrteur <unlvsur at live dot com> ---
(In reply to Andrew Pinski from comment #6)
> You say it works with the host as linux, can you show the output of -v while
> compiling?
Same issue happens with x86_64-ubuntu-linux-gnu target, x86_64-w64-mingw32 host
too.
Looks like we have some issues dealing with this on windows at the compiler
side.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] -std=libc++ does not with cross compilers and moving the install around (places the include path last)
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (8 preceding siblings ...)
2022-01-21 9:08 ` unlvsur at live dot com
@ 2022-01-21 9:18 ` pinskia at gcc dot gnu.org
2022-01-21 9:20 ` pinskia at gcc dot gnu.org
` (2 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-21 9:18 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |UNCONFIRMED
Summary|libc++ does not work |-std=libc++ does not with
|properly with |cross compilers and moving
|x86_64-w64-mingw32 host, |the install around (places
|but works fine with |the include path last)
|x86_64-linux-gnu host |
Ever confirmed|1 |0
--- Comment #10 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to cqwrteur from comment #8)
> Created attachment 52254 [details]
> result from linux
>
> Yes on linux include/v1/c++ goes first.
The main difference is the addition of:
-iprefix
d:\x86_64-windows-gnu\aarch64-linux-android\bin\../lib/gcc/aarch64-linux-android/12.0.1/
The problem is somewhere in add_standard_paths
My guess is if you move the install directory for the linux case, the problem
on Linux will show up too.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] -std=libc++ does not with cross compilers and moving the install around (places the include path last)
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (9 preceding siblings ...)
2022-01-21 9:18 ` [Bug c++/104157] -std=libc++ does not with cross compilers and moving the install around (places the include path last) pinskia at gcc dot gnu.org
@ 2022-01-21 9:20 ` pinskia at gcc dot gnu.org
2022-01-21 9:36 ` unlvsur at live dot com
2022-01-21 9:38 ` pinskia at gcc dot gnu.org
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-21 9:20 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #11 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Somehow add_standard_paths is doing the wrong thing when -iprefix is applied
but I have no idea how or why. This definitely needs to be fixed but it is a
low priority as -std=libc++ is not used that much, especially with
non-sysrooted cross compilers.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] -std=libc++ does not with cross compilers and moving the install around (places the include path last)
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (10 preceding siblings ...)
2022-01-21 9:20 ` pinskia at gcc dot gnu.org
@ 2022-01-21 9:36 ` unlvsur at live dot com
2022-01-21 9:38 ` pinskia at gcc dot gnu.org
12 siblings, 0 replies; 14+ messages in thread
From: unlvsur at live dot com @ 2022-01-21 9:36 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #12 from cqwrteur <unlvsur at live dot com> ---
well. plus canadian cross back compiler From windows to linux.
probably only i cross compile Linux programs on windows.(several other people
downloaded my toolchains.)
Get Outlook for Android<https://aka.ms/AAb9ysg>
________________________________
From: pinskia at gcc dot gnu.org <gcc-bugzilla@gcc.gnu.org>
Sent: Friday, January 21, 2022 4:20:19 AM
To: unlvsur@live.com <unlvsur@live.com>
Subject: [Bug c++/104157] -std=libc++ does not with cross compilers and moving
the install around (places the include path last)
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #11 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Somehow add_standard_paths is doing the wrong thing when -iprefix is applied
but I have no idea how or why. This definitely needs to be fixed but it is a
low priority as -std=libc++ is not used that much, especially with
non-sysrooted cross compilers.
--
You are receiving this mail because:
You reported the bug.
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug c++/104157] -std=libc++ does not with cross compilers and moving the install around (places the include path last)
2022-01-21 5:50 [Bug c++/104157] New: libc++ does not work properly with x86_64-w64-mingw32 host, but works fine with x86_64-linux-gnu host unlvsur at live dot com
` (11 preceding siblings ...)
2022-01-21 9:36 ` unlvsur at live dot com
@ 2022-01-21 9:38 ` pinskia at gcc dot gnu.org
12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-21 9:38 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104157
--- Comment #13 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to cqwrteur from comment #12)
> well. plus canadian cross back compiler From windows to linux.
> probably only i cross compile Linux programs on windows.(several other
> people downloaded my toolchains.)
Yes but hardly anyone uses -std=libc++ in general :). And using non-sysroot
these days is not really supported and for good reasons.
^ permalink raw reply [flat|nested] 14+ messages in thread