Tkをmakeする前にTclをあらかじめmakeしておきます。
unixディレクトリの下で以下のスクリプトを実行します。
setup.sh
#!/bin/sh
if [ $# -eq 1 ]; then
. ../../setup-pre.sh $1
else
. ../../setup-pre.sh
fi
CPPFLAGS="-I/usr/local/include"; export CPPFLAGS
LDFLAGS="-L/usr/local/lib$LIBISA -R/usr/local/lib$LIBISA"; export LDFLAGS
if [ "$ISA" = "sparcv9" -o "$ISA" = "amd64" ]; then
E64BIT="--enable-64bit"
else
E64BIT=
fi
if [ "$ISA" = "sparcv9" -o "$ISA" = "sparcv8plus" ]; then
E64BITVIS="--enable-64bit-vis"
else
E64BITVIS=
fi
case `uname -r` in
"5.10"|"5.11")
DTRACE="--enable-dtrace"
;;
*)
DTRACE=
;;
esac
./configure $CONFDIRS ${DTRACE} ${E64BIT} ${E64BITVIS} \
--enable-threads \
--enable-shared
dtraceが64bitを使えるようにできあがったMakefileを修正します。
% vi Makefile + DTRACE_SWITCHES=-64
setup.sh
#!/bin/sh
if [ $# -eq 1 ]; then
. ../../setup-pre.sh $1
else
. ../../setup-pre.sh
fi
CPPFLAGS="-I/usr/local/include"; export CPPFLAGS
LDFLAGS="-L/usr/local/lib$LIBISA -R/usr/local/lib$LIBISA"; export LDFLAGS
if [ "$ISA" = "sparcv9" -o "$ISA" = "amd64" ]; then
E64BIT="--enable-64bit"
else
E64BIT=
fi
if [ "$ISA" = "sparcv9" -o "$ISA" = "sparcv8plus" ]; then
E64BITVIS="--enable-64bit-vis"
else
E64BITVIS=
fi
./configure $CONFDIRS \
--enable-threads \
--enable-shared \
--with-x ${E64BIT} ${E64BITVIS}
setup.shを実行してmakeします。
% ./setup.sh [sparcv9|sparcv8plus|amd64|i386] % gmake # gmake install