[armedslack] ARMedSlack running on Neo FreeRunner

Stuart Winter m-lists at biscuit.org.uk
Sat Jun 13 13:36:33 UTC 2009


> I'm installing my first ARMedslack version inside Qemu at the moment. Stuart,
> your documentation is excellent! But boy! When you said the installer inside
> Qemu was slow, you wheren't kidding where you? This is 1.6Ghz iron it's
> running on, and I don't mean 1.6 dual Core :-(

Oh - yeah.  I feel for you ;-)
I can barely bring myself to use QEMU now I've got the SheevaPlugs - I
only use it to test that AS still *works* in QEMU ;-)

> back to ~100MB (to allow for a good margin). But that means subtracting from
> the Qemu install, because otherwise I can't compile a kernel inside Qemu.

The thing doesn't have a Network card and you can't mount a temp dir
over NFS?

> We'll see. It all depends I guess on what you want the device to do when
> you're done. Or perhaps I have to bump my nose a couple of times before I see
> what they have seen?

Yes - this is the case, and is why I am only personally interested in
particular ARM devices that have a minimum of 512MB RAM, a fast CPU, and
can use a hard disk - I need build machines where I can build the entire
of Slackware.  I'm really looking forward to these ARM laptops.  That'd be
my dream to have ARMedslack running on one of those and use it as my
day to day laptop!

> The trick will be to keep it small enough but workable. I had a mind to use
> the initrd of ARMedslacks installer, convert this to jffs2 just to Prove the
> Concept and thus gain something bootable. Knowing the initrd of Slackwares
> installer, there is everything you need for testing purposes. Monday.

I can't include the actual build script for the Slackware installer, but
the one attached might be useful.  The installer for the 'kirkwood'
is produced by reprocessing the 'Versatile' installer, and replacing
the Versatile kernel modules with the kirkwood ones, and adding some
additional modules that are required for the Kirkwood.
At the top of the script it sources part of the 'slackkit' package's
package building kit.  For this script, it's really only using
$PKGSTORE, which is a pointer to where your armedslack tree is:
  armedslack-current/slackware

Have fun! :)
-------------- next part --------------
#!/bin/bash

##############################################################
# Script: mk-kirkwood.sh
# Purpose: Take the ARM Versatile Slackware ARM installer and
#          produce a new installer for the Marvell Kirkwood
#          devices.
# Author : Stuart Witner <mozes at slackware.com>
# Date   : 15-May-2009
###############################################################

# Load in the ARMedslack build kit from the 'slackkit' package.
source /usr/share/slackdev/buildkit.sh

# For any -rc releases, remove the hyphen.
KERNELVER="$( ls -1 $PKGSTORE/a/kernel_kirkwood*.t?z | head -1 | rev | cut -d- -f3 | rev | cut -d_ -f1 )"
SLKARCH=kirkwood

cd /tmp
rm -rf kirkwood-installer
mkdir -vpm755 kirkwood-installer/{unpack,tree}
cd kirkwood-installer
LIST=/tmp/kirkwood-installer/i-mod-list

# Unpack the Versatile installer.
# The installers for all ARM architectures are identical - the
# only thing we need to change per architecture is the Kernel modules.
# The default architecture for ARMedslack is the 'Versatile' because 
# it's the most accessible, being supported by QEMU.
#
pushd tree
  zcat $PKGSTORE/../isolinux/initrd-versatile.img | cpio -div
  cd lib/modules/
  ( cd *versatile*
    #find . -type f  | sed 's?.gz??' > $LIST
   # Generate the list of Kernel modules which are included in the installer:
    find . -type f > $LIST )
   # Delete the ARM Versatile kernel modules; we'll be replacing these
   # with the Kirkwood's.
  rm -rf *versatile*
  EXTPOS=$PWD 
popd

# Add a few additional modules required for the Kirkwood series.
# These can include specific hardware drivers, or additional
# USB/SCSI drivers which aren't needed by the ARM Versatile
# board.
#
#
cat << EOF >> $LIST
./kernel/drivers/mmc/
./kernel/drivers/net/mv643xx_eth.ko.gz
./kernel/drivers/usb/storage/usb-libusual.ko.gz
./kernel/drivers/scsi/scsi_tgt.ko.gz
./kernel/drivers/scsi/scsi_mod.ko.gz
./kernel/drivers/scsi/sg.ko.gz
./kernel/lib/crc-t10dif.ko.gz
./kernel/drivers/usb/core/usbcore.ko.gz
./kernel/drivers/usb/storage/usb-storage.ko.gz
./kernel/drivers/usb/storage/ums-cypress.ko.gz
./kernel/drivers/usb/host/ehci-hcd.ko.gz
EOF

pushd unpack
  # Unpack the kirkwood Kernel modules into a temporary
  # space:
  tar --wildcards -xvvf $PKGSTORE/a/kernel-modules-${SLKARCH}-${KERNELVER}_${SLKARCH}-*.tgz -C. lib/modules/* || exit 1
  cd lib/modules/
  # Work out what the name of the Kernel is (this may not match the
  # Kernel version number in this script, although it should!)
  KERNELNAME="$( ls -1d * )"
  cd $KERNELNAME
  # Create the /lib/modules/2.6.x-kirkwood directory:
  mkdir -vpm755 $EXTPOS/$KERNELNAME
  # Copy the same Kernel modules as the Versatile does -- including those
  # additional ones in the list above -- into the Kirkwood installer:
  tar pvvcf - -T $LIST | tar -C $EXTPOS/$KERNELNAME/ -pxf -
popd

cd tree

# Re-generate module dependencies list:
find ./lib/modules -type d -mindepth 1 -maxdepth 1 -printf "%f\n" | xargs -i depmod {} -b.

#read -p "Make the mods now then hit ENTER"

# Create U-Boot image & put it into the
# Slackware ARM tree ready for distribution:
find . | cpio -o -H newc | gzip -9fv > ../Slackware_Installer_$SLKARCH.gz
mkimage \
  -A arm \
  -O linux \
  -T ramdisk \
  -C gzip \
  -n 'Slackware ARM Installer' \
  -d ../Slackware_Installer_$SLKARCH.gz \
  $PKGSTORE/../isolinux/uinitrd-$SLKARCH.img
#  /tmp/uinitrd-${SLKARCH}.img


More information about the ARMedslack mailing list