#!/bin/sh

RPMBUILD=`which rpmbuild  2>/dev/null`
if [ "x$RPMBUILD" = "x" ]; then
    RPMBUILD=`which rpm 2>/dev/null`;
fi
echo $RPMBUILD
export RPMBUILD

if [ x"$TOPDIR" = "x" ]; then
    TOPDIR=`rpm --eval '%_topdir'`;
fi

if [ "x$PKG_SOURCE_DIR" = "x" ]; then
    PKG_SOURCE_DIR=`rpm --eval '%_sourcedir'`;
fi
echo $TOPDIR
echo $PKG_SOURCE_DIR

export TOPDIR
export PKG_SOURCE_DIR

echo export LANG=C
echo export LC_ALL=C
echo export SED=sed
echo export RUNSOCKS=runsocks
export LANG=C
export LC_ALL=C
export SED=sed
export RUNSOCKS=runsocks

make copy_patches
make im-sdk
make xcin
make zhCN
make zhTW
make zhHK
make koKR
make thTH
make clear_specfiles
