public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Cross compiling for m68k-uclinux, followup of 'Re: Link tests after   GCC_NO_EXECUTABLES'
@ 2010-01-30  0:10 Elden Crom
  2010-01-31 17:46 ` Kai Ruottu
  0 siblings, 1 reply; 3+ messages in thread
From: Elden Crom @ 2010-01-30  0:10 UTC (permalink / raw)
  To: gcc-help

On an 'Linux eldenlinux2 2.6.31-17-generic i686 GNU/Linux' with 'gcc
version 4.4.1' I tried several variants of:

../gcc-4.4.3/configure --target=m68k-uclinux --enable-multilib
--enable-threads \
    --disable-libmudflap --disable-libssp --disable-libgomp \
    --enable-languages=c,c++ \
    --disable-nls            \
    --disable-lto
(Not that I understand all of the options.) I get:
Configuring in m68k-uclinux/libstdc++-v3
...
checking for shl_load... configure: error: Link tests are not allowed
after GCC_NO_EXECUTABLES.
make[1]: *** [configure-target-libstdc++-v3] Error 1
...

If I add '--with-newlib' the error changes......

../gcc-4.4.3/configure --target=m68k-uclinux --enable-multilib
--enable-threads \
    --disable-libmudflap --disable-libssp --disable-libgomp \
    --enable-languages=c,c++ \
    --disable-nls            \
    --disable-lto            \
    --with-newlib
(Not that I understand all of the options.) I get:
Configuring in m68k-uclinux/libstdc++-v3
...
checking for type equivalent to int8_t... configure: error: no 8-bit type
/e/gcc10/ewc/gcc-4.4.3/libstdc++-v3/configure: line 116577: exit:
please: numeric argument required
/e/gcc10/ewc/gcc-4.4.3/libstdc++-v3/configure: line 116577: exit:
please: numeric argument required


The rest of it compiles if I remove libstdc++ from the
../gcc-4.4.3/configure, but then I can't do c++.


The related patches seem to be resolved...
Did "Re: Link tests after GCC_NO_EXECUTABLES" get fixed
(http://gcc.gnu.org/ml/gcc/2007-11/msg00875.html).
If so what was the resolution?
What is the resultant switch? (--cache-file? ,
--simulate-link-tests=file_with_results?)
Is don't see it on http://gcc.gnu.org/install/configure.html, but its
a big document! It would seem to belong in the
"Cross-Compiler-Specific Options".

Should this be sent to gcc@gcc.gnu.org?

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Cross compiling for m68k-uclinux, followup of 'Re: Link tests  after   GCC_NO_EXECUTABLES'
  2010-01-30  0:10 Cross compiling for m68k-uclinux, followup of 'Re: Link tests after GCC_NO_EXECUTABLES' Elden Crom
@ 2010-01-31 17:46 ` Kai Ruottu
  2010-02-01 20:31   ` Elden Crom
  0 siblings, 1 reply; 3+ messages in thread
From: Kai Ruottu @ 2010-01-31 17:46 UTC (permalink / raw)
  To: Elden Crom; +Cc: gcc-help

Elden Crom wrote:
> On an 'Linux eldenlinux2 2.6.31-17-generic i686 GNU/Linux' with 'gcc
> version 4.4.1' I tried several variants of:
>
> ./gcc-4.4.3/configure --target=m68k-uclinux --enable-multilib
> --enable-threads \
>     --disable-libmudflap --disable-libssp --disable-libgomp \
>     --enable-languages=c,c++ \
>     --disable-nls            \
>     --disable-lto
> (Not that I understand all of the options.) I get:
> Configuring in m68k-uclinux/libstdc++-v3
> ..
> checking for shl_load... configure: error: Link tests are not allowed
> after GCC_NO_EXECUTABLES.
> make[1]: *** [configure-target-libstdc++-v3] Error 1
> ..
>   

The prerequisites for producing GCC from sources should be quite 
well-known :

1. the target binutils (a native system has these usually, for a 
cross-host they must be built and
    installed)

2. the target C library (a native system has this usually, for a 
cross-host it must be installed)

When configuring libstdc++ the target C library will be investigated via 
link tests.  If one
cannot even compile and link a "Hello World" with the just made new 
GCC,  ie. there is
no headers and libraries for the target or something is wrong in them, 
then libstdc++ cannot
be configured and built....

Probably somewhere there is a pre-made 'uClibc' for 'uCLinux/m68k'.  If 
so, then download
and install it where it belongs!   If not, you must build it from its 
sources and install it before
you can continue.

Installing (only) GCC happens via the (should be) well-known :

    make install-gcc

With gcc-4.4.3 you probably must install 'libgcc' separately :

   make install-target-libgcc

After doing this you can try a "Hello World" for 'm68k-uclinux'  and see 
what is wrong...

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Cross compiling for m68k-uclinux, followup of 'Re: Link tests   after GCC_NO_EXECUTABLES'
  2010-01-31 17:46 ` Kai Ruottu
