The binutils 2.15 assembler now automaticly and non-optionally adds
the .eh_frame section for unwind information. This section appears
to wreck havoc to the final boot code. Fix this by using a special
linker script that discards the .eh_frame sections, but is otherwise
identical to the linker internal script used for -N.
Compiler used: gcc 3.3.5
Verified with: binutils 2.14 & binutils 2.15 (stock and in-tree)
Tested with: /boot/loader & /boot/netboot
make(1) wants to build loader.sym *before* the .o files. Eliminating
one seeminly intermediate step avoids the problem. Somehow, it seems
that variables are not getting expanded at the right time.
Any explanations would be appreciated...
Changing:
${BASE}.sym: ${OBJS} ${LIBSTAND} ${LIBFICL} ${LIBALPHA} ${CRT} vers.o
${LD} ...
To:
BASEOBJS= ${OBJS} ${LIBSTAND} ${LIBFICL} ${LIBALPHA} ${CRT} vers.o
${BASE}.sym: ${BASEOBJS}
echo ${BASEOBJS}
${LD} ...
.. the echo only shows LIBFICL, CRT and vers.o. ${OBJS} is not included.
only doing so if loader.rc does not exist. This fixes the problem where
installworld doesn't update /boot/loader.4th, resulting in device.hints not
being loaded after updating past the config(8) changes, which resulted in
mcclock0 not being probed, and a nice kernel panic during boot.
FICL. bootforth is now live on the Alpha!
**BEWARE** - you *MUST* build and install a current libstand or you will
most likely get zfree() panics at loader startup.
We should now be able to set up the loader.conf stuff on the Alpha too.
/boot/loader (even though it is 100% dormant in the Alpha version),
then the loader panics with a zfree error:Loading /boot/loader.test
*** keyboard not plugged in...
Console: SRM firmware console
panic: zfree(0x2003cb58,4096): wild pointer
versus the exact same code but without FICL linked in:
Loading /boot/loader
Console: SRM firmware console
VMS PAL rev: 0x1000600010114
OSF PAL rev: 0x1000600020116
Switch to OSF PAL code succeeded.
FreeBSD/alpha SRM disk boot, Revision 0.1
This is almost certainly an alpha infrastructure bug, not a FICL
problem. It's probably the same thing that made FICL fail for no
apparent reason on the Alpha.