ColdFire GNU C compiler
On this page you'll find out how to download, setup and use my ready built copies of GNU C
for the ColdFire which run under both Linux and Windows 95/98/NT (known hence forth as Win32).
The compiler has the following features:
- Based on the EGCS version of gcc
- Linker scripts and I/O glue for common Motorola ColdFire eval boards.
- Example programs that run on the SBC5206, SBC5206e and SBC5307.
- Comprehensive user documentation
Note: The compiler contained on this site CAN be used to target
any 68000, 683xx, 68020, 68030, 68040 or 68060 series processor with the addition of the relevant
libraries listed below.
What's New
Release 6 of the compiler has the following new features:
- EGCS-1.1.2 and GNU Binutils-2.9.1 based compiler
- 6 months of ColdFire code generation bug fixes including:
- large > 64k C struct code gen error
- duplicate accesses to volatile pointers with -O0
- bad assembly of mul[us] intructions
- shift a 64 bit long long 8 bits to the left bug
- Experimental support for ColdFire MAC assembly (-mmac)
(thanks to Linus Nordberg [linus.nordberg@canit.se])
- Experimental support for ColdFire hardware divide assembly (-mhwdiv)
- New example demonstrating the MAC instructions
(5206e and 5307 users only)
- Updated to support Cygwin Beta 20.1
Updates
If anyone wishes to be notified when a new release of the GNU C compiler binaries is made I have
created a closed mailing list. To subscribe just send an email message (no subject or body required) to
coldfire-gcc-subscribe@fiddes.surfaid.org.
To unsubscribe send a message to
coldfire-gcc-unsubscribe@fiddes.surfaid.org.
The traffic on the list will be very low at around two to three announcements per year.
Installation
Here's the basic installation procedure for the compiler. I would suggest that you read
readme.txt whilst you wait for things to download.
Eric Praetzel has kindly setup a
mirror in Canada if things are slow here.
Win32
- Download instkit.zip(300kb) and unpack
into an empty directory. This gets you the install program.
- Download gcc-m68k-win32-r6.tar.bz2(4.5MB)
which is the compressed archive that contains the compiler. Put this in the
same directory as the installer.
- (Optional) If you want HTML documentation download (Release 5 only for now)
gcc-docs-r5.tar.bz2(500kb).
- (Optional) If you want to use the compiler with CPU32 processors as well
as ColdFire then download cpu32libs-r6.tar.bz2(800kb)
or if you want to target 68000, 68020(+/- fpu), 68060, 68040 and cpu32 then grab
extralibs-r6.tar.bz2(3MB)
- Having downloaded all the archives open up a plain Command Prompt/DOS
box. Go to the installer directory. Run "install c:\coldfire" where
c:\coldfire is the directory considered to be the "Virtual UNIX" root("/").
This will create a setenv.bat file to allocate the path, flush out and
reinstall the registry(note if you have the Cygnus CDK you'll need to
remount some things - beware!) and uncompress the archive(s).
- Run c:\coldfire\setenv.bat and cd to c:\coldfire\gcc-m68k\examples. Run
"make" and it will then proceed to make a series of demo programs..
These examples only run on Arnewsh SBC5206, SBC5206e and SBC5307 ColdFire
eval. boards.
Linux
- Download gcc-m68k-linux-r6.tar.bz2(3MB)
which is the compressed archive that contains the compiler. Put this in an empty directory.
- As root go to / and run: tar -xvf/<somedirectory>/gcc-m68k-linux-r6.tar.bz2 --use-compress-program=bzip2.
If you do not have bzip2 then see the bzip2 website.
- (Optional) If you want HTML documentation download
gcc-docs-r5.tar.bz2(500kb).
- (Optional) If you want to use the compiler with CPU32 processors as well
as ColdFire then download cpu32libs-r6.tar.bz2(800kb)
or if you want to target 68000, 68020(+/- fpu), 68060, 68040 and cpu32 then grab
extralibs-r6.tar.bz2(3MB)
- To unpack option components go to /usr/local and run:
tar -xvf/<somedirectory>/option-file.tar.bz2 --use-compress-program=bzip2
- Cd to /usr/local/gcc-m68k/examples. Run
"make" and it will then proceed to make a series of demo programs..
These examples only run on Arnewsh SBC5206, SBC5206e and SBC5307 ColdFire
eval. boards.
Building
If you want to build your own cross-compiler from scratch then there are two guides one for
Win32 and one for Linux
.