[Bug gprofng/29113] New: Build error for x86_64-w64-mingw32 host since CLOCK_MONOTONIC does not exist

2022-05-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29113

Bug ID: 29113
   Summary: Build error for x86_64-w64-mingw32 host since
CLOCK_MONOTONIC does not exist
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: gprofng
  Assignee: vladimir.mezentsev at oracle dot com
  Reporter: euloanty at live dot com
  Target Milestone: ---

../../../../../../binutils-gdb/gprofng/libcollector/gethrtime.c: In function
'linux_gethrtime':
../../../../../../binutils-gdb/gprofng/libcollector/gethrtime.c:38:11: warning:
implicit declaration of function 'clock_gettime'
[-Wimplicit-function-declaration]
   38 |   int r = clock_gettime (CLOCK_MONOTONIC, &tp);
  |   ^
../../../../../../binutils-gdb/gprofng/libcollector/gethrtime.c:38:26: error:
'CLOCK_MONOTONIC' undeclared (first use in this function)
   38 |   int r = clock_gettime (CLOCK_MONOTONIC, &tp);
  |  ^~~
../../../../../../binutils-gdb/gprofng/libcollector/gethrtime.c:38:26: note:
each undeclared identifier is reported only once for each function it appears
in

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


[Bug gprofng/29113] Build error for x86_64-w64-mingw32 host since CLOCK_MONOTONIC does not exist

2022-05-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29113

cqwrteur  changed:

   What|Removed |Added

 Target||x86_64-ubuntu-linux-gnu
   Host||x86_64-w64-mingw32
 CC||euloanty at live dot com
  Build||x86_64-linux-gnu

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


[Bug gprofng/29113] Build error for x86_64-w64-mingw32 host since CLOCK_MONOTONIC does not exist

2022-05-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29113

--- Comment #1 from cqwrteur  ---
i do canadian compilation for windows to build linux programs. gprofng simply
does not correctly support windows host. Needs to block it in the build script

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


[Bug gprofng/29113] Build error for x86_64-w64-mingw32 host since CLOCK_MONOTONIC does not exist

2022-05-03 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29113

--- Comment #3 from cqwrteur  ---
(In reply to Vladimir Mezentsev from comment #2)
>  How do you configure your build ?
> 
> gprofng should not be built for x86_64-w64-mingw32.
> Only these platforms are supported:
> 
> % cat gprofng/configure.ac
> ...
>   case "${target}" in
> x86_64-*-linux*)
>   build_src=true
>   build_collector=true
>   ;;
> i?86-*-linux*)
>   build_collector=true
>   build_collector=true
>   ;;
> aarch64-*-linux*)
>   build_src=true
>   build_collector=true
>   ;;
>   esac

I do Canadian compilation for building cross back compiler. (Aka, the compiler
is built on linux, hosted on windows, and targeting windows)

Here the bug is that if target is linux but host is windows, your configure
script would still build collector.

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


[Bug gprofng/29113] Build error for x86_64-w64-mingw32 host since CLOCK_MONOTONIC does not exist

2022-05-03 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29113

--- Comment #4 from cqwrteur  ---
(In reply to Vladimir Mezentsev from comment #2)
>  How do you configure your build ?
> 
> gprofng should not be built for x86_64-w64-mingw32.
> Only these platforms are supported:
> 
> % cat gprofng/configure.ac
> ...
>   case "${target}" in
> x86_64-*-linux*)
>   build_src=true
>   build_collector=true
>   ;;
> i?86-*-linux*)
>   build_collector=true
>   build_collector=true
>   ;;
> aarch64-*-linux*)
>   build_src=true
>   build_collector=true
>   ;;
>   esac

the compiler runs on WINDOWS. but the compiled program runs on linux.

The build process is again on linux. It is a crossback Canadian toolchain.

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


[Bug gprofng/29113] Build error for x86_64-w64-mingw32 host since CLOCK_MONOTONIC does not exist

2022-05-03 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29113

--- Comment #5 from cqwrteur  ---
(In reply to Vladimir Mezentsev from comment #2)
>  How do you configure your build ?
> 
> gprofng should not be built for x86_64-w64-mingw32.
> Only these platforms are supported:
> 
> % cat gprofng/configure.ac
> ...
>   case "${target}" in
> x86_64-*-linux*)
>   build_src=true
>   build_collector=true
>   ;;
> i?86-*-linux*)
>   build_collector=true
>   build_collector=true
>   ;;
> aarch64-*-linux*)
>   build_src=true
>   build_collector=true
>   ;;
>   esac

case "${target}" in
is clearly wrong. It should be ${host}, not ${target}

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


[Bug gprofng/29131] New: No rule to make target 'gprofng.1', needed by 'all-am'. Stop

2022-05-08 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29131

Bug ID: 29131
   Summary: No rule to make target 'gprofng.1', needed by
'all-am'.  Stop
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: gprofng
  Assignee: vladimir.mezentsev at oracle dot com
  Reporter: euloanty at live dot com
  Target Milestone: ---

Created attachment 14096
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14096&action=edit
error

make[5]: *** No rule to make target 'gprofng.1', needed by 'all-am'.  Stop.
make[5]: *** Waiting for unfinished jobs
make[4]: *** [Makefile:599: all] Error 2
make[3]: *** [Makefile:471: all-recursive] Error 1
make[2]: *** [Makefile:403: all] Error 2
make[1]: *** [Makefile:7757: all-gprofng] Error 2
make: *** [Makefile:1004: all] Error 2

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


[Bug gprofng/29131] No rule to make target 'gprofng.1', needed by 'all-am'. Stop. For arm

2022-05-08 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29131

cqwrteur  changed:

   What|Removed |Added

   Host||aarch64-linux-gnu
Summary|No rule to make target  |No rule to make target
   |'gprofng.1', needed by  |'gprofng.1', needed by
   |'all-am'.  Stop |'all-am'.  Stop. For arm
  Build||x86_64-linux-gnu
 Target||aarch64-linux-gnu
 CC|            |euloanty at live dot com

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


[Bug gprofng/29131] No rule to make target 'gprofng.1', needed by 'all-am'. Stop. For arm

2022-05-09 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29131

