Mercurial > trustbridge
diff packaging/linux-installer.inc.in @ 978:d92b1594e974
Merged.
author | Emanuel Schuetze <emanuel@intevation.de> |
---|---|
date | Fri, 29 Aug 2014 13:10:11 +0200 |
parents | 8be2f510adbf |
children | f5306f8c02f3 |
line wrap: on
line diff
--- a/packaging/linux-installer.inc.in Fri Aug 29 13:09:40 2014 +0200 +++ b/packaging/linux-installer.inc.in Fri Aug 29 13:10:11 2014 +0200 @@ -20,6 +20,7 @@ HELPNAMES_SOURCES="###HELPNAMES_SOURCES###" HELPNAMES_STATIC="###HELPNAMES_STATIC###" HELPNAMES_IMG="###HELPNAMES_IMG###" +ARCH="###ARCH###" declare -A instcfg oldinstcfg declare inst_default_prefix instdata_path instcfg_path instcfg_file @@ -177,6 +178,7 @@ fi instcfg_file="${instcfg_path}/${INSTCFGNAME}" extra_bin_path=`mktemp --tmpdir -d tmpbin.XXXXXXXXXX` + HOST_ARCH=$(uname -m) } cleanup() @@ -501,11 +503,27 @@ ------------------------------------------------------------------------ TrustBridge - Installer - Version ${instcfg[VERSION]} (Testversion) + Version ${instcfg[VERSION]} - ${ARCH} (Testversion) ------------------------------------------------------------------------ EOF +if [ "$ARCH" == "x86_64" -a "$ARCH" != "$HOST_ARCH" ]; then + getxt "It appears your system architecture is %s.\n" "$HOST_ARCH" + getxt "This installer is for 64 bit systems.\n" + getxt "Really install TrustBridge for '%s' systems? [y/n]\n" "${ARCH}" + yorn || exit 0 +fi + +if [ "$ARCH" == "i386" ]; then + if [[ "$HOST_ARCH" != *86 ]]; then + getxt "It appears your system architecture is %s.\n" "$HOST_ARCH" + getxt "This installer is for 32 bit systems.\n" + getxt "Really install TrustBridge for '%s' systems? [y/n]\n" "${ARCH}" + yorn || exit 0 + fi +fi + if [ $DEINSTALL -eq 1 ] ; then deinstall # Stop after deinstallation: