Attempt to make MariaDB work if moved (to cvmfs) after compilation by using built-in flags and env vars.