5.2 バグ修正を含むソースコードへの置き換えとビルド、オレオレパッケージの作成
次にバグのあるソースコードを新しいソースコードに置き換え、ビルドができるかどうか試してみます。新しいソース
コードは http://code.google.com/p/tcode/から取得します。
kozo2@debian:~/sandbox/t-code-2.3.1$ cd ..
kozo2@debian:~/sandbox$ svn co http://tcode.googlecode.com/svn/trunk/ tcode-read-only
置き換えが必要なファイルを新しいソースコードをコピーすることで上書きします。
kozo2@debian:~/sandbox$ cp tcode-read-only/tc/bushu-util/* t-code-2.3.1/bushu-util/
kozo2@debian:~/sandbox$ cp tcode-read-only/tc/etc/* t-code-2.3.1/etc/
kozo2@debian:~/sandbox$ cp tcode-read-only/tc/lisp/* t-code-2.3.1/lisp/
kozo2@debian:~/sandbox$ cp tcode-read-only/tc/mazegaki/* t-code-2.3.1/mazegaki/
これでビルドが通るか試します。 (通ります)
kozo2@debian:~/sandbox$ cd t-code-2.3.1
kozo2@debian:~/sandbox$ debuild -us -uc
とりあえず、置き換えたソースコードでパッケージができました。次はこれをインストールし動作確認してみます。
5.3 オレオレパッケージの動作確認
先程作成した用いるソースコードに変更を加えた Debian パッケージをインストールし、動作に問題がないか確認しま
す。インストールするには dpkg コマンドに-i オプションをつけてインストールしたい.deb ファイルを指定します。
kozo2@debian:~/sandbox$ sudo dpkg -i t-code_2.3.1-3_all.deb
Selecting previously unselected package t-code.
(Reading database ... 97587 files and directories currently installed.)
Unpacking t-code (from t-code_2.3.1-3_all.deb) ...
Setting up t-code (2:2.3.1-3) ...
install/t-code: Handling install for emacsen flavor emacs23
Processing triggers for install-info ...
kozo2@debian:~/sandbox$
インストールは問題ないようです。それでは t-code が問題ないか emacs を起動し試してみます。試しに t-code 練習プ
ログラム eelll の起動を試みると emacs が下記のメッセージを出し、何か問題があることがわかります。
Debugger entered--Lisp error: (error ‘‘ファイル /usr/share/tc/EELLLTXT が存在しません。’’)
signal(error (‘‘ファイル /usr/share/tc/EELLLTXT が存在しません。’’))
error(‘‘ファイル %s が存在しません。’’ ‘‘/usr/share/tc/EELLLTXT’’)
tcode-set-work-buffer(‘‘ *eelll: text*’’ ‘‘EELLLTXT’’)
eelll-completing-read()
call-interactively(eelll t nil)
execute-extended-command(nil)
call-interactively(execute-extended-command nil nil)
5.4 Debian ディレクトリ下のファイルの変更
先程の問題は t-code が用いる交ぜ書き、部首合成変換用データがインストールされているディレクトリを指定する
emacs の変数 tcode-site-data-directory の設定によるものです。この tcode-site-data-directory を指定し直すにはパッ
ケージ作成用 directory 下の debian/emacsen-startup に下記の設定を追加しビルドし直します。
14