0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Risa/Asirのインストール

Last updated at Posted at 2025-04-12

ここでインストールするもの

タイトル見たらわかると思いますが,$\texttt{Risa/Asir}$です.

下準備

いくつかインストールしておかなければならないようなのでしておきます.

$ sudo apt install automake bison libxt-dev libxaw7-dev

ソースのダウンロード

上記のサイトからダウンロードして,解凍します.

# ダウンロード
$ wget https://www.math.kobe-u.ac.jp/pub/OpenXM/head/openxm-head.tar.gz

# 解凍
$ tar -zxvf openxm-head.tar.gz

インストール

makeするときに,色々とファイルをダウンロードしているので,インターネットに接続されている必要があります.

$ cd OpenXM/src
OpenXM/src$ make install

OpenXM/src$ cd ../rc
OpenXM/rc$ make install

インストールに成功していればasirコマンドで起動できるかと思います.

Risa/Asirの起動
$ asir
This is Risa/Asir, full GMP Version 20220328 (Kobe Distribution).
Copyright (C) 1994-2000, all rights reserved, FUJITSU LABORATORIES LIMITED.
Copyright 2000-2021, Risa/Asir committers, http://www.openxm.org/.
GC 7.6.12 copyright 1988-2018, H-J. Boehm, A. J. Demers, Xerox, SGI, HP, I. Maidanski.
Debug windows of ox servers will not be opened. Set Xm_noX=0 to open it.
OpenXM/Risa/Asir-Contrib $Revision: 1.168 $ (20220114), Copyright 2000-2021, OpenXM.org committers
helph(); [html help], ox_help(0); ox_help("keyword"); ox_grep("keyword");
     for help messages (unix version only).
http://www.math.kobe-u.ac.jp/OpenXM/Current/doc/index-doc.html
load : "nn_ndbf.rr" not found in the search path
return to toplevel
[1029]

実行してみる

とりあえずhello worldしてみます.asirコマンドで$\texttt{Risa/Asir}$を起動したら,print("hello, world!")でプリントできます.

$ asir
This is Risa/Asir, full GMP Version 20220328 (Kobe Distribution).
Copyright (C) 1994-2000, all rights reserved, FUJITSU LABORATORIES LIMITED.
Copyright 2000-2021, Risa/Asir committers, http://www.openxm.org/.
GC 7.6.12 copyright 1988-2018, H-J. Boehm, A. J. Demers, Xerox, SGI, HP, I. Maidanski.
Debug windows of ox servers will not be opened. Set Xm_noX=0 to open it.
OpenXM/Risa/Asir-Contrib $Revision: 1.168 $ (20220114), Copyright 2000-2021, OpenXM.org committers
helph(); [html help], ox_help(0); ox_help("keyword"); ox_grep("keyword");
     for help messages (unix version only).
http://www.math.kobe-u.ac.jp/OpenXM/Current/doc/index-doc.html
load : "nn_ndbf.rr" not found in the search path
return to toplevel
[1029] print("hello, world!");
hello, world!
0

正常に動いてるらしい.load関数を使うとソースを読み込むことができるので,hello, worldするだけのソースhello.rrを実行してみます.

因みに,hello.rrの中身は以下の様になっています.

hello.rr
print("hello, world!");

end$
[1030] load("hello.rr");
hello, world!
0

ちゃんとできた.

Colabにおいておいた

Colab上で$\texttt{Risa/Asir}$をインストールできるものを作っておいたので,Ubuntuとかがない人はここでもできます.ただ,インストールには20分強かかりますので,急ぎの人はやめた方が良いです(毎回毎回インストールしなおす必要があるから).

参考にしたもの

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?