Page 1 of 1

compiling libsupc++

Posted: Sat Apr 16, 2016 5:06 am
by Techel
Hey, I'd like to compile libsupc++, so I looked at the wiki and typed the following commands into my cygwin bash:

Code: Select all

dude@pc /cygdrive/c/bin/src/gcc-4.8.2
$ ./configure --target=i686-elf --prefix=/cygdrive/c/bin/i686-elf --enable-lang
uages=c,c++ --without-headers --disable-nls
This worked and a makfile was created.

Next I configured libstdc++:

Code: Select all

dude@pc /cygdrive/c/bin/src/gcc-4.8.2/libstdc++-v3
$ CPP=i686-elf-cpp ./configure --host=i686-elf --prefix=/cygdrive/c/bin/i686-el
f --disable-hosted-libstdcxx  --disable-nls
This gave me:

Code: Select all

checking for shl_load... configure: error: Link tests are not allowed after GCC_
NO_EXECUTABLES.
The i686-elf gcc is the one downloadable at the cross-compiler wiki entry. Any Ideas how this can be fixed?

Re: compiling libsupc++

Posted: Mon Jun 06, 2016 10:00 am
by heat
Techel wrote:Hey, I'd like to compile libsupc++, so I looked at the wiki and typed the following commands into my cygwin bash:

Code: Select all

dude@pc /cygdrive/c/bin/src/gcc-4.8.2
$ ./configure --target=i686-elf --prefix=/cygdrive/c/bin/i686-elf --enable-lang
uages=c,c++ --without-headers --disable-nls
This worked and a makfile was created.

Next I configured libstdc++:

Code: Select all

dude@pc /cygdrive/c/bin/src/gcc-4.8.2/libstdc++-v3
$ CPP=i686-elf-cpp ./configure --host=i686-elf --prefix=/cygdrive/c/bin/i686-el
f --disable-hosted-libstdcxx  --disable-nls
This gave me:

Code: Select all

checking for shl_load... configure: error: Link tests are not allowed after GCC_
NO_EXECUTABLES.
The i686-elf gcc is the one downloadable at the cross-compiler wiki entry. Any Ideas how this can be fixed?
I had that problem while trying to compile libsupc++. Basically the problem is that its looking for dlopen() but as it's a bare metal target, it doesn't find any. I was even compiling with a Hosted GCC Compiler, but it still didn't work. I tried to fiddle with the makefile.ac so it got past that point, but still got errors for stuff that's not implemented, so I just gave up.

A more detailed explanation here: https://gcc.gnu.org/ml/gcc/2008-03/msg00515.html (notice OP also had an i686-elf target and was using newlib)

Re: compiling libsupc++

Posted: Mon Jun 06, 2016 10:50 am
by Techel
Thanks for your reply, let's see...