GNU ToolChains Cross Compiler C/C++library issue

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello

I built a GNU toolchain using the main parameter below:

build=i686-w64-mingw32

host=i686-w64-mingw32

target=x86_64-pc-elf

I used GCC 11.3 , binutil 2.40 and newlib 4.3.0

I created executives with prefix x86_64-pc-elf-...exe

But when I try to build a simple application using this toolchain in eclipse

#include <vector>
using namespace std;

int main()
{
    std::vector <int> v;
    return 0;
}

D:\MinGWCompUpdates\msys\1.0\build\x86_64-pc-elf_11.3.0_odk\x86_64-pc-elf\newlib\x86_64-pc-elf\x32\pic\newlib/../../../../../../newlib-4.3.0/newlib/libc/stdlib/abort.c:59:
undefined reference to `_exit'

D:\MinGWCompUpdates\msys\1.0\build\x86_64-pc-elf_11.3.0_odk\x86_64-pc-elf\newlib\x86_64-pc-elf\x32\pic\newlib/../../../../../../newlib-4.3.0/newlib/libc/reent/fstatr.c:55:
undefined reference to `fstat'

D:\MinGWCompUpdates\msys\1.0\build\x86_64-pc-elf_11.3.0_odk\x86_64-pc-elf\newlib\x86_64-pc-elf\x32\pic\newlib/../../../../../../newlib-4.3.0/newlib/libc/reent/isattyr.c:52:
undefined reference to `isatty'

......

I'm guessing it's a static library issue, at the link stage When I change
the optimization Level other than 0, the problem goes away.

I guess that there when I built toolchains library functions are not fully
created.

Note : I have set the library path correctly.

I tried to built a simple app using cross compiler toolchains that I built.
but I got linker errors.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux