Mandriva

Return to the main archive index.

Custom Search

Mandrake Linux Archives: cooker-ppc@mandrivalinux.org

Mandrake Linux: cooker-ppc@mandrivalinux.org


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]


Hi Craig,

Nice report. I was most interested in the MOL part as it is my next experiment with my Mac Mini. The reason being that you can get the Airport Extreme working with LInux and MOL if this site is to be believed: http://forums.gentoo.org/viewtopic-t-365647.html
I haven't had the time yet to give it a go but your description of how to get MOL running will certainly make it a bit easier.

Cheers,

Donald

On 18 Sep 2005, at 21:04, Craig Miller wrote:

Hello All,

I recently spent the last couple of weeks getting Mandriva LE2005 working on my new Powerbook G4 (15"), and I wanted to share some tips to configuration. I installed Mandriva LE2005 off of the 3 CDs, and then pointed my urpmi sources to cooker for additional packages.

Installation
The first thing I did with my brand new PowerBook was to boot MacOSX (which was preinstalled) to ensure the machine worked. The second thing I did was push in CD1 of the Mandriva LE2005 set, and blow away the hard drive, as I wanted this to be primarily a linux machine, with the ability to run MacOSX (dual boot, as well as inside MOL).

The installation went pretty smooth, except the boot partition section. I don't know why I always seem to have problems with this section. I had created a small boot partition (to be used by yaboot/ybin) but it wasn't formatted at partition time (my mistake) and once you get to the install boot partion time, it is too late to format. So I got to install twice.

In the partitioning tool, I chose "custom" and "resized" the MacOSX partition, which in reality is somewhat useless, since it says resizing will delete all info on that partition. But it was a convenient way to make additional space for linux partitions.

After the second install (this time with an HFS formatted boot partion) it was time to eject the CD's and boot into Linux.

Once I could reliably get into Linux, it was time to put MacOSX on the machine. So I used the 2 DVDs (included) to install MacOSX (tiger) back on the slightly less roomy hard drive. This confuses the machine about booting. It no longer wants to boot into Linux.

So it was time to drop down to OpenFirmware with holding down the command+option+O+F keys while rebooting the Powerbook. Once in OpenFirmware, you better know where your boot partition is (mine was 4). I used the command:
boot hd:4,\\yaboot

This got yaboot up, and from there I was able to boot Mandriva. Once in Mandriva, I quickly checked /etc/yaboot.conf to make sure it looked sane, and perhaps add the option to boot into macosx, and then ran ybin to bless my boot partition so I wouldn't have to visit OpenFirmware again.

After all that installation fun, it was time to configure a few things in Linux.

Sound
Run a minimum kernel of 2.6.12-6mdk. The 2.6.11 doesn't support sound (for some reason). I didn't do anything special other than use this kernel (or later) to get sound.

Sleep
To get good reliable sleep (on the PB), I recommend using pbbuttonsd-0.7.1-1mdk. There are still other problems (like setting how long before the PB falls asleep) but over all this is pretty useful. There a nice GUI for configuring much of what is in pbbuttonsd called powerprefs, be sure to get that as well.

Wireless
I knew going into this purchase that the internal 802.11g (broadcom based) wireless interface wasn't going to work with Linux. I chose the 15" because it had a PCMCIA slot, and I happen to have an old Lucent Tech WaveLAN 802.11b card. I installed the pcmcia software, pcmcia-cs-3.2.8-4mdk. Then there is the configuration, and this is important, because without the right values for the PB, at best pcmcia won't work, and at worst, it hangs up the PB, and a reboot is required. The 2 config files of interest are as follows and then edit the lines below the file names:
/etc/pcmcia/config.opts
        include port0x100-0x4ff, port 0x1000-0x17ff
        include memory 0xa7000000-0xa7ffffff
/etc/sysconfig/pcmcia
        PCMCIA=yes
        PCIC=yenta_socket
Once this is done, start up pcmcia services "service pcmcia start" and if you have a light on your card, you should see it. Then it is time to configure the network. I used
drakconf (or drakconnect directly). In there, IP address, DNS, ESSID, and WEP can be configured.

X
The basic install (from the CD) does a good job at getting X working. But I found I needed to tweak it a bit to get it into 24 bit (which works better with MOL). I used drakconf again to adjust the hardware setup, which picked the correct video driver (I had been using fbdev) which is radeon. I then edited manually the /etc/X11/xorg.conf file:
    Section "Screen"
       DefaultColorDepth 24
        Subsection "Display"
            Depth 24
            Virtual 1280 854
        EndSubsection

     Section "Device"
        Identifier "device1"
        VendorName "ATI"
        BoardName "ATI Radeon (fglrx)"
        Driver "radeon"
        BusID "PCI:0:16:0"
        Option "DPMS"

This yields about 21 fps with glxgears at full screen. Certainly not a game-bustin' speed, but plenty fast for me.

Touchpad
Bad news, this one doesn't work out of the box. Apparently Apple has moved to a USB touchpad, and all the old stuff doesn't work any longer. It is so dead, I had to use an external USB mouse for all my X work. With the help of Danny, I was able to try his latest Multimedia Kernel (2.6.12-11.mm.mdk). This is the only kernel that works with the PB G4 touchpad. I expect it to be on cooker soon.

But I didn't realize that this kernel was working with the touchpad for several days, because if an external mouse is plugged in at boot up, it somehow disables the touchpad. The trick here is to ensure that any external mice are not plugged in at boot time.

Just booting (without an external mouse) gives basic mouse functionality with the touchpad. That is it moves the pointer, and pressing the button will click. But there is no tap, no drag, and so forth. Fortunately there is more that can be done with the touchpad. A synaptics driver (synaptics-0.14.2) can be downloaded and compiled from: http://www.popies.net/atp/ along with some very good information on configuring xorg.conf to use the driver.
My reworked /etc/X11/xorg.conf now has the following for mouse/touchpad support:
Section "InputDevice"
    Identifier "Mouse1"
    Driver "mouse"
    Option "Protocol" "IMPS/2"
    Option "Device" "/dev/mouse"
    Option "Emulate3Buttons"
    Option "Emulate3Timeout" "50"
    Option "ZAxisMapping" "4 5"
    Option "Buttons" "5"
EndSection

Along with the Synaptics section which I pasted in directly from the website. I had to change 2 lines because I don't tap as fast as the author:
     Option      "MaxTapMove"         "220"
     Option      "MaxTapTime"         "180"

The synaptics driver brings quite a bit of functionality to the touchpad, you can see the webpage (and be sure to read the README in the driver tarball). But the features I am enjoying most are 2 and 3 finger tapping (giving me middle and right button taps), freeing me from having to reach for a modifier key to get to middle and right mouse buttons. And vertical scrolling is the other feature I am really liking. Moving one's finger up and down the right side of the touchpad vertically scrolls the window. I have tried enabling horizontal scrolling, but apparently not much in the way of apps supports it at this time.

MOL
The tricky part about MOL is the kernel modules. Now that I had a working Multimedia kernel, it was only a matter of compiling the kernel modules and I would be up and running. Unfortunately, it didn't work quite that smoothly. Cooker is supporting gcc 4.0, and LE2005 comes with gcc 3.4. The prebuilt kernel Danny had given me was built with gcc 4.0, and my compiling MOL kernel modules (KLMs) in gcc 3.4 didn't work (well, compiling works, the modules just don't insert). So I either had to upgrade fully to cooker gcc 4.0 (and a bunch of stuff that comes with that) or rebuild the multimedia kernel with gcc 3.4. I chose the latter. After compiling and installing the kernel with gcc 3.4 (2.6.12-11.mm.4mdkcustom) I was able to rebuild those MOL kernel modules and get MOL up and running.

Well not quite, since this new PB G4 came with Tiger, and a patch is required for Tiger and MOL (which can be retrieved from: http://www-user.rhrk.uni-kl.de/~nissler/mol/index.html)

I ended up recompiling mol-0.9.71 with a couple of additional patches:
mol-0.9.71-gcc4-2.6.12.patch             
mol-0.9.71-skbuff-mac-fix.patch
mol-0.9.71-kmod-unresolved-symbols.patch
mol_rsync_tiger.diff

After all that patching, the compiling went pretty smoothly. All that was left was to configure MOL to run on the new PB. In the /etc/mol directory, edit:
molrc.video
    resolution:              1280/854/75     # width/height/Hz
    depth:                      24
    start_on_console:    yes

You may want to edit molrc.osx and give it a bit more RAM than the puny 96MB default.
    ram_size:               192

Be sure to run molvconfig before starting mol. I selected the first settings that came up, and skipped the rest.

Then finally it was time to start mol with the command: startmol -X

The screen switches to vt8 and if all goes well you presented with a penguin hugging an apple, and eventually the MacOSX login screen. Switching back to Linux is just a matter of pressing ctrl+option+f7. Works like charm.

I installed the MOL "drivers" once in MacOSX, rebooted MacOSX and was able to configure a new ethernet interface (en2). MOL sets up NAT and a mini DHCPd (server) which gives MacOSX the ip address of 192.168.41.2  I was able to ping out to the internet, and surf the web.

Having run Linux on my Powerbook G3 (Pismo) for the past 4 years, I haven't had much experience with MacOSX, but it is nice to have it there if I need it.

Moving In

Moving my data from my old PB to the new went much smoother than I had expected. I was able to run a DVD+RW of my /home, then insert the disk into the new PB G4. I chose to use tar rather than cp to copy the info from the DVD to my new /home, as I wanted to preserve the dates of my files, by first cd'ing into /mnt/cdrom, then issuing the command: tar cf . - | (cd /home; tar xvf - )

In the space of an hour or so all my data was transferred over to the new PB G4.

Wrapping Up
I hope this helps in understanding what can be done to setup Mandriva LE2005 on the new Powerbook G4. It took a bit of work to get a working, useful machine, and I couldn't have done it with out the help of the folks on the cooker-ppc list. Thanks to all for your help.












Date Index | Thread Index

Looking for a job?



Advertisement (via La Vignette)