mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

91 lines
3.6 KiB

  1. Introduction
  2. ------------
  3. This configuration offers a cross-build of (a subset of) the build-bootstrap
  4. package selection for the sparc architecture as emulated by qemu-system-sparc.
  5. It includes support for most of the hardware emulated by qemu, a working udev,
  6. kernel and userland support for TCP/IP networking, and more.
  7. With qemu and the resulting build you can at least:
  8. - boot the kernel and first stage initrd,
  9. - execute a shell from the initrd,
  10. - mount NFS file systems,
  11. - load the second stage from a CD-ROM or HTTP server,
  12. - and install packages from the CD on a hard disc.
  13. The packages included should be sufficient for native builds on the targeted
  14. platform.
  15. Quick Start
  16. -----------
  17. - Boot from CD with framebuffer (PROM console):
  18. qemu-system-sparc -cdrom bbs-sparc-qemu_cd1.iso -hda /srv/qemu.hda \
  19. -boot d
  20. - Boot from CD with serial console:
  21. qemu-system-sparc -cdrom bbs-sparc-qemu_cd1.iso -hda /srv/qemu.hda \
  22. -boot d -append "console=ttyS0 video=tcxfb:off" -nographic
  23. Hints And Known Bugs
  24. --------------------
  25. - To use the CD image in qemu, create it after the build has finished:
  26. ./scripts/Create-ISO bbs-sparc-qemu bbs-sparc-qemu
  27. - To use a hard disk in qemu, create it with e.g.:
  28. qemu-img create /srv/qemu.hda 2048M
  29. - When using a console on the serial port, be sure to enter 'ttyS0' as the
  30. terminal device in boot stage 2, or you won't get to see the command line.
  31. - glibc26 does not build for sparc with -Os because extern inline functions are
  32. not used when optimizing for size, resulting in a missing __ieee754_sqrtl
  33. function for libm_pic.a; glibc-2.6/sysdeps/sparc/sparc32/fpu/e_sqrtl.c
  34. is compiled but glibc-2.6/sysdeps/sparc/sparc32/soft-fp/q_sqrt.c contains
  35. the actual __ieee754_sqrtl function.
  36. - the SCSI support in kernel is not compiled as a module because udev can't
  37. load it automatically, and loading it and creating the /dev entries manually,
  38. the SCSI devices don't work. Furthermore, if partitioning a previously empty
  39. hard disk, the new partitions won't show up until after a reboot.
  40. - the size of the uncompressed kernel image (/boot/image) is limited to 2,5 MB
  41. when booting with silo. Because of this limit the framebuffer driver is not
  42. compiled into the kernel (and cannot be compiled as a module).
  43. - strace does not (cross-)build for sparc yet.
  44. - To access HTTP or NFS servers in qemu, add the following options:
  45. -net nic -net tap
  46. You need root privileges for this, or have your system administrator set it
  47. up for you. When qemu starts it will create a network interface (tap0) on the
  48. host system and add an IP address/netmask (172.20.0.1/16) to it:
  49. host:/# ip addr show dev tap0
  50. 19: tap0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN qlen 500
  51. link/ether 00:ff:e1:75:9a:a0 brd ff:ff:ff:ff:ff:ff
  52. inet 172.20.0.1/16 brd 172.20.255.255 scope global tap0
  53. inet6 fe80::2ff:e1ff:fe75:9aa0/64 scope link
  54. valid_lft forever preferred_lft forever
  55. In the first boot stage of the emulated system, execute a shell, set up the
  56. network link and add an IP address on the same network:
  57. sh-3.2# ip link set up dev eth0
  58. [ 41.026595] eth0: link up
  59. sh-3.2# ip addr add 172.20.0.20/16 dev eth0
  60. You should now be able to reach the host system:
  61. sh-3.2# ping -c3 172.20.0.1
  62. PING 172.20.0.1 (172.20.0.1): 56 octets data
  63. 64 octets from 172.20.0.1: icmp_seq=0 ttl=64 time=16.7 ms
  64. 64 octets from 172.20.0.1: icmp_seq=1 ttl=64 time=1.6 ms
  65. 64 octets from 172.20.0.1: icmp_seq=2 ttl=64 time=1.1 ms
  66. --- 172.20.0.1 ping statistics ---
  67. 3 packets transmitted, 3 packets received, 0% packet loss
  68. round-trip min/avg/max = 1.1/6.4/16.7 ms