# -*- filetype: bash -*-
#
# Copyright (c) Paul R. Tagliamonte <tag@pault.ag>
# OK. Right. So. This is really fucking gross. If you want to disable it,
# fip the switch below to `true`.

GLOBAL_DISABLE_LIBOLLA="false"


if [ "x${DISABLE_LIBOLLA}" != "x" ]; then
    DISABLE_LIBOLLA=GLOBAL_DISABLE_LIBOLLA
fi

if [ "x${DISABLE_LIBOLLA}" == "xtrue" ]; then
    exit 0
fi

if [ "x${LD_PRELOAD}" = "x" ]; then
    export LD_PRELOAD="/usr/lib/olla/libolla.so"
else
    export LD_PRELOAD="${LD_PRELOAD} /usr/lib/olla/libolla.so"
fi
