せっかくのRaspberry Piが埃をかぶっているので、久しぶりにssh経由でログインして、mrubyをインストールしてみました。
Arch Linuxを使っているので、参考サイトのapt-getではなく、pacmanで依存するパッケージをインストールしていきます。
手順
$ sudo pacman -S git $ sudo pacman -S bison $ sudo pacman -S make $ sudo pacman -S gcc
あとは、参考サイトのように順調にすすめばよかったのですが、mrubyをmakeすると、以下のようなエラーが表示されました。別途、termcapをインストールすることで、無事、mrubyをmakeすることができました。
LD build/host/bin/mirb /usr/bin/ld: cannot find -ltermcap collect2: error: ld returned 1 exit status
termcapのインストール
$ wget http://ftp.gnu.org/gnu/termcap/termcap-1.3.1.tar.gz $ tar zxvf termcap-1.3.1.tar.gz $ cd termcap-1.3.1 $ ./configure $ make $ sudo make install
動作確認
$ mruby -h Usage: mruby [switches] programfile switches: -b load and execute RiteBinary (mrb) file -c check syntax only -e 'command' one line of script -v print version number, then run in verbose mode --verbose run in verbose mode --version print the version --copyright print the copyright