Home > codefest2008 > HowToInstallGauche
More actions

HowToInstallGauche

Tags:  


How to Install Gauche

Intro. Gauche

  • 日本自创的 Scheme 方言(Lisp 的方言;-)
  • GDHP 实现中使用的语言

Gauche Installation on Ubuntu (ant its variants)

  • Install Gauche, it's package name is "gauche"
    • Synaptic ~ 新立得;)

Play Hanio in Gauche TTY toy

  • so u can fell Hanio game in CLI by toh.scm ; 现在就直接可以使用 toh.scm 在命令行中尝试了
  • $ gosh toh.scm --help
    Usage:
      Server:       toh.scm -s [-1] [port#]
      Client:       toh.scm -c n host:port host:port
      Interactive:  toh.scm -i [port#]
  • so play way is:
  • start tow Hanio server:
    • $ gosh toh.scm -s 9001
    • $ gosh toh.scm -s 9002
  • start Hanio client to start moving disk in TTY(terminal)
    • $ gosh toh.scm -c 7 localhost:9001 localhost:9002
      ACK 127.0.0.1:40246 127.0.0.1:36761
      Tower0: 6543210
      Tower0: 654321
      Tower0: 65432
      Tower0: 6543
      Tower0: 65430
      Tower0: 6543
      Tower0: 654
      Tower0: 6541
      Tower0: 65410
      Tower0: 6541
      Tower0: 654
      Tower0: 65
      Tower0: 650
      ...
  • the fun is base GDHP we can mix GUI&CLI to play Hanio ;-)
  • $ gosh gtk-toh.scm --help
    Usage:
      Server:       gtk-toh.scm -s [port#]
      Client:       gtk-toh.scm -c n host1:port1 host2:port2
      Both: gtk-toh.scm [port#]
  • hold them TTY Hanio server
  • $ gosh gtk-toh.scm -c 10 localhost:9001 localhost:9002
  • so us gtk-toh.scm will play 10 disks Hanio with them TTY server in localhost:9001/9002
  • 2008-03-09-131127_536x602_scrot.png

Gauche-gkt Installation on Ubuntu (ant its variants)

  • Install Gauche, it's package name is "gauche"
    • Synaptic ~ 新立得;)
  • Unfortunately, gauche-gtk cannot be installed because it's not good state in Ubuntu
  • You need to build gauche-gtk
  • Please get the source code from Debian archive (say, debian.cn99.com)
    • /debian/main/g/gauche-gtk/gauche-gtk_0.4.1-8.{dsc,diff.gz} and orig.tar.gz
  • Invoke command, "dpkg-source"
    • You might need to install "dpgk-dev" and "fakeroot"
    • You need to edit the file debian/control
      • gauche-dev (>= 0.8.8) (was >= 0.8.12)
  • Invoke command, "dpkg-buildpackage -us -uc -rfakeroot" under the directory "gauche-gtk-0.4.1"
    • You might get error on dependency
    • You might need to install "libgtk"-something and other software
    • After installing software needed, please invoke "dpkg-buildpackage" again
  • You should have "gauche-gtk_0.4.1-8_i386.deb"
  • Install "gauche-gtk_0.4.1-8_i386.deb"
    • $ sudo dpkg -i gauche-gtk_0.4.1-8_i386.deb
运行命令
$gosh gtk-toh.scm
  • 多线程towers-of-hanoi GUI展示软件  gtk-toh.scm 运行情景(Ubuntu7.10):
  • 2008-03-09-095918_916x597_scrot.png

0 Comments  Show recent to old
Post a comment



 RSS of this page

Written by:   Version:   Last Edited By:   Modified