--- Comment #2 from cqwrteur  ---
(In reply to Vladimir Mezentsev from comment #1)
>  I cannot reproduce this on my build.
> How do you configure your build ?
> Is it Intel or Arm ?

aarch64-linux-gnu target and host

Build on x86_64-linux-gnu

I am using a x86_64-linux machine that builds a native toolchain that would run
on aarch64 raspi

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


[Bug gprofng/29148] New: bison version too new??

2022-05-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29148

Bug ID: 29148
   Summary: bison version too new??
   Product: binutils
   Version: 2.39 (HEAD)
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: gprofng
  Assignee: vladimir.mezentsev at oracle dot com
  Reporter: euloanty at live dot com
  Target Milestone: ---

checking for bison 3.0.4 or newer... 3.8.2, bad
configure: error: Building gprofng requires bison 3.0.4 or later.

bison --version
bison (GNU Bison) 3.8.2
Written by Robert Corbett and Richard Stallman.

Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

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


[Bug gprofng/29148] bison version too new??

2022-05-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29148

cqwrteur  changed:

   What|Removed |Added

  Build||x86_64-linux-gnu
   Host||x86_64-linux-gnu
 Target||x86_64-linux-gnu

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


[Bug gprofng/29148] bison version too new??

2022-05-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29148

cqwrteur  changed:

   What|Removed |Added

 CC||euloanty at live dot com

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


[Bug gprofng/29148] bison version too new??

2022-05-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29148

cqwrteur  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |INVALID

--- Comment #1 from cqwrteur  ---
Does it look like it is an issue coming from ubuntu patching? These linux
distributions apply patches to everything that breaks a lot of things.

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


[Bug binutils/29218] libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

--- Comment #1 from cqwrteur  ---
Created attachment 14128
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14128&action=edit
config file

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


[Bug binutils/29218] libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

cqwrteur  changed:

   What|Removed |Added

  Build||x86_64-linux-gnu
 Target||i586-msdosdjgp
   Host||x86_64-w64-mingw32
 CC||euloanty at live dot com

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


[Bug binutils/29218] New: libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

Bug ID: 29218
   Summary: libiberty cannot find __imp___acrt_iob_func for
x86_64-w64-mingw32 cross toolchain for canadian
compilation
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: binutils
  Assignee: unassigned at sourceware dot org
  Reporter: euloanty at live dot com
  Target Milestone: ---

/usr/local/lib/gcc/x86_64-pc-linux-gnu/13.0.0/../../../../x86_64-pc-linux-gnu/bin/ld:
../libiberty/libiberty.a(xmalloc.o): in function `fprintf':
/home/cqwrteur/toolchains/native/x86_64-w64-mingw32/x86_64-w64-mingw32/include/stdio.h:361:
undefined reference to `__mingw_vfprintf'
/usr/local/lib/gcc/x86_64-pc-linux-gnu/13.0.0/../../../../x86_64-pc-linux-gnu/bin/ld:
../libiberty/libiberty.a(xmalloc.o): in function `xmalloc_failed':
/home/cqwrteur/toolchains_build/build/x86_64-w64-mingw32/i586-msdosdjgpp/binutils-gdb/libiberty/../../../../../binutils-gdb/libiberty/xmalloc.c:134:
undefined reference to `__imp___acrt_iob_func'
collect2: error: ld returned 1 exit status
make[3]: *** [Makefile:2488: doc/chew.stamp] Error 1
make[3]: Leaving directory
'/home/cqwrteur/toolchains_build/build/x86_64-w64-mingw32/i586-msdosdjgpp/binutils-gdb/bfd'
make[2]: *** [Makefile:1939: info-recursive] Error 1
make[2]: Leaving directory
'/home/cqwrteur/toolchains_build/build/x86_64-w64-mingw32/i586-msdosdjgpp/binutils-gdb/bfd'
make[1]: *** [Makefile:3071: all-bfd] Error 2
make[1]: *** Waiting for unfinished jobs
yes

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


[Bug binutils/29218] libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

--- Comment #2 from cqwrteur  ---
https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=7273d78f3f7ae3701512f1ff423430f51b011ece

I believe it breaks because of this commitment. It makes the binary compiled
with the build compiler instead of the host compiler.

It completely breaks Canadian compilation.

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


[Bug binutils/29218] libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

cqwrteur  changed:

   What|Removed |Added

 CC||amodra at gmail dot com

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


[Bug binutils/29218] libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

--- Comment #3 from cqwrteur  ---
BTW. The xmalloc thing should be just __builtin_trap(). No more debugging
information and recovery thank you.

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


[Bug binutils/29218] libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

--- Comment #4 from cqwrteur  ---
void* xmalloc(size_t sz) noexcept
{
void* ptr = malloc(sz);
if(!ptr)
__builtin_trap();
return ptr;
}

Thank you. Since stdio on mingw-w64 bloats binary size.

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


[Bug binutils/29218] libiberty cannot find __imp___acrt_iob_func for x86_64-w64-mingw32 cross toolchain for canadian compilation

2022-06-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29218

--- Comment #5 from cqwrteur  ---
https://sourceware.org/git/?p=binutils-gdb.git;a=commitdiff;h=b0de9ed86f3af84fbd636f94a58b9c4ad7f4e743

well it looks like this does not fix Canadian compilation.

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


[Bug gprofng/29593] New: error: '__u64' undeclared (first use in this function) for aarch64-linux-musl host

2022-09-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29593

Bug ID: 29593
   Summary: error: '__u64' undeclared (first use in this function)
for aarch64-linux-musl host
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: gprofng
  Assignee: vladimir.mezentsev at oracle dot com
  Reporter: euloanty at live dot com
  Target Milestone: ---

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


[Bug gprofng/29593] error: '__u64' undeclared (first use in this function) for aarch64-linux-musl host

2022-09-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29593

cqwrteur  changed:

   What|Removed |Added

 CC||euloanty at live dot com
 Target||aarch64-linux-musl
   Host||aarch64-linux-musl
  Build||x86_64-linux-gnu

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


[Bug gprofng/29593] error: '__u64' undeclared (first use in this function) for aarch64-linux-musl host

2022-09-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29593

--- Comment #1 from cqwrteur  ---
Created attachment 14341
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14341&action=edit
bug

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


[Bug gold/29678] Unsupported target for loongrach64-linux-gnu for linker

2022-10-12 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29678

cqwrteur  changed:

   What|Removed |Added

 Target||loongarch64-linux-gnu
   Host||x86_64-linux-gnu
  Build||x86_64-linux-gnu

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


[Bug gold/29678] Unsupported target for loongrach64-linux-gnu for linker

2022-10-12 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29678

cqwrteur  changed:

   What|Removed |Added

 CC||euloanty at live dot com,
   ||liuzhensong at loongson dot cn

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


[Bug gold/29678] New: Unsupported target for loongrach64-linux-gnu for linker

2022-10-12 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29678

Bug ID: 29678
   Summary: Unsupported target for loongrach64-linux-gnu for
linker
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: gold
  Assignee: ccoutant at gmail dot com
  Reporter: euloanty at live dot com
CC: ian at airs dot com
  Target Milestone: ---

configure: error: "unsupported target loongarch64-unknown-linux-gnu"
make[1]: *** [Makefile:6809: configure-gold] Error 1
make[1]: Leaving directory
'/home/cqwrteur/toolchains_build/gcc_build/native/loongarch64-linux-gnu/binutils-gdb'
make: *** [Makefile:1004: all] Error 2

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


[Bug ld/29797] New: error while loading shared libraries: unexpected PLT reloc type 0x00

2022-11-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29797

Bug ID: 29797
   Summary: error while loading shared libraries: unexpected PLT
reloc type 0x00
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: ld
  Assignee: unassigned at sourceware dot org
  Reporter: euloanty at live dot com
  Target Milestone: ---

#include

[[__gnu__::__target__("avx2")]]
inline void foo()
{
puts("avx2\n");
}

[[__gnu__::__target__("default")]]
inline void foo()
{
puts("default\n");
}

int main()
{
foo();
}

$ g++ -o a a.cc -Ofast -std=c++23 -s -flto
$ ./a
./a: error while loading shared libraries: unexpected PLT reloc type 0x00
$ g++ -o a a.cc -Ofast -std=c++23 -s -flto -fuse-ld=gold
$ ./a
avx2

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


[Bug ld/29797] error while loading shared libraries: unexpected PLT reloc type 0x00

2022-11-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29797

cqwrteur  changed:

   What|Removed |Added

 CC||euloanty at live dot com

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


[Bug ld/29797] error while loading shared libraries: unexpected PLT reloc type 0x00

2022-11-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29797

--- Comment #1 from cqwrteur  ---
gold linker works while ld does not work for __gnu__::__target__ attribute.

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


[Bug ld/29797] error while loading shared libraries: unexpected PLT reloc type 0x00

2022-11-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29797

cqwrteur  changed:

   What|Removed |Added

Version|unspecified |2.40 (HEAD)

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


[Bug ld/29797] error while loading shared libraries: unexpected PLT reloc type 0x00

2022-11-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29797

--- Comment #2 from cqwrteur  ---
BTW

why [[__gnu__::__target__("sha")]] does not work while

[[__gnu__::__target__("ssse3,sha")]] would compile but not with clang??

https://godbolt.org/z/bTfTM8chz

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


[Bug binutils/29866] New: Build stuck at "checking for ELF support in BFD..." for x86_64-w64-mingw32 host at canadian compilation

2022-12-08 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29866

Bug ID: 29866
   Summary: Build stuck at "checking for ELF support in BFD..."
for x86_64-w64-mingw32 host at canadian compilation
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: binutils
  Assignee: unassigned at sourceware dot org
  Reporter: euloanty at live dot com
  Target Milestone: ---

checking compiler warning flags...  -Wall -Wpointer-arith -Wno-unused
-Wunused-value -Wunused-variable -Wunused-function -Wno-switch
-Wno-char-subscripts -Wempty-body -Wunused-but-set-parameter
-Wunused-but-set-variable -Wno-sign-compare -Wno-error=maybe-uninitialized
-Wno-mismatched-tags -Wsuggest-override -Wimplicit-fallthrough=3
-Wduplicated-cond -Wshadow=local -Wdeprecated-copy -Wdeprecated-copy-dtor
-Wredundant-move -Wmissing-declarations -Wstrict-null-sentinel -Wno-format
checking for cygwin... no
checking for ELF support in BFD...

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


[Bug binutils/29866] Build stuck at "checking for ELF support in BFD..." for x86_64-w64-mingw32 host at canadian compilation

2022-12-08 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29866

cqwrteur  changed:

   What|Removed |Added

 Target||x86_64-w64-mingw32
 CC||euloanty at live dot com
   Host||x86_64-w64-mingw32
  Build||x86_64-linux-gnu

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


[Bug binutils/29866] Build stuck at "checking for ELF support in BFD..." for x86_64-w64-mingw32 host at canadian compilation

2022-12-13 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29866

--- Comment #2 from cqwrteur  ---
(In reply to Alan Modra from comment #1)
> This is in libctf configure.  For me, I see the following in
> libctf/config.log:
> configure:14586: checking for ELF support in BFD
> configure:14606: ./libtool --quiet --mode=link x86_64-w64-mingw32-gcc -o
> conftest.exe -I/home/alan/src/binutils-gdb/libctf/../include -I../bfd
> -I/home/alan/src/binutils-gdb/libctf/../bfd -g -O2  -L../bfd
> -L../libiberty -L../zlib  -Wl,--stack,12582912 conftest.c -lbfd -liberty -lz
> >&5
> configure:14606: $? = 0
> configure:14614: result: yes
> 
> So the bug report is really asking "Why does my compiler hang?", and there
> isn't any way for me to answer that.
> 
> My conftest.c for the test is:
> /* confdefs.h */
> #define PACKAGE_NAME "libctf"
> #define PACKAGE_TARNAME "libctf"
> #define PACKAGE_VERSION "1.2.0"
> #define PACKAGE_STRING "libctf 1.2.0"
> #define PACKAGE_BUGREPORT ""
> #define PACKAGE_URL ""
> #define STDC_HEADERS 1
> #define HAVE_SYS_TYPES_H 1
> #define HAVE_SYS_STAT_H 1
> #define HAVE_STDLIB_H 1
> #define HAVE_STRING_H 1
> #define HAVE_MEMORY_H 1
> #define HAVE_STRINGS_H 1
> #define HAVE_INTTYPES_H 1
> #define HAVE_STDINT_H 1
> #define HAVE_UNISTD_H 1
> #define __EXTENSIONS__ 1
> #define _ALL_SOURCE 1
> #define _GNU_SOURCE 1
> #define _POSIX_PTHREAD_SEMANTICS 1
> #define _TANDEM_SOURCE 1
> #define PACKAGE "libctf"
> #define VERSION "1.2.0"
> #define LT_OBJDIR ".libs/"
> #define _FILE_OFFSET_BITS 64
> #define HAVE_STDLIB_H 1
> #define HAVE_UNISTD_H 1
> #define HAVE_SYS_PARAM_H 1
> #define HAVE_GETPAGESIZE 1
> /* end confdefs.h.  */
> #include 
>#include 
>#include "bfd.h"
>#include "elf-bfd.h"
> int
> main ()
> {
> (void) bfd_section_from_elf_index (NULL, 0);
>return 0;
>   ;
>   return 0;
> }
> 
> The previous failed test in the log will give you your confdefs.h, which may
> be different to mine.  If you run your conftest.c through your compiler by
> hand and it hangs, then you likely have a problem with your compiler rather
> than there being a libctf configure problem.

it is just hanging for no reason

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


[Bug binutils/29866] Build stuck at "checking for ELF support in BFD..." for x86_64-w64-mingw32 host at canadian compilation

2022-12-13 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29866

--- Comment #3 from cqwrteur  ---
checking for ELF support in BFD... libtool: link: Could not determine host path
corresponding to

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


[Bug binutils/29866] Build stuck at "checking for ELF support in BFD..." for x86_64-w64-mingw32 host at canadian compilation

2022-12-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29866

--- Comment #4 from cqwrteur  ---
(In reply to Alan Modra from comment #1)
> This is in libctf configure.  For me, I see the following in
> libctf/config.log:
> configure:14586: checking for ELF support in BFD
> configure:14606: ./libtool --quiet --mode=link x86_64-w64-mingw32-gcc -o
> conftest.exe -I/home/alan/src/binutils-gdb/libctf/../include -I../bfd
> -I/home/alan/src/binutils-gdb/libctf/../bfd -g -O2  -L../bfd
> -L../libiberty -L../zlib  -Wl,--stack,12582912 conftest.c -lbfd -liberty -lz
> >&5
> configure:14606: $? = 0
> configure:14614: result: yes
> 
> So the bug report is really asking "Why does my compiler hang?", and there
> isn't any way for me to answer that.
> 
> My conftest.c for the test is:
> /* confdefs.h */
> #define PACKAGE_NAME "libctf"
> #define PACKAGE_TARNAME "libctf"
> #define PACKAGE_VERSION "1.2.0"
> #define PACKAGE_STRING "libctf 1.2.0"
> #define PACKAGE_BUGREPORT ""
> #define PACKAGE_URL ""
> #define STDC_HEADERS 1
> #define HAVE_SYS_TYPES_H 1
> #define HAVE_SYS_STAT_H 1
> #define HAVE_STDLIB_H 1
> #define HAVE_STRING_H 1
> #define HAVE_MEMORY_H 1
> #define HAVE_STRINGS_H 1
> #define HAVE_INTTYPES_H 1
> #define HAVE_STDINT_H 1
> #define HAVE_UNISTD_H 1
> #define __EXTENSIONS__ 1
> #define _ALL_SOURCE 1
> #define _GNU_SOURCE 1
> #define _POSIX_PTHREAD_SEMANTICS 1
> #define _TANDEM_SOURCE 1
> #define PACKAGE "libctf"
> #define VERSION "1.2.0"
> #define LT_OBJDIR ".libs/"
> #define _FILE_OFFSET_BITS 64
> #define HAVE_STDLIB_H 1
> #define HAVE_UNISTD_H 1
> #define HAVE_SYS_PARAM_H 1
> #define HAVE_GETPAGESIZE 1
> /* end confdefs.h.  */
> #include 
>#include 
>#include "bfd.h"
>#include "elf-bfd.h"
> int
> main ()
> {
> (void) bfd_section_from_elf_index (NULL, 0);
>return 0;
>   ;
>   return 0;
> }
> 
> The previous failed test in the log will give you your confdefs.h, which may
> be different to mine.  If you run your conftest.c through your compiler by
> hand and it hangs, then you likely have a problem with your compiler rather
> than there being a libctf configure problem.

why would the GCC have issues? I run it with GCC manually and GCC does not
hang. However. here it hangs for build

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


[Bug binutils/29866] Build stuck at "checking for ELF support in BFD..." for x86_64-w64-mingw32 host at canadian compilation

2022-12-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29866

--- Comment #5 from cqwrteur  ---
Created attachment 14517
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14517&action=edit
hang

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


[Bug binutils/29866] Build hang at "checking for ELF support in BFD..." for x86_64-w64-mingw32 host at canadian compilation

2022-12-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29866

cqwrteur  changed:

   What|Removed |Added

Summary|Build stuck at "checking|Build hang at "checking for
   |for ELF support in BFD..."  |ELF support in BFD..." for
   |for x86_64-w64-mingw32 host |x86_64-w64-mingw32 host at
   |at canadian compilation |canadian compilation

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


[Bug ld/29973] New: x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

Bug ID: 29973
   Summary: x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r:
section below image base for windows
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: ld
  Assignee: unassigned at sourceware dot org
  Reporter: euloanty at live dot com
  Target Milestone: ---

x86_64-w64-mingw32-g++ -o helloworld helloworld.cc -Ofast -std=c++23 -s -flto
-march=native -I../../include
/home/cqwrteur/toolchains/x86_64-pc-linux-gnu/x86_64-w64-mingw32/lib/gcc/x86_64-w64-mingw32/13.0.0/../../../../x86_64-w64-mingw32/bin/ld:
helloworld.exe:.rdata_r: section below image base

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 Target||x86_64-w64-mingw32
 CC||euloanty at live dot com

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #1 from cqwrteur  ---
clang + lld works but ld does not. Yes, it is the issue that relates to ld
linker.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

Version|unspecified |2.41 (HEAD)

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

   Severity|normal  |critical

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #2 from cqwrteur  ---
Nobody comes and fixes this?

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 CC||jwakely.gcc at gmail dot com

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-14 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

   Priority|P2  |P1

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-22 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 CC||lh_mouse at 126 dot com

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-22 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #3 from cqwrteur  ---
Is that a mingw-w64 issue or libstdc++ issue? Or is it just because of the ld
linker?

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-24 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #5 from cqwrteur  ---
nope. none of them work. I can only make it work with lld.
it does not work when the code dynamically linked with libstdc++
Probably it is the latest patch on GCC that changes the win32 thread model
causes the issue.

I am now using win32 thread model of GCC but libstdc++ cannot dynamically link.

It works when -static-libstdc++ is used. My guess is that it might be either ld
or libstdc++’s issues.



From: nickc at redhat dot com 
Sent: Tuesday, January 24, 2023 8:24:58 AM
To: euloa...@live.com 
Subject: [Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r:
section below image base for windows

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

Nick Clifton  changed:

   What|Removed |Added

 CC||nickc at redhat dot com

--- Comment #4 from Nick Clifton  ---
Hi cqwrteur,

  I am afraid that we are going to need some more information before we can get
to the bottom of this issue.  For example:

  * What is the code in helloworld.cc ?
  * Why is the "-s" option being used ?
  * Does the problem still occur if "-s" is not used ?
  * Similarly, does omitting "-flto" make the linking work ?

It would help if you could upload the compiled form of helloworld.cc (ie
helloworld.o).  I did try to reproduce the problem myself, but the link worked.
 I was however using gcc version 11 not version 13.

Also which version of the linker are you using ?

Cheers
  Nick

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

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-24 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 CC||jwakely.gcc at gmail dot com

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-24 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #6 from cqwrteur  ---
(In reply to cqwrteur from comment #5)
> Created attachment 14622 [details]
> C249694B8E474FF2AE570A876F184D45.png
> 
> nope. none of them work. I can only make it work with lld.
> it does not work when the code dynamically linked with libstdc++
> Probably it is the latest patch on GCC that changes the win32 thread model
> causes the issue.
> 
> I am now using win32 thread model of GCC but libstdc++ cannot dynamically
> link.
> 
> It works when -static-libstdc++ is used. My guess is that it might be either
> ld or libstdc++’s issues.
> 
> 
> 
> From: nickc at redhat dot com 
> Sent: Tuesday, January 24, 2023 8:24:58 AM
> To: euloa...@live.com 
> Subject: [Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r:
> section below image base for windows
> 
> https://sourceware.org/bugzilla/show_bug.cgi?id=29973
> 
> Nick Clifton  changed:
> 
>What|Removed |Added
> 
>  CC||nickc at redhat dot com
> 
> --- Comment #4 from Nick Clifton  ---
> Hi cqwrteur,
> 
>   I am afraid that we are going to need some more information before we can
> get
> to the bottom of this issue.  For example:
> 
>   * What is the code in helloworld.cc ?
>   * Why is the "-s" option being used ?
>   * Does the problem still occur if "-s" is not used ?
>   * Similarly, does omitting "-flto" make the linking work ?
> 
> It would help if you could upload the compiled form of helloworld.cc (ie
> helloworld.o).  I did try to reproduce the problem myself, but the link
> worked.
>  I was however using gcc version 11 not version 13.
> 
> Also which version of the linker are you using ?
> 
> Cheers
>   Nick
> 
> --
> You are receiving this mail because:
> You are on the CC list for the bug.
> You reported the bug.

Hi jwakely, I do not know whether it is an issue that relates to win32 thread
model of libstdc++ or it is the issue with gnu ld. Can you investigate it for
me? Thanks.

cqwrteur@HOME-SERVER:~/Libraries/fast_io/examples/0001.helloworld$
x86_64-w64-mingw32-g++ -o helloworld helloworld.cc -Ofast -I../../include
-std=c++23 -static-libstd
c++
cqwrteur@HOME-SERVER:~/Libraries/fast_io/examples/0001.helloworld$
x86_64-w64-mingw32-g++ -o helloworld helloworld.cc -Ofast -I../../include
-std=c++23
/home/cqwrteur/toolchains/x86_64-pc-linux-gnu/x86_64-w64-mingw32/lib/gcc/x86_64-w64-mingw32/13.0.0/../../../../x86_64-w64-mingw32/bin/ld:
helloworld.exe:.rdata_r: section below image base

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-24 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #8 from cqwrteur  ---
(In reply to Jonathan Wakely from comment #7)
> (In reply to cqwrteur from comment #6)
> > Hi jwakely, I do not know whether it is an issue that relates to win32
> > thread model of libstdc++ or it is the issue with gnu ld. Can you
> > investigate it for me? Thanks.
> 
> No.

What if it is libstdc++'s issue? I can statically link libstdc++ but I cannot
do that dynamically. dynamically linking libgcc still works but libstdc++ does
not.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-24 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #9 from cqwrteur  ---
(In reply to Jonathan Wakely from comment #7)
> (In reply to cqwrteur from comment #6)
> > Hi jwakely, I do not know whether it is an issue that relates to win32
> > thread model of libstdc++ or it is the issue with gnu ld. Can you
> > investigate it for me? Thanks.
> 
> No.

yes

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-24 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #10 from cqwrteur  ---
(In reply to Nick Clifton from comment #4)
> Hi cqwrteur,
> 
>   I am afraid that we are going to need some more information before we can
> get to the bottom of this issue.  For example:
> 
>   * What is the code in helloworld.cc ?
>   * Why is the "-s" option being used ?  
>   * Does the problem still occur if "-s" is not used ?
>   * Similarly, does omitting "-flto" make the linking work ?
> 
> It would help if you could upload the compiled form of helloworld.cc (ie
> helloworld.o).  I did try to reproduce the problem myself, but the link
> worked.  I was however using gcc version 11 not version 13.
> 
> Also which version of the linker are you using ?
> 
> Cheers
>   Nick

just any C++ code that would link to libstdc++

#include

int main()
{
std::cout<<"Hello World\n";
}

For example
remove -s -flto flags they all fail while -fuse-ld=lld would work.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-25 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #11 from cqwrteur  ---
Does the issue come from this patch?

https://github.com/mirror/mingw-w64/commit/fc55e181b2d84c8817e3fd9d86c6944ac709acc9

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-25 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #13 from cqwrteur  ---
lld does not work for canadian building compiler

Get Outlook for Android

From: nickc at redhat dot com 
Sent: Wednesday, January 25, 2023 8:37:38 AM
To: euloa...@live.com 
Subject: [Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r:
section below image base for windows

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

--- Comment #12 from Nick Clifton  ---
(In reply to cqwrteur from comment #10)

> just any C++ code that would link to libstdc++
>
> #include
>
> int main()
> {
> std::cout<<"Hello World\n";
> }
>
> For example
> remove -s -flto flags they all fail while -fuse-ld=lld would work.

I tried that, but the compilation and link still works for me.  As I said
though, I am using gcc 11 not gcc 13.

(In reply to cqwrteur from comment #11)
> Does the issue come from this patch?
>
> https://github.com/mirror/mingw-w64/commit/
> fc55e181b2d84c8817e3fd9d86c6944ac709acc9

It could do - I am not familiar with the mingw-w64 runtime code, so I cannot
really say.

If you have a workaound - using lld - then I would stick with that for now.

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

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-01-26 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #15 from cqwrteur  ---
it is because of gcc 13 i guess. Old versions of mingw-w64 have the same issue.
it is probably libstdc++'s problem since recently they made changes on adding
C++ standard library threading support for win32 thread model

Get Outlook for Android

From: nickc at redhat dot com 
Sent: Thursday, January 26, 2023 7:38:27 AM
To: euloa...@live.com 
Subject: [Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r:
section below image base for windows

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

--- Comment #14 from Nick Clifton  ---
Well I have just tried x86_64-w64-mingw32-g++ from Fedora rawhide (which is
based on gcc version 12) and I still cannot reproduce the problem.  So I am
beginning to suspect that it is gcc version 13 specific.

Are you using a home built version of x86_64-w64-mingw32, or have you
downloaded it from somewhere ?

Please could you create a helloworld.o object file and upload that ?  Maybe
with that I will be able to reproduce the problem.

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

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #16 from cqwrteur  ---
Created attachment 14649
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14649&action=edit
libstdc++.dll.a

I think the issue comes with libstdc++.dll.a but I am not sure. Can you have a
look at libstdc++.dll.a?

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-03 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 CC||jakub at redhat dot com

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-03 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #19 from cqwrteur  ---
(In reply to Nick Clifton from comment #18)
> Created attachment 14652 [details]
> Proposed patch
> 
> Interesting.  The issue is the section itself: .rdata_r.  This is not a
> normal PE section name, and it is missing from the default script used by
> the linker.  So instead the orphan section handling code is activated, and
> this places the section into the .rdata section.  But in doing so, it also
> sets the vaddr for the .rdata section to 0.
> 
> The .rdata_r section is being created by the LTO plugin when it recompiles
> helloworld.cc.  I am not sure why this is happening.  But there is an easy
> fix - add the .rdata_r section to the default linker map.  So that is what
> this patch does.
> 
> Please try out the patch and let me know if it works for you.

thank you it is working now.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-05 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #20 from cqwrteur  ---
(In reply to Nick Clifton from comment #18)
> Created attachment 14652 [details]
> Proposed patch
> 
> Interesting.  The issue is the section itself: .rdata_r.  This is not a
> normal PE section name, and it is missing from the default script used by
> the linker.  So instead the orphan section handling code is activated, and
> this places the section into the .rdata section.  But in doing so, it also
> sets the vaddr for the .rdata section to 0.
> 
> The .rdata_r section is being created by the LTO plugin when it recompiles
> helloworld.cc.  I am not sure why this is happening.  But there is an easy
> fix - add the .rdata_r section to the default linker map.  So that is what
> this patch does.
> 
> Please try out the patch and let me know if it works for you.

Please merge the patch. It is important for me

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-05 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #21 from cqwrteur  ---
(In reply to cqwrteur from comment #20)
> (In reply to Nick Clifton from comment #18)
> > Created attachment 14652 [details]
> > Proposed patch
> > 
> > Interesting.  The issue is the section itself: .rdata_r.  This is not a
> > normal PE section name, and it is missing from the default script used by
> > the linker.  So instead the orphan section handling code is activated, and
> > this places the section into the .rdata section.  But in doing so, it also
> > sets the vaddr for the .rdata section to 0.
> > 
> > The .rdata_r section is being created by the LTO plugin when it recompiles
> > helloworld.cc.  I am not sure why this is happening.  But there is an easy
> > fix - add the .rdata_r section to the default linker map.  So that is what
> > this patch does.
> > 
> > Please try out the patch and let me know if it works for you.
> 
> Please merge the patch. It is important for me

The code compiles but it crashes for dynamically linking libstdc++-6.dll

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-06 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #23 from cqwrteur  ---
(In reply to cqwrteur from comment #22)
> (In reply to cqwrteur from comment #21)
> > (In reply to cqwrteur from comment #20)
> > > (In reply to Nick Clifton from comment #18)
> > > > Created attachment 14652 [details]
> > > > Proposed patch
> > > > 
> > > > Interesting.  The issue is the section itself: .rdata_r.  This is not a
> > > > normal PE section name, and it is missing from the default script used 
> > > > by
> > > > the linker.  So instead the orphan section handling code is activated, 
> > > > and
> > > > this places the section into the .rdata section.  But in doing so, it 
> > > > also
> > > > sets the vaddr for the .rdata section to 0.
> > > > 
> > > > The .rdata_r section is being created by the LTO plugin when it 
> > > > recompiles
> > > > helloworld.cc.  I am not sure why this is happening.  But there is an 
> > > > easy
> > > > fix - add the .rdata_r section to the default linker map.  So that is 
> > > > what
> > > > this patch does.
> > > > 
> > > > Please try out the patch and let me know if it works for you.
> > > 
> > > Please merge the patch. It is important for me
> > 
> > The code compiles but it crashes for dynamically linking libstdc++-6.dll
> 
> #include
> 
> int main()
> {
> std::cout<<"Hello World\n";
> }
> 
> cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ x86_64-w64-mingw32-g++ -o
> iostream iostream.cc -Ofast -std=c++23
> cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ wine ./iostream.exe
> wine: Unhandled page fault on read access to 0004FEAABE98 at address
> 0003BE9ED6CD (thread 00d8), starting debugger...
> Unhandled exception: page fault on read access to 0x4feaabe98 in 64-bit code
> (0x000
> 3be9ed6cd).
>  ignore
> 
> x86_64-w64-mingw32-g++ -o iostream iostream.cc -Ofast -std=c++23 -fuse-ld=lld
> cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ ./iostream.exe ^C
> cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ wine ./iostream.exe
> Hello World

The ld linker is still buggy.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-06 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #22 from cqwrteur  ---
(In reply to cqwrteur from comment #21)
> (In reply to cqwrteur from comment #20)
> > (In reply to Nick Clifton from comment #18)
> > > Created attachment 14652 [details]
> > > Proposed patch
> > > 
> > > Interesting.  The issue is the section itself: .rdata_r.  This is not a
> > > normal PE section name, and it is missing from the default script used by
> > > the linker.  So instead the orphan section handling code is activated, and
> > > this places the section into the .rdata section.  But in doing so, it also
> > > sets the vaddr for the .rdata section to 0.
> > > 
> > > The .rdata_r section is being created by the LTO plugin when it recompiles
> > > helloworld.cc.  I am not sure why this is happening.  But there is an easy
> > > fix - add the .rdata_r section to the default linker map.  So that is what
> > > this patch does.
> > > 
> > > Please try out the patch and let me know if it works for you.
> > 
> > Please merge the patch. It is important for me
> 
> The code compiles but it crashes for dynamically linking libstdc++-6.dll

#include

int main()
{
std::cout<<"Hello World\n";
}

cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ x86_64-w64-mingw32-g++ -o
iostream iostream.cc -Ofast -std=c++23
cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ wine ./iostream.exe
wine: Unhandled page fault on read access to 0004FEAABE98 at address
0003BE9ED6CD (thread 00d8), starting debugger...
Unhandled exception: page fault on read access to 0x4feaabe98 in 64-bit code
(0x000
3be9ed6cd).
 ignore

x86_64-w64-mingw32-g++ -o iostream iostream.cc -Ofast -std=c++23 -fuse-ld=lld
cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ ./iostream.exe ^C
cqwrteur@HOME-SERVER:~/Libraries/fast_io/.tmp$ wine ./iostream.exe
Hello World

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #25 from cqwrteur  ---
(In reply to Nick Clifton from comment #24)
> Created attachment 14656 [details]
> Proposed patch
> 
> Hi,
> 
>   Oops - I forgot about section names containing the $ character.
> 
>   Please could you try out this revised patch and let me know if it works
> properly this time.
> 
> Cheers
>   Nick

looks like it is working now. However, I will try to build CMake to try whether
it works out.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #26 from cqwrteur  ---
(In reply to cqwrteur from comment #25)
> (In reply to Nick Clifton from comment #24)
> > Created attachment 14656 [details]
> > Proposed patch
> > 
> > Hi,
> > 
> >   Oops - I forgot about section names containing the $ character.
> > 
> >   Please could you try out this revised patch and let me know if it works
> > properly this time.
> > 
> > Cheers
> >   Nick
> 
> looks like it is working now. However, I will try to build CMake to try
> whether it works out.

cqwrteur@HOME-SERVER:~/Temp$ wine ./iostream.exe
wine: Unhandled page fault on read access to 0004FEAABEB0 at address
0003BE9ED6CD (thread 00ec), starting debugger...
Unhandled exception: page fault on read access to 0x4feaabeb0 in 64-bit code
(0x000
3be9ed6cd).
Register dump:

No it is still not working for iostream

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #27 from cqwrteur  ---
Created attachment 14659
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14659&action=edit
iostream

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-09 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #29 from cqwrteur  ---
Created attachment 14666
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14666&action=edit
This is my build script

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-09 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #28 from cqwrteur  ---
(In reply to Nick Clifton from comment #24)
> Created attachment 14656 [details]
> Proposed patch
> 
> Hi,
> 
>   Oops - I forgot about section names containing the $ character.
> 
>   Please could you try out this revised patch and let me know if it works
> properly this time.
> 
> Cheers
>   Nick

Hello can you further investigate the issue here?

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-13 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #30 from cqwrteur  ---
(In reply to Nick Clifton from comment #24)
> Created attachment 14656 [details]
> Proposed patch
> 
> Hi,
> 
>   Oops - I forgot about section names containing the $ character.
> 
>   Please could you try out this revised patch and let me know if it works
> properly this time.
> 
> Cheers
>   Nick

Hello. Could you fix it? Since the bug makes it impossible to use gcc on
windows.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #33 from cqwrteur  ---
(In reply to Nick Clifton from comment #32)
> Hi,
> 
>   I am wondering if there are two problems here, rather than just one.  So
> please could you check a couple of things for me ?
> 
>   1. Does iostream.exe fail to run if built without LTO ?
>   2. Where does iostream.exe fail ?  Is it before main(), or when the
> libstdc++ library is being loaded, or somewhere else ?
> 
> Thanks
>   Nick

it fails to run without lto. yes

when libstdc++ library is being loaded.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #34 from cqwrteur  ---
(In reply to cqwrteur from comment #33)
> (In reply to Nick Clifton from comment #32)
> > Hi,
> > 
> >   I am wondering if there are two problems here, rather than just one.  So
> > please could you check a couple of things for me ?
> > 
> >   1. Does iostream.exe fail to run if built without LTO ?
> >   2. Where does iostream.exe fail ?  Is it before main(), or when the
> > libstdc++ library is being loaded, or somewhere else ?
> > 
> > Thanks
> >   Nick
> 
> it fails to run without lto. yes
> 
> when libstdc++ library is being loaded.

if it is -static-libstdc++ then it works. Or it just crashes the program. I
tried with lld and it works even with GCC or clang with/without lto.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #35 from cqwrteur  ---
(In reply to Nick Clifton from comment #32)
> Hi,
> 
>   I am wondering if there are two problems here, rather than just one.  So
> please could you check a couple of things for me ?
> 
>   1. Does iostream.exe fail to run if built without LTO ?
>   2. Where does iostream.exe fail ?  Is it before main(), or when the
> libstdc++ library is being loaded, or somewhere else ?
> 
> Thanks
>   Nick

I have tried. Looks like this issue only happens when iostream is included
since iostream has a static global variable that causes issues.

https://github.com/gcc-mirror/gcc/blob/07f497c2da3600cc99cd7d1b5c6726972fb2b5a1/libstdc%2B%2B-v3/include/std/iostream#L78

https://github.com/gcc-mirror/gcc/blob/ec59848074ba8c4310cbadb603822bfaeff03a32/libstdc%2B%2B-v3/src/c%2B%2B98/ios_base_init.h

#if __has_attribute(init_priority)
static ios_base::Init __ioinit __attribute__((init_priority(90)));
#endif

It has this new init_priority attribute. Perhaps ld fails to understand PE
targets while lld does?

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #36 from cqwrteur  ---
https://github.com/gcc-mirror/gcc/commit/ec59848074ba8c4310cbadb603822bfaeff03a32

See this

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 CC||jwakely.gcc at gmail dot com

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-16 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #37 from cqwrteur  ---
jwakely do you think it is caused by __init_priority__ ?

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-02-23 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #38 from cqwrteur  ---
(In reply to Nick Clifton from comment #32)
> Hi,
> 
>   I am wondering if there are two problems here, rather than just one.  So
> please could you check a couple of things for me ?
> 
>   1. Does iostream.exe fail to run if built without LTO ?
>   2. Where does iostream.exe fail ?  Is it before main(), or when the
> libstdc++ library is being loaded, or somewhere else ?
> 
> Thanks
>   Nick

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

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-03-06 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #39 from cqwrteur  ---
(In reply to Nick Clifton from comment #14)
> Well I have just tried x86_64-w64-mingw32-g++ from Fedora rawhide (which is
> based on gcc version 12) and I still cannot reproduce the problem.  So I am
> beginning to suspect that it is gcc version 13 specific.
> 
> Are you using a home built version of x86_64-w64-mingw32, or have you
> downloaded it from somewhere ?
> 
> Please could you create a helloworld.o object file and upload that ?  Maybe
> with that I will be able to reproduce the problem.

As March has already begun, it would be appreciated if the bug for binutils-gdb
could be resolved as soon as possible before the official release in April.

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-03-11 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

--- Comment #40 from cqwrteur  ---
(In reply to Nick Clifton from comment #32)
> Hi,
> 
>   I am wondering if there are two problems here, rather than just one.  So
> please could you check a couple of things for me ?
> 
>   1. Does iostream.exe fail to run if built without LTO ?
>   2. Where does iostream.exe fail ?  Is it before main(), or when the
> libstdc++ library is being loaded, or somewhere else ?
> 
> Thanks
>   Nick

Still crashes today. Please fix this asap.

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


[Bug ld/30254] New: iostream crashes with ld linker for windows targets

2023-03-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

Bug ID: 30254
   Summary: iostream crashes with ld linker for windows targets
   Product: binutils
   Version: unspecified
Status: UNCONFIRMED
  Severity: normal
  Priority: P2
 Component: ld
  Assignee: unassigned at sourceware dot org
  Reporter: euloanty at live dot com
  Target Milestone: ---

Bug issue 29973 was a mess. So I decided to start a new one and close bug
29973.

GCC 13 made several changes to iostream, including making it with an
__init_priority__ and changing the definition due to the updated win32 thread
model changes.

I do not know what breaks it. But any program that uses std::cout/std::cin now
will crash when dynamically linked with libstdc++. I have tried LLVM lld. lld
does not crash the program, but ld crashes.

This breaks nearly all C++ programs on windows since they may use iostream in
some places, and the entire program crashes.

Maybe ld linker does not correctly deal with __init_priority__ for PE targets.
However, I am not an expert on the linker and do not know why.

It is very near April, and we will get the latest binutils and GCC 13
published, and GCC 14 will be very soon. This issue needs to be addressed as
soon as possible so we do not break Windows programs and GCC bootstrapping when
GCC 13 is released.

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-03-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

cqwrteur  changed:

   What|Removed |Added

   Priority|P2  |P1
   Severity|normal  |critical
 Target||pe targets

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


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-03-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 Resolution|--- |MOVED
 Status|ASSIGNED|RESOLVED

--- Comment #41 from cqwrteur  ---
move for issue 30254

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-03-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

cqwrteur  changed:

   What|Removed |Added

 CC||euloanty at live dot com

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-04-01 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

cqwrteur  changed:

   What|Removed |Added

 CC||nickc at redhat dot com

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


[Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking

2023-04-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

cqwrteur  changed:

   What|Removed |Added

   Priority|P2  |P1

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


[Bug ld/30375] New: C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking

2023-04-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

Bug ID: 30375
   Summary: C++ std::cout's rdbuf gives ridiculous address on
windows with dynamic linking
   Product: binutils
   Version: 2.41 (HEAD)
Status: UNCONFIRMED
  Severity: critical
  Priority: P2
 Component: ld
  Assignee: unassigned at sourceware dot org
  Reporter: euloanty at live dot com
  Target Milestone: ---

struct foo
{

foo()
{
__builtin_puts("hello\n");
}
};
foo f{};

#include

foo death{};

int main()
{
__builtin_puts("before crashing\n");
__builtin_printf("%p\n",std::cout.rdbuf());
__builtin_puts("crashing\n");
}
Here is an example:

>g++ -o hw hw.cc -Ofast -s -I../include

>hw
hello

hello

before crashing

6156746547736C54
crashing

Using lld:

>g++ -o hw hw.cc -Ofast -s -I../include -fuse-ld=lld

>hw
hello

hello

before crashing

7FFFA97A4C00
crashing

>g++ -o hw hw.cc -Ofast -s -I../include -static

D:\msys64\home\unlvs\projects\fast_io\.temp>hw
hello

hello

before crashing

7FF62687E8C0
crashing


What happens here??

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


[Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking

2023-04-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

cqwrteur  changed:

   What|Removed |Added

 Target||x86_64-w64-mingw32

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


[Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking

2023-04-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

--- Comment #1 from cqwrteur  ---
6156746547736C54 is clearly not a possible address.

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


[Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking with ld

2023-04-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

cqwrteur  changed:

   What|Removed |Added

Summary|C++ std::cout's rdbuf gives |C++ std::cout's rdbuf gives
   |ridiculous address on   |ridiculous address on
   |windows with dynamic|windows with dynamic
   |linking |linking with ld

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


[Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking with ld

2023-04-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

cqwrteur  changed:

   What|Removed |Added

 Depends on||29973


Referenced Bugs:

https://sourceware.org/bugzilla/show_bug.cgi?id=29973
[Bug 29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below
image base for windows
-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29973] x86_64-w64-mingw32-g++ ld: helloworld.exe:.rdata_r: section below image base for windows

2023-04-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29973

cqwrteur  changed:

   What|Removed |Added

 Blocks||30375


Referenced Bugs:

https://sourceware.org/bugzilla/show_bug.cgi?id=30375
[Bug 30375] C++ std::cout's rdbuf gives ridiculous address on windows with
dynamic linking with ld
-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking with ld

2023-04-21 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

cqwrteur  changed:

   What|Removed |Added

 CC||euloanty at live dot com

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


[Bug ld/30375] C++ std::cout's rdbuf gives ridiculous address on windows with dynamic linking with ld

2023-05-07 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

cqwrteur  changed:

   What|Removed |Added

 CC||nickc at redhat dot com,
   ||nickc at sourceware dot org

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-05-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

--- Comment #2 from cqwrteur  ---
(In reply to Alan Modra from comment #1)
> Does this problem still occur after my patch for pr30343?

Yes, it still occurs. Just crashing for hello world.

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-05-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

--- Comment #3 from cqwrteur  ---
(In reply to cqwrteur from comment #2)
> (In reply to Alan Modra from comment #1)
> > Does this problem still occur after my patch for pr30343?
> 
> Yes, it still occurs. Just crashing for hello world.

30375

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-05-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

--- Comment #4 from cqwrteur  ---
https://sourceware.org/bugzilla/show_bug.cgi?id=30375

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-05-20 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

--- Comment #5 from cqwrteur  ---
(In reply to Alan Modra from comment #1)
> Does this problem still occur after my patch for pr30343?

Please fix this asap. I have reported this for half a year and it is still
unfixed. This breaks basically everything for me.

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-05-21 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

cqwrteur  changed:

   What|Removed |Added

 CC||amodra at gmail dot com

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


[Bug ld/30254] iostream crashes with ld linker for windows targets

2023-05-21 Thread euloanty at live dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=30254

--- Comment #6 from cqwrteur  ---
Created attachment 14891
  --> https://sourceware.org/bugzilla/attachment.cgi?id=14891&action=edit
ld missing import of ios_base_library_init

I use lld and it imports one more symbol than ld. 
I guess it is the reason since libstdc++ does this:
#ifdef _GLIBCXX_SYMVER_GNU
#pragma GCC diagnostic ignored "-Wattribute-alias"

  void ios_base_library_init (void)
  __attribute__((alias ("_ZNSt8ios_base4InitC1Ev")));
#endif


https://github.com/gcc-mirror/gcc/blob/master/libstdc%2B%2B-v3/src/c%2B%2B98/ios_init.cc

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


  1   2   3   >