アプリケーションパッケージ開発者ガイド

request スクリプト

trap 'exit 3' 15
# determine if and where general executables should be placed
ans=`ckyorn -d y \
-p "Should executables included in this package be installed"
` || exit $?
if [ "$ans" = y ]
then
   CLASSES="$CLASSES bin"
   NCMPBIN=`ckpath -d /usr/ncmp/bin -aoy \
   -p "Where should executables be installed"
   ` || exit $?
fi
# determine if emacs editor should be installed, and if it should
# where should the associated macros be placed
ans=`ckyorn -d y \
-p "Should emacs editor included in this package be installed"
` || exit $?
if [ "$ans" = y ]
then
   CLASSES="$CLASSES emacs"
   EMACS=`ckpath -d /usr/ncmp/lib/emacs -aoy \
   -p "Where should emacs macros be installed"
   ` || exit $?
fi

request スクリプトは、ファイルシステム上にファイルを残さずに終了できます。Solaris バージョン 2.5 よりも前のバージョンおよび互換バージョンでインストールを行う場合、checkinstall スクリプトが使用されていない可能性があるので、request スクリプトを使用してファイルシステムのテストを行い、インストールの成功を確認することをお勧めします。request スクリプトがコード 1 で終了すると、インストールはクリーンに終了します。

これらのファイル例では、パラメータ型パスを使用して複数のベースディレクトリを確立する方法が示されています。しかし、pkgadd コマンドによって管理および検証される BASEDIR パラメータを使用する必要が生じる場合もあります。複数のベースディレクトリを使用する際には、同じプラットフォームに複数のバージョンやアーキテクチャーをインストールする場合に備えて、特別な注意を払う必要があります。