[uClinux-dev] Does anyone have m68knommu running with current uClibc and gcc 4.3?
lsorense at csclub.uwaterloo.ca
Wed Feb 25 14:36:01 EST 2009
I have tried for quite a number of days (or maybe a couple of weeks now)
to get a working m68knommu setup with something resembling current code.
I have managed to take the build-uclinux-tools.sh along with the versions
of software it wants and get a working build, but it is all rather old.
I would prefer to be working from something current, so I have been
trying to update each piece to get something working but newer, and so
far it isn't working.
The version that works consists of:
linux 2.6.16 headers
uClibc 20060608 (appears to be 0.9.27)
I have managed to update binutils to 2.19 without breaking anything
(just took a small fix to one .S file in uClibc to do that).
With this combination, I can compile user space programs that run.
To update gcc to 4.3.2 I have to update the uClibc version (so I got
0.9.30) and the kernel headers (which I wanted anyhow, since I am actually
running a 2.6.29-rc3 kernel at the moment).
So binutils 2.19 and gcc 4.3.2 is compiling the kernel just fine,
and the kernel boots. However user space programs do not execute,
but simply return error 1 and never do anything.
User space programs compiled with gcc 4.1.1 and uClibc 0.9.27 do run
fine on the same kernel.
It seems something is wrong with the userspace code generated by gcc
4.3.2 in this case.
The CPU in question is a coldfire 5271, for which I have used -m5200 or
-m5307, with the same result for both (seems those are the two options
the kernel wants to pick from for this cpu).
I noticed that gcc 4.3.x apparently changed the C calling convention on
the m68k, which I suspect has something to do with the problem, since
uClibc probably needs to be in sync with this change. gcc 4.3 did provide
a target of m68k-uclinuxoldabi for those wishing to stay with the old
ABI, although they did not make sure it could actually be compiled when
you select this target (since it fails to compile when configured for
the oldabi target, with an error involving '#error "What are you doing
with crtstuff.c, then?"' from gcc/crtstuff.c (line 469 in the case of
So does gcc 4.3.x work for anyone on m68knommu with uClibc? Am I trying
something hopeless here, or am I just configuring or compiling it wrong
More information about the uClinux-dev