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

A few more Debian/PowerPC oddities



I finally got my Debian system to the point that I can leave it in Debian. 
Hurray!  I've been jotting down anomalies as I run into them.  Here's my
current list:

--At startup, I get:
hwclock is unable to get I/O port access.  I.e. iopl(3) returned nonzero return
code -1.
Am I missing some device, or what?  Maybe hwclock should be a symlink to
/sbin/clock?

--Emacs had nothing bound to the delete-backward-char command.  The delete key
was bound instead to delete-char, which deletes forward.  Very strange, not
very useful.

--rlogin: I had to mkdir /dev/pts, mount -t devpts devpts /dev/pts
For some reason I never had to do this in LinuxPPC, even with the same kernel. 
A newer version of rlogind, I guess?  Seems like creating the right devices--
or at least checking for them--should be part of the netstd install.

--xv: doesn't refresh properly in visual schnauzer, even after an xrefresh.

--no man entry for /sbin/clock

--/usr/bin/fakeroot segfaults in make-equivs

--Several packages have a dependency on xlib6, which doesn't exist and doesn't
seem to be provided by xlib6g.

--There is a netscape-base-4 package, but the various components depend on
netscape-base-407, netscape-base-45, etc., which don't exist.

--The man command is weirdly slow.  Maybe there's some needed piece I haven't
installed yet?--I'm still tiptoeing along, since all my old stuff is still in
place (see below).

--Although Geert's latest accelerated X server is installed and running
(XF68_FBDev-accel-ppc-glibc-2.1-19981210), it doesn't seem to be running
accelerated, even though I'm using the same XF86Config as before, and running
exactly the same kernel.

I wrote a shell script for switching back and forth between the LinuxPPC R4
world and the Debian world, which I thought others might find useful.  It works
by creating a file named OLDDIR in the LinuxPPC directories, a file named
NEWDIR in the Debian directories, and a file named BOTHDIR in directories that
don't need to be swapped around.  There are directories named olddirs and
newdirs for stashing the directories while they're inactive.  Crude, but it
works, and now I can easily boot back and forth between the two systems without
everything breaking.  The script checks for which world it's running in, and
does the right thing for either, so I didn't have to maintain two separate
scripts.  It currently saves away directories in /usr and /usr/local, since my
/usr partition is the same for both systems.  I've included the script at the
end of this message if anyone is interested.

-Randy

#!/bin/bash

# swap between old LinuxPPC /usr subdirs and new Debian /usr subdirs

if ( /bin/grep -q Debian /etc/issue ); then
    echo Configuring directories for Debian
    savedir="old"
    SAVEDIR="OLD"
    usedir="new"
    USEDIR="NEW"
elif ( /bin/grep -q LinuxPPC /etc/issue ); then
    echo Configuring directories for LinuxPPC
    savedir="new"
    SAVEDIR="NEW"
    usedir="old"
    USEDIR="OLD"
else
    echo ***unable to determine OS type
    exit 1
fi

function save_restore_dirs () {

    echo processing $1...

    symlinks=""
    newsubdirs=""
    oldsubdirs=""
    bothsubdirs=""
    unknowns=""

    for file in `ls $1`; do
        if [ -d $1/${file} ]; then
            if [ -L $1/${file} ]; then #leave symlinks and regular files alone
                symlinks="${symlinks} ${file}"
            elif [ -e $1/${file}/NEWDIR ]; then
                newsubdirs="${newsubdirs} ${file}"
            elif [ -e $1/${file}/OLDDIR ]; then
                oldsubdirs="${oldsubdirs} $file"
            elif [ -e $1/${file}/BOTHDIR ]; then
                bothsubdirs="${bothsubdirs} ${file}"
            else
                unknowns="${unknowns} ${file}"
            fi
        fi
    done

    echo old = $oldsubdirs
    echo new = $newsubdirs
    echo both = $bothsubdirs
    echo unknown = $unknowns
    echo symlinks = $symlinks

    if [ "${savedir}" = "new" ]; then
        savesubs=$newsubdirs
        echo save new, use old
    else
        savesubs=$oldsubdirs
        echo save old, use new
    fi

    for dir in ${savesubs}; do
        if [ ! -e $1/${dir}/${SAVEDIR}DIR ]; then
            echo ***no ${SAVEDIR}DIR in $1/${dir}, skipping
            continue
        elif [ -e $1/${savedir}dirs/${dir} ]; then
            echo ***unable to save $1/${dir} because $1/${savedir}dirs/${dir}
already exists
            continue
        fi
        echo -n $1/${dir}...
        mv $1/${dir} $1/${savedir}dirs/
        echo moved to $1/${savedir}dirs
    done

    for dir in `ls $1/${usedir}dirs`; do
        if [ -d $1/${usedir}dirs/$dir ]; then
            if [ ! -e $1/${usedir}dirs/${dir}/${USEDIR}DIR ]; then
                echo ***no ${USEDIR}DIR in $1/${usedir}dirs/${dir}, directory
no
t restored
                continue
            elif [ -e $1/${dir} ]; then
                echo ***unable to restore $1/${dir} from ${usedir}dirs because
f
ile already exists
                continue
            else
                echo -n $dir...
                mv $1/${usedir}dirs/${dir} $1
                echo restored from ${usedir}dirs
            fi
        fi
    done

}

save_restore_dirs /usr
save_restore_dirs /usr/local


Reply to: