Do you have a question? Post it now! No Registration Necessary
Subject
- Posted on
- Harro Haan
October 25, 2006, 7:47 pm

I just compiled the m68k-elf-tools (for M68K/Coldfire tools) under Cygwin,
but it should also work for the ARM platform!
make sure the following tools are installed in Cygwin:
gcc-core, gcc-g++, binutils, cpio, make, patch, tar, vim, gettext, libintl
open the Cygwin Bash Shell
mkdir /uClinux
cd /uClinux
download the sources from:
http://www.uclinux.org/pub/uClinux/dist/uClinux-dist-20060803.tar.gz and
save it to the uClinux directory
tar xvzf uClinux-dist-20060803.tar.gz
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/basic/docproc
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/basic/fixdep
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/basic/split-include
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/kconfig/conf
download the following M68K/ColdFire/ARM tool chain sources from:
http://www.uclinux.org/pub/uClinux/m68k-elf-tools/tools-20060615/ and save
it to the uClinux directory:
build-uclinux-tools.sh
binutils-2.16.tar.gz
elf2flt-20060608.tar.gz
gcc-4.1.1.tar.bz2
genromfs-0.5.1.tar.gz
save
http://www.uclinux.org/pub/uClinux/uclinux-elf-tools/tools-20030314/genromfs-0.5.1-cygwin-020605.patch
to
/uClinux/
vim build-uclinux-tools.sh
change line 57 and 58 when ARM platform
make comments of line 66-67
#LINUXVERS="2.6.16"
#UCLIBCVERS="20060608"
change line 72 into
ROOTDIR="$/uClinux-dist"
change line 86-87 into
KERNEL="$/uClinux-dist/linux-2.6.x"
UCLIBC="$/uClinux-dist/uClibc"
make comments of line 171-172
#rm -rf $
#rm -rf $
make comments of line 275-276
#extract linux-$.tar*
#extract uClibc-$.tar*
change line 877 into
UCLIBC_CONFIG="$/uClinux-dist/uClibc-$.config"
A small patch needs to be applied to the linux kernel, so the following
error doesn't occur:
HOSTLD scripts/kconfig/conf
scripts/kconfig/conf.o:conf.c:(.text+0x91): undefined reference to
`_libintl_gettext'
Get this patch from
http://sources.redhat.com/ml/crossgcc/2006-05/msg00093.html
Save the patch to
/uClinux/uClinux-dist/linux-2.6.x/support_cygwin_cross.patch
cd /uClinux/uClinux-dist/linux-2.6.x/
patch -p1 < support_cygwin_cross.patch
copy the file /uClinux-dist/uClibc/.config from a binary distribution to the
file
/uClinux/uClinux-dist/uClibc/extra/Configs/Config.$.default (where
$ is for example m86k)
or run
/uClinux/uClinux-dist/uClibc/make config
to make one yourself and save /uClinux/uClinux-dist/uClibc/.config to the
file
/uClinux/uClinux-dist/uClibc/extra/Configs/Config.$.default (where
$ is for example m86k)
./build-uclinux-tools.sh continue 2>&1 | tee errs.txt
during STAGE1 all files are extracted
before STAGE3 I had to make a comment (because of linking errors) of line 31
(LIBS := -lcygwin $(LIBS)) in the file
/uClinux/elf2flt-20060608/Makefile.in
mkdir /tftpboot
cd /uClinux/uClinux-dist/uClibc
make clean
cd ..
make config
make dep
make
last but not least, build a binary archive for distribution.
cd /uClinux
./build-uclinux-tools.sh dist
but it should also work for the ARM platform!
make sure the following tools are installed in Cygwin:
gcc-core, gcc-g++, binutils, cpio, make, patch, tar, vim, gettext, libintl
open the Cygwin Bash Shell
mkdir /uClinux
cd /uClinux
download the sources from:
http://www.uclinux.org/pub/uClinux/dist/uClinux-dist-20060803.tar.gz and
save it to the uClinux directory
tar xvzf uClinux-dist-20060803.tar.gz
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/basic/docproc
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/basic/fixdep
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/basic/split-include
remove /uClinux/uClinux-dist/linux-2.6.x/scripts/kconfig/conf
download the following M68K/ColdFire/ARM tool chain sources from:
http://www.uclinux.org/pub/uClinux/m68k-elf-tools/tools-20060615/ and save
it to the uClinux directory:
build-uclinux-tools.sh
binutils-2.16.tar.gz
elf2flt-20060608.tar.gz
gcc-4.1.1.tar.bz2
genromfs-0.5.1.tar.gz
save
http://www.uclinux.org/pub/uClinux/uclinux-elf-tools/tools-20030314/genromfs-0.5.1-cygwin-020605.patch
to
/uClinux/
vim build-uclinux-tools.sh
change line 57 and 58 when ARM platform
make comments of line 66-67
#LINUXVERS="2.6.16"
#UCLIBCVERS="20060608"
change line 72 into
ROOTDIR="$/uClinux-dist"
change line 86-87 into
KERNEL="$/uClinux-dist/linux-2.6.x"
UCLIBC="$/uClinux-dist/uClibc"
make comments of line 171-172
#rm -rf $
#rm -rf $
make comments of line 275-276
#extract linux-$.tar*
#extract uClibc-$.tar*
change line 877 into
UCLIBC_CONFIG="$/uClinux-dist/uClibc-$.config"
A small patch needs to be applied to the linux kernel, so the following
error doesn't occur:
HOSTLD scripts/kconfig/conf
scripts/kconfig/conf.o:conf.c:(.text+0x91): undefined reference to
`_libintl_gettext'
Get this patch from
http://sources.redhat.com/ml/crossgcc/2006-05/msg00093.html
Save the patch to
/uClinux/uClinux-dist/linux-2.6.x/support_cygwin_cross.patch
cd /uClinux/uClinux-dist/linux-2.6.x/
patch -p1 < support_cygwin_cross.patch
copy the file /uClinux-dist/uClibc/.config from a binary distribution to the
file
/uClinux/uClinux-dist/uClibc/extra/Configs/Config.$.default (where
$ is for example m86k)
or run
/uClinux/uClinux-dist/uClibc/make config
to make one yourself and save /uClinux/uClinux-dist/uClibc/.config to the
file
/uClinux/uClinux-dist/uClibc/extra/Configs/Config.$.default (where
$ is for example m86k)
./build-uclinux-tools.sh continue 2>&1 | tee errs.txt
during STAGE1 all files are extracted
before STAGE3 I had to make a comment (because of linking errors) of line 31
(LIBS := -lcygwin $(LIBS)) in the file
/uClinux/elf2flt-20060608/Makefile.in
mkdir /tftpboot
cd /uClinux/uClinux-dist/uClibc
make clean
cd ..
make config
make dep
make
last but not least, build a binary archive for distribution.
cd /uClinux
./build-uclinux-tools.sh dist

Re: Howto compile uClinux tool chain under Cygwin (latest tool chain version of 20060615)
distribution and can be selected in the Kernel configuration. So why is
it necessary to set up a tool chain especially with µC in mind ?
Thanks, Michael
Site Timeline
- » Memory hole
- — Next thread in » Embedded Linux
-
- » How to read the data from the first sector of HDD
- — Previous thread in » Embedded Linux
-
- » Addressing on I2C
- — Newest thread in » Embedded Linux
-
- » Подвох
- — The site's Newest Thread. Posted in » Electronic Circuits (Russian)
-