Gentoo Archives: gentoo-dev

From: Roy Marples <uberlord@g.o>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] Gentoo/FreeBSD available for Sparc64
Date: Tue, 31 Oct 2006 09:42:53
Message-Id: 200610310941.25361.uberlord@gentoo.org
1 Hi List!
2
3 The first Gentoo/FreeBSD/Sparc64 stage [1] is ready for testing!
4 There are a few rough edges, namely you have to compile all kernel stuff you
5 need into the kernel as loading modules causes a kernel panic. This is
6 probably a gcc related error as upstream uses gcc-3.4.x by default.
7
8 Installation requires downloading the FreeBSD Sparc64 installation CD. From
9 there you can choose the fixit options to get to a shell where you can
10 partition your disk and follow the usual instructions [2] for stage
11 extraction and system building.
12
13 NOTES
14 All modules have to be built into the kernel - kldload causes kernel panics
15 about memory not aligned. I'm pretty sure this is gcc-4 related as my kernel
16 patch doesn't touch module loading code.
17
18 You can only boot from ad0. You can probably boot from ad1, but I only have
19 the one disk so I cannot say for certain. I'm 99% sure you cannot boot from a
20 specific slice / partition as sparc does not seem too support that.
21
22 Only gcc-4.1 is supported - anything lower will not work for building a
23 kernel. This is because older versions do not correctly define __arch64__
24 when compiling 64-bit code.
25
26 We have a custom FreeBSD patches that replace all __sparc64__ defines to
27 __sparc__ [3]. If the code is really 64-bit related (most is not) then we use
28 the __arch64__ define too. Only FreeBSD sources appear to use the __sparc64__
29 define as I've successfully built and tested large external packages such as
30 postgresql, samba and many more and none of them use that define.
31
32 Some packages assume that sparc CHOST is always sparc-*-* (bug #151715) - this
33 is the case for Linux where the userland is always 32-bit and the kernel is
34 64-bits, but for FreeBSD the kernel won't run any 32-bit code so the CHOST is
35 sparc64-gentoo-freebsdx.x (x.x being the freebsd version).
36
37 Thanks
38
39 [1] http://gentoo.osuosl.org/experimental/sparc/freebsd/
40 [2] http://www.gentoo.org/doc/en/gentoo-freebsd.xml
41 [3] __sparc64__ define is not a guarantee of 64-bit code according to gcc
42 developers
43
44 --
45 Roy Marples <uberlord@g.o>
46 Gentoo Developer (baselayout, networking)
47 --
48 gentoo-dev@g.o mailing list

Replies

Subject Author
Re: [gentoo-dev] Gentoo/FreeBSD available for Sparc64 Mike Frysinger <vapier@g.o>