#!/bin/sh set -o errexit # Reading system configuration informations, functions and package versions. source ../sysinfos source ../functions source ../packages-list # Applying patches (if any) apply_patches ${1} cd ${LFS_TMP}/${1} export VERSION=$(echo ${1} | sed "s!tk\(.*\)!\1!g") export V=`echo $VERSION | cut -d "." -f 1,2` export DIR=$PWD cd unix sed -i "s/relid'/relid/" configure ./configure \ --prefix=/usr \ --enable-threads make sed -i -e "s:${DIR}/unix:/usr/lib:" \ -e "s:${DIR}:/usr/include/tk${V}:" tkConfig.sh make install install -d /usr/include/tk${V}/unix install -m644 *.h /usr/include/tk${V}/unix/ install -d /usr/include/tk${V}/generic install -m644 ../generic/*.h /usr/include/tk${V}/generic/ rm -f /usr/include/tk${V}/generic/{tk,tkDecls,tkPlatDecls}.h ln -nsf ../../include/tk${V} /usr/lib/tk${V}/include ln -sf libtk${V}.so /usr/lib/libtk.so ln -sf wish${V} /usr/bin/wish ldconfig exit $?