This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Compiling gcc-2.95.2 for use as m68k cross compiler


Hi Kai et. al.,

Let me start with the most important:

> PS. I will disappear to a skiing vacation for a week, but not taking no other
> 'plasm expanders' than just a little ethyl-alcohol, mixed into beer, I'll
> promise... Perhaps mixed into a little brandy too because of the under 20
> Celsius temperature (meaning 'cognac', people here don't prefer 'brandy' at
> all, it is much cheaper and so on, if they don't see the bottle, they seldom
> taste the difference...)

I hope you have a great time!  As for me, I'd never make a promise like
"just a *little* ethyl-alcohol..."!  You've mentioned beer, brandy and
cognac - but what about gin!?  My poison of preference is the coldest,
driest Martini possible. Given the 'under 20 Celsius temperature' I'd keep a
stash of the bottle *and the glasses* outside - with a twist of lemon, I'd
need nothing else...

(So maybe now you know why I can't remember your suggestions from one email
to the next, :-)


Ok, back to building...

Here are the steps I have taken so far and I will add steps that your last
response suggest in order to build the cross-compiler:

1. Got the gcc-2.95.2 sources
2. Untarred them into /h/crossgcc/gcc-2.95.2
3. Applied the patch file that purportedly changes some things to get this
to compile for MachTen (on a Mac).
4. Edited ../gcc-2.95.2/gcc/config/m68k/m68k-none.h to make 68332 the
default
5. Edited ../gcc-2.95.2/gcc/config/m68k/t-m68kbare and commented out all the
lines that reference MULTI* - here is the snippet from that file as it
stands now:

-------------------------- clip -----------------------
#MULTILIB_OPTIONS = m68000/m68020/m5200/mcpu32 m68881/msoft-float
#MULTILIB_DIRNAMES =
#MULTILIB_MATCHES = m68000=mc68000 m68000=m68302 mcpu32=m68332
m68020=mc68020 m68020=m68040
 m68020=m68060
#MULTILIB_EXCEPTIONS = m68000/msoft-float m5200/m68881 m5200/msoft-float
mcpu32/m68881 mcpu
32/msoft-float

#LIBGCC = stmp-multilib
INSTALL_LIBGCC = install-multilib
-------------------------- clip -----------------------

As you can see, I have left the 'INSTALL_LIBGCC' uncommented - is this
correct for what I want to do? (Kai, this is how I've interpreted your
suggestions on this matter, however, we all know how well I've interpreted
your suggestions in the past!)

6. Created a /h/crossgcc/build-gcc295 directory
7. From that build directory, ran ../gcc-2.95.2/configure --target=m68k-coff

8. New suggested step: Make the following directory:
/usr/local/lib/gcc-lib/m68k-coff/2.95.2

9. make all


These are the steps that I will try now.

Have I got the above right - is there anything else I should do? (Besides
checking on the temperature of that bottle, that is, :-)

Thanks!



> From: Kai Ruottu <kai.ruottu@luukku.com>
> Organization: Freenet Finland
> Reply-To: karuottu@freenet.hut.fi
> Date: Fri, 02 Mar 2001 12:24:38 +0200
> To: Mark Palmerino <mbp@csr-bos.com>
> Cc: crossgcc@sourceware.cygnus.com
> Subject: Re: Compiling gcc-2.95.2 for use as m68k cross compiler
> 
> Mark Palmerino wrote:
>> 
>> I am taking Kai's gentle suggestions to consider using gcc-2.95.2 as the
>> base for building a cross-compiler with the target of m68k-coff.  I am in
>> that process now.
>> 
>> I have run into a problem that I'm hoping someone might suggest a solution
>> for. Here is the output during the make where it stops. It seems that there
>> is a "configure error" when checking whether the C compiler works. The funny
>> thing though is that I think it was working in the make before this point.
> 
> Of course the compiler works, but the linking doesn't work... How else it
> could
> be ?
> 
>> configure: error: installation or configuration problem: C compiler cannot
>> create executables.
> 
> The compiler doesn't create executables, it only compiles the source into
> an assembly source...
> 
>> checking whether the C compiler (/h/crossgcc/build-gcc295/gcc/xgcc
>> -B/h/crossgcc/build-gcc295/gcc/ -B/usr/local/m68k-coff/bin/ -g -O2 ) works...
>> no
>> configure: error: installation or configuration problem: C compiler cannot
>> create executables.
> 
> If you look at the '-B/usr/local/m68k-coff/bin/' in the command line, you will
> see that there must be something really wrong with the search paths for 'xgcc'
> !!!
> Otherwise this wouldn't be here. It helps the 'xgcc' to find the 'as' and 'ld'
> when
> building a compiler if they are in the '$prefix/$target/bin'. The '/usr/lib'
> and
> '/usr/include' will be found automatically for a native compiler. Nothing else
> for
> a cross-compile included...
> 
> All the target stuff is accessed via the '$prefix/lib/gcc-lib/$target/2.95.x'
> with
> gcc-2.95.x, like the target headers:
> 
> E:\usr\local\lib\gcc-lib\m68k-coff\2_95.3>cpp0 -v
> GNU CPP version 2.95.3 20010101 (prerelease) (68k, Motorola syntax)
> #include "..." search starts here:
> #include <...> search starts here:
> \usr\local\lib\gcc-lib\m68k-coff\2_95.3\..\..\..\..\include
> \usr\local\lib\gcc-lib\m68k-coff\2_95.3\include
> \usr\local\lib\gcc-lib\m68k-coff\2_95.3\..\..\..\..\m68k-coff\sys-include
> \usr\local\lib\gcc-lib\m68k-coff\2_95.3\..\..\..\..\m68k-coff\include
> End of search list.
> 
> So the workaround for gcc-2.95.2 in your case is the pre-creation of the:
> 
> /usr/local/lib/gcc-lib/m68k-coff/2.95.2
> 
> Then and only then the target stuff will be found by the 'xgcc'...
> 
> You must also fix the 'specs' just as you did with the gcc-2.8.1. Everything
> is the same as with it, the BCC as the target, using a linker script --- you
> can use the 'rm_rom.ld' now, and so on... I would suggest you to use the
> prebuilt
> libs and headers from the Objsw-package, or to install the GCC in this phase,
> leaving the libiberty and libstdc++ builds later, and building & installing
> newlib with your new GCC. It really is ready now, the extra libs are only
> missing. I prefer to install with my own install template, but 'make
> all-install-gcc'
> or something which installs only the stuff in the 'gcc' subdir, should work...
> 
> Cheers, Kai
> 
> PS. I will disappear to a skiing vacation for a week, but not taking no other
> 'plasm expanders' than just a little ethyl-alcohol, mixed into beer, I'll
> promise...
> Perhaps mixed into a little brandy too because of the under 20 Celsius
> temperature
> (meaning 'cognac', people here don't prefer 'brandy' at all, it is much
> cheaper
> and so on, if they don't see the bottle, they seldom taste the difference...)
> 
> 
> ------
> Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
> Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com
> 
> 
> 


------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]