Tutorials/Programs and editors/Tectonicus/VPS

This tutorial should only be used on a VPS/headless machine.

Note: If your headless server has a graphics adapter only install libgl1-mesa-swx11 if you are experiencing any problems.

Note: I am using the sun-java6-jdk but it should also work with the openjdk.

Ubuntu 10.04
I have got Tectonicus running this way on a EC2 Ubuntu 10.04 Lucid machine.


 * sudo apt-get install xvfb libgl1-mesa-swx11 libxcursor1 libxrandr2 libxxf86vm1 (your minimal xserver stack)
 * For testing purpose install mesa-utils and try xvfb-run glxinfo and xvfb-run glxgears
 * Also test xvfb-run -a xrandr. If you get an RANDR Extension not (installed/configured ?) error take a look at the Debian setup.

You now have all needed dependencies installed further Informations see Tectonicus/VPS

Debian (e.g. all apt based distributions, also Ubuntu before 10.04)
I have got Tectonicus running this way on a EC2 Debian 5.0 Lenny machine.

To get tectonicus running you will need to recompile xvfb (yeah it's really sad, it is a one-line bug).


 * sudo apt-get build-dep xvfb
 * You will now have to add a deb-src repository to you /etc/apt/sources.list
 * sudo apt-get source xvfb
 * you will know get a directory called xorg-server-X.X.X we now need to patch the source.
 * wget https://bugs.launchpad.net/xorg-server/+bug/516123/+attachment/1126330/+files/xvfb-fbScreenInit-handling.patch
 * wget https://bugs.launchpad.net/xorg-server/+bug/516123/+attachment/1126331/+files/xvfb-randr.patch
 * You have to apply this patches in the right order
 * patch -p1 xorg-server-X.X.X/hw/vfb/InitOutput.c  xvfb-fbScreenInit-handling.patch
 * patch -p1 xorg-server-X.X.X/hw/vfb/InitOutput.c  xvfb-randr.patch
 * sudo apt-get install fakeroot
 * cd xorg-server-X.X.X
 * The next step will probably take hours.
 * dpkg-buildpackage -rfakeroot -uc -b
 * cd ..
 * dpkg -i xvfb_*.deb
 * sudo apt-get install libgl1-mesa-swx11 libxcursor1 libxrandr2 libxxf86vm1 x11-xserver-utils
 * Now try xvfb-run -a xrandr. If everything worked how its supposed to work you should get no errors.
 * For testing purpose install mesa-utils and try xvfb-run glxinfo and xvfb-run glxgears

You now have all needed dependencies installed further Informations see Tectonicus/VPS

Note: If anyone knows an easier way to patch xvfb or could provide debs I would be grateful.

OpenSuse
Coming soon

Archlinux
From Extra/Core repo:

sudo pacman -Sy xorg-server-xvfb xorg-server-utils xorg-server libxcursor libgl mesa libxrandr xorg-xrandr libxxf86vm

That is as far as I got. if anyone can track down the dependencies for arch we could get this together.

Coming soon

RHEL/CentOS 5 (and likely other RPM based distributions)

 * 1) sudo yum install xorg-x11-server-Xvfb xorg-x11-server-utils glx-utils
 * copy the xvfb-run script below to /usr/local/bin
 * For testing purpose try to run:
 * 1) xvfb-run glxinfo
 * 2) xvf-run glxgears
 * 3) xvfb-run -a xrandr

You now have all needed dependencies installed further Informations see Tectonicus/VPS

xvfb-run script

 * For those who can't get this script via their distribution, here it is:

# # # # set -e # PROGNAME=xvfb-run SERVERNUM=99 AUTHFILE=$(pwd)/.Xauthority ERRORFILE=/dev/null STARTWAIT=3 XVFBARGS="-screen 0 640x480x8" LISTENTCP="-nolisten tcp" XAUTHPROTO=. # usage { cat << EOF Usage: $PROGNAME [OPTION ...] COMMAND # run COMMAND (usually an X client) in a virtual X server environment # Options: -a       --auto-servernum   try to get a free server number, starting at                                --server-num -e FILE  --error-file=FILE  file used to store xauth errors and Xvfb output (defualt: $ERRORFILE) -f FILE  --auth-file=FILE   file used to store auth cookie (default: ./.Xauthority) -h       --help             display this usage message and exit -n NUM   --server-num=NUM   server number to use (default: $SERVERNUM) -l       --listen-tcp       enable TCP port listening in the X server -p PROTO --xauth-protocol=PROTO   X authority protocol name to use (defaults to xauth's default) -s ARGS  --server-args=ARGS  arguments (other than server number and -nolisten                                 tcp) to pass to the Xvfb server (default: \"$XVFBARGS\") -w DELAY --wait=DELAY       delay in seconds to wait for Xvfb to start (default: $STARTWAIT) EOF :; } # find_free_servernum { # ldv: FIXME: race condition. i=$SERVERNUM while [ -f /tmp/.X$i-lock ]; do        i=$(($i + 1)) done echo $i; } # ARGS=$(getopt --options +ae:f:hn:lp:s:w: \       --long auto-servernum,error-file:auth-file:,help,server-num:,listen-tcp,xauth-protocol:,server-args:,wait: \        --name "$PROGNAME" -- "$@") # if [ $? -ne 0 ]; then echo "$PROGNAME: error while getting options" >&2 exit 1 fi # eval set -- "$ARGS" # while :; do    case "$1" in         -a|--auto-servernum) SERVERNUM=$(find_free_servernum) ;;         -e|--error-file) ERRORFILE="$2"; shift ;; -f|--auth-file) AUTHFILE="$2"; shift ;;        -h|--help) SHOWHELP="yes" ;; -n|--server-num) SERVERNUM="$2"; shift ;;        -l|--listen-tcp) LISTENTCP="" ;; -p|--xauth-protocol) XAUTHPROTO="$2"; shift ;;        -s|--server-args) XVFBARGS="$2"; shift ;; -w|--wait) STARTWAIT="$2"; shift ;;        --) shift; break ;; *) echo "$PROGNAME: error while parsing option \"$1\"" >&2; USAGE=$(usage); echo "$USAGE" >&2; exit 1 ;;    esac     shift done # if [ "$SHOWHELP" ]; then     usage     exit 0 fi # if [ -z "$*" ]; then     echo "$PROGNAME: need a command to run" >&2     exit 2 fi # if ! which xauth > /dev/null; then     echo "$PROGNAME: xauth command not found; exiting." >&2     exit 3 fi # rm -f $AUTHFILE MCOOKIE=$(mcookie) XAUTHORITY=$AUTHFILE xauth add :$SERVERNUM $XAUTHPROTO $MCOOKIE > $ERRORFILE 2>&1 XAUTHORITY=$AUTHFILE Xvfb :$SERVERNUM $XVFBARGS $LISTENTCP > $ERRORFILE 2>&1 & XVFBPID=$! sleep $STARTWAIT # set +e DISPLAY=:$SERVERNUM XAUTHORITY=$AUTHFILE $@ 2>&1 RETVAL=$? set -e # kill $XVFBPID # XAUTHORITY=$AUTHFILE xauth remove :$SERVERNUM > $ERRORFILE 2>&1 rm $AUTHFILE # exit $RETVAL #
 * 1) !/bin/sh
 * 1) xvfb-run - run the specified command in a virtual X server
 * 1) This script starts an instance of Xvfb, the "fake" X server, runs a
 * 2) command with that server available, and kills the X server when
 * 3) done.  The return value of the command becomes the return value of
 * 4) this script.
 * 1) If anyone is using this to build a Debian package, make sure the
 * 2) package Build-Depends on xvfb, xbase-clients, and xfonts-base.
 * 1) display a usage message
 * 1) find free server number by looking at .X*-lock files in /tmp
 * 1) parse command line
 * 1) start Xvfb
 * 1) start the command and save its exit status
 * 1) kill Xvfb now that the command has exited
 * 1) clean up
 * 1) return the executed command's exit status
 * 1) vim:set ai et sts=4 sw=4 tw=0:

Tectonicus Setup
You will need a minecraft.jar (Not the one you can download from minecraft.net). Start up the game and the auto-updater will download it to '.minecraft/bin', usually somewhere in your home directory.

Please replace all /path/to/ to the correct path.

If you are gettin a biome related error use this flag for tectonicus useBiomeColours=false and of course you can use all other flags for tectonicus Tectonicus


 * 64bit
 * 32bit

Feedback
Please give me your feedback in the minecraft forum or via e-mail wallnuss13 [at] gmail [dot] com.