@ 2010-02-01 20:31   ` Elden Crom
  0 siblings, 0 replies; 3+ messages in thread
From: Elden Crom @ 2010-02-01 20:31 UTC (permalink / raw)
  To: Kai Ruottu; +Cc: gcc-help

On Sun, Jan 31, 2010 at 10:47 AM, Kai Ruottu <kai.ruottu@wippies.com> wrote:
> Elden Crom wrote:
>>
>> On an 'Linux eldenlinux2 2.6.31-17-generic i686 GNU/Linux' with 'gcc
>> version 4.4.1' I tried several variants of:
>>
>> ./gcc-4.4.3/configure --target=m68k-uclinux --enable-multilib
>> --enable-threads \
>>    --disable-libmudflap --disable-libssp --disable-libgomp \
>>    --enable-languages=c,c++ \
>>    --disable-nls            \
>>    --disable-lto
>> (Not that I understand all of the options.) I get:
>> Configuring in m68k-uclinux/libstdc++-v3
>> ..
>> checking for shl_load... configure: error: Link tests are not allowed
>> after GCC_NO_EXECUTABLES.
>> make[1]: *** [configure-target-libstdc++-v3] Error 1
>> ..
>>
>
> The prerequisites for producing GCC from sources should be quite well-known
> :
>
> 1. the target binutils (a native system has these usually, for a cross-host
> they must be built and
>   installed)

I have built and installed the binutils for m68k-uclinux.
If I only
 --enable-languages=c
and install gcc
Then gcc works fine for C files.
It's only broken if I enable c++.
Furthermore, if I
sed configure  -i.bck -e "s/noconfigdirs=\"\"/noconfigdirs=\"\"
#EWC\nnoconfigdirs=\"target-libstdc++-v3\" #EWC/"
(ie remove the listdc++ from being compiled) then g++ will compile and
install as well.
And make valid executables when linking to differently made (read
'old') crt1.o, crt1, etc and libstdc++.


>
> 2. the target C library (a native system has this usually, for a cross-host
> it must be installed)

Looking at the config script, it appears to have already decided that
It cannot even compile C++ tests, even though it just compiled the g++
compiler.
Is this the "--with-system......" option?


>
> When configuring libstdc++ the target C library will be investigated via
> link tests.  If one
> cannot even compile and link a "Hello World" with the just made new GCC,
>  ie. there is
> no headers and libraries for the target or something is wrong in them, then
> libstdc++ cannot
> be configured and built....
>
> Probably somewhere there is a pre-made 'uClibc' for 'uCLinux/m68k'.  If so,
> then download
> and install it where it belongs!   If not, you must build it from its
> sources and install it before
> you can continue.
>
> Installing (only) GCC happens via the (should be) well-known :
>
>   make install-gcc
>
> With gcc-4.4.3 you probably must install 'libgcc' separately :
>
>  make install-target-libgcc
>

'make install' will do both, right?

> After doing this you can try a "Hello World" for 'm68k-uclinux'  and see
> what is wrong...
>
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-02-01 20:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-30  0:10 Cross compiling for m68k-uclinux, followup of 'Re: Link tests after GCC_NO_EXECUTABLES' Elden Crom
2010-01-31 17:46 ` Kai Ruottu
2010-02-01 20:31   ` Elden Crom

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).