User Tools

Site Tools


linux:installscratch

This is an old revision of the document!


Installing Scratch on SuSE 13

These instructions are about installing the Scratch programming language in OpenSuSe 13.1 (bottle).

First step: install squeak

The first thing we need is squeak, the smalltalk virtual machine. I've tried to install it by downloading it from its website, but it doesn't have all the necessary modules, specially the sound modules. Try this link or try to search “squeak” in the Opensuse repository.

Second step: install scratch

I've tried to install the rpm package that comes in the scratch website, but it failed in my case. The thing is that I've probably tried this with the wrong version of the squeak virtual machine (see up), but at the end I not sure.

Instead of this, I've downloaded the deb package from the MIT site and afterwards I dissasembled it:

 ar -xvf ../scratch_1.4.0.6~dfsg1-2~ubuntu12.04.1_all.deb 

you will get three files:

  • debian-binary
  • control.tar.gz
  • data.tar.gz

Uncompress the later two:

tar -xzf control.tar.gz
tar -xzf data.tar.gz

The first one contains scripts of unstalling and postinstall, among other things. The data.tar.gz contains the scratch program.

As root user, I did the following:

# cp  bin/scratch /usr/local/bin/
# cp share/* /usr/local/share -R

After that, you are almost ready to run scratch in SuSE 13.

Third step: fix start script

The last step is to fix the start script, /usr/local/bin/scratch, I made the following changes (better to save a copy of the original):

#!/bin/sh
# File:            scratch
# Description:     Script to start the Squeak VM binary with the scratch image
# Original Author: Bert Freudenberg
# Adapted by:      Miriam Ruiz, Raul Luna
 
VM_VERSION=4.10.2-2614
SQ_DIR=/usr/lib/squeak/$VM_VERSION
VM="$SQ_DIR/squeakvm"
VMOPTIONS="-encoding UTF-8 -vm-display-x11 -xshm -plugins /usr/lib/squeak/$VM_V
IMAGE="/usr/local/share/scratch/Scratch.image"
IMOPTIONS=""
DOCUMENT=""
WRAPPER=""

And this is it. If you want, you can do more fixings like creating a fancy starting icon, etc. But the hard stuff is already done.

linux/installscratch.1393279386.txt.gz · Last modified: 2022/12/02 22:02 (external edit)