Linux on an Apple Powerbook G4
By Jochen Voss, last updated .
This text describes the adventures I encountered while installing Linux
on an
Apple Powerbook G4 (15″ version, 1.67GHz).
It seems that with Apple's numbering scheme the machine is a
PowerBook5,6
. If you have questions or additional hints, feel
free to contact me.
The page was originally written in spring 2005, when the machine was new on the market. After a while I got bored by the many difficulties connected to running Linux on the machine and I switched to using MacOS X. Recently I reinstalled the current Debian/unstable distribution on the machine and was happy to notice that Linux support has significantly improved.
Contents
Summary
I was able to install Debian GNU/Linux on the machine. The laptop has the hardware configuration Apple introduced in February 2005.
component | hardware identification | status | |
---|---|---|---|
core components | MPC7447A CPU (1.67 GHz) Apple UniNorth 2 chipset IDE hard disk | works | ![]() |
graphics card | ATI RV350 (Mobility Radeon 9600 M10) | works (no 3D accel.) | ![]() |
display | 15.2″ TFT 1280×854 pixels | works | ![]() |
keyboard | internal USB | works needs keymap | ![]() |
track pad | internal USB | works sometimes hangs a bit | ![]() |
Ethernet Controller | Sun GEM | works perfectly | ![]() |
WLAN | Broadcom BCM4306 802.11b/g | works | ![]() |
sound | Snapper | works | ![]() |
external USB | works | ![]() | |
PCMCIA slot | works | ![]() | |
bluetooth | ??? | see below | ![]() |
modem | ??? | not detected | ![]() |
Table 1. This table summarises the hardware support for Post-February-2005 Apple powerbooks under Linux. A plus sign in the last column indicates that the component works out of the box, plus-minus indicates that it can be made to work by applying kernel patches etc. or that it partially works, and a minus indicates that I did not manage to make the component work at all.
Some information about my setup:
- the kernel config file config-2.6.13.2.
- the kernel's boot messages as obtained by dmesg.
- the /proc/cpuinfo contents
- the
lspci -v
output - the
lsusb -v
output
Installation
Nowadays Debian Linux can be installed on the machine from the usual installation media. Initially, when the machine was still very new, I followed the steps described at William R Sowerbutts' Linux on the Mac Mini page. I used the Debian Sarge installer RC2 netinstall image, and the basic installation worked without any trouble.
Keyboard
The Powerbook keyboard needs getting used to: there are no keys for page-up, page-down and the hash mark. Since I was unhappy with the provided key-bindings under Linux, I finally wrote my own ones, aiming for as much MacOS X compatibility as possible.
Originally the kernel produced key press events for the fn
key,
thus allowing it to be bound in the X Window system. For some reason
(which I never understood) this feature was removed in later kernels.
The keymaps in the remaining part of this section are from the time
when fn
could still be bound in keymaps. Nowadays they will
probably be less useful:
- a Linux console keymap for the British keyboard
- a set of files implementing Xorg server key bindings for British, French (thanks, Yves-Alexis Perez) and German keyboards, using the XKB extension
- a set of files implementing old XFree86 server key bindings for the British and German (untested) keyboards, using the XKB extension (eject key does not work due to a bug in XFree86)
Some notes about the key bindings:
- The apple keys (
command
in MacOS) act as meta keys. You can use
to cycle trough your windows andapple-tab
etc. to switch virtual consoles.ctrl-apple-F1
- The alt key (
option
in MacOS) acts as anAltGr
key. You can use it together with other keys to produce all sorts of funny characters as in MacOS X: for the British keyboard
gives the hash markalt-3
#
,
gives the German sharp esszet, andalt-s
gives the Germanalt-u a
ä
umlaut character. - The page-up and page-down keys are at
andfn-up
.fn-down
- Since X11 does not know the concept of an
key, I just mapped the key toeject
. With this setting, you can teach, for example, the Gnome desktop environment to treatF13
as an eject key.F13
Bluetooth
BlueTooth does not work out of the box. I do not own any bluetooth devices, so the following is unchecked. According to Johannes Berg's message to debian-powerpc the following error messages are related to bluetooth support. In the posting he also explains how to get bluetooth working.
... usb 2-1: new full speed USB device using ohci_hcd and address 2 hub 4-0:1.0: USB hub found hub 4-0:1.0: 2 ports detected usb 2-1: device descriptor read/64, error -71 usb 2-1: device descriptor read/64, error -71 usb 2-1: new full speed USB device using ohci_hcd and address 3 usb 2-1: device descriptor read/64, error -71 usb 2-1: device descriptor read/64, error -71 usb 2-2: new full speed USB device using ohci_hcd and address 4 ...
Error -71 above stands for protocol error
(EPROTO
),
error -5 for I/O error
(EIO
).
Other Problems
- At shutdown the pdns daemon gives the following error message:
pdnsd[487]: Caught signal 15. Exiting. pdnsd[492]: Failed to open socket: Bad file descriptor. Status readback will be impossible
The problem does not occur on a (otherwise similar) Intel machine. - For some weird reason xterm does not work! It
opens a window but then dies immediately with the following error message.
xterm: fatal pty error 23 (errno=22) on tty /dev/pts/1
This is reported as Debian bug 229566 and can be worked around by using the following X resource settings:
xterm*eightBitInput: true xterm*metaSendsEscape: true
- For some time my system clock was randomly reset after reboot and after waking up the machine from sleep. The problem seems to mostly affect only kernel version 2.6.12 to 2.6.12.2. I never saw this problem with kernel 2.6.11. With 2.6.12 and 2.6.12.2 the clock was very often (approx. one in three cases) very wrong (more than a year in a random direction). With 2.6.12.3 the clock was off by approximately an hour for a few times.
References
- Information about the processor can be found on Freescale Semiconductor's MPC7447A Product Summary Page. The Programming Environments Manual describes the PowerPC assembler language in great detail.
- the debian-powerpc mailing list
- Johannes Berg's PowerBook page contains information about the special keys and the trackpad.
- the Linux Broadcom 4301 Driver Project
- Stelian Pop's Apple Touchpad Driver
- Doug Palmer, An Unreliable Guide to XKB Configuration
- the ATI R300 project might provide 3D acceleration support for the graphics card in the future
- the penguinppc.org web page
- Werner Heuser's TuxMobil website contains a wealth of information about installing and running Linux on laptops.