GaucheでWebサーバ 2 (gauche-makiki をインストールしてみる)

コメント欄で Gauche Makiki を教えてもらったので動かしてみました。


まず Gaucheのインストールから。
make を使うのと Gaushe の付随する(?)パッケージも全部インストールします。

apt-get install -y make git gauche*


次に makiki をClone して make、インストールします

git clone https://github.com/shirok/Gauche-makiki.git
cd Gauche-makiki

./configure
make install


ここまでできるとサンプルが動くようになります

# gosh ./examples/minimal.scm &


curl -vvv http://localhost:6789
* Rebuilt URL to: http://localhost:6789/
* Hostname was NOT found in DNS cache
*   Trying ::1...
* Connected to localhost (::1) port 6789 (#0)
> GET / HTTP/1.1
> User-Agent: curl/7.38.0
> Host: localhost:6789
> Accept: */*
> 
< HTTP/1.1 200 OK
* Server gauche/makiki is not blacklisted
< Server: gauche/makiki
< Content-Type: text/html; charset=utf-8
< Content-Length: 19
< 
* Connection #0 to host localhost left intact
<h1>It worked!</h1>


簡単!