a555f2
#! /bin/sh
a555f2
#
a555f2
# Wrapper script for mysql_config to support multilib
a555f2
#
a555f2
# This command respects setarch
a555f2
a555f2
bits=$(rpm --eval %__isa_bits)
a555f2
a555f2
case $bits in
a555f2
    32|64) status=known ;;
a555f2
        *) status=unknown ;;
a555f2
esac
a555f2
a555f2
if [ "$status" = "unknown" ] ; then
a555f2
    echo "$0: error: command 'rpm --eval %__isa_bits' returned unknown value: $bits"
a555f2
    exit 1
a555f2
fi
a555f2
a555f2
a555f2
if [ -x @bindir@/mysql_config-$bits ] ; then
a555f2
    @bindir@/mysql_config-$bits "$@"
a555f2
else
a555f2
    echo "$0: error: needed binary: @bindir@/mysql_config-$bits is missing"
a555f2
    exit 1
a555f2
fi
a555f2