diff options
| author | Jean-Sébastien Pédron <jean-sebastien@rabbitmq.com> | 2015-08-31 11:26:39 +0200 |
|---|---|---|
| committer | Jean-Sébastien Pédron <jean-sebastien.pedron@dumbbell.fr> | 2015-10-20 11:10:48 +0200 |
| commit | b28fbfce63963edc060927f641cbb00f9944fc50 (patch) | |
| tree | 233461d3120e9322a711292cca8a6f319314ed6a /scripts | |
| parent | d68b63fafcd35f5d180541c1b8bb0fa534e7bc1b (diff) | |
| download | rabbitmq-server-git-b28fbfce63963edc060927f641cbb00f9944fc50.tar.gz | |
Define ERL_LIBS when RabbitMQ runs from its source directory
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/rabbitmq-env | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/scripts/rabbitmq-env b/scripts/rabbitmq-env index 3eef90e141..7450450953 100755 --- a/scripts/rabbitmq-env +++ b/scripts/rabbitmq-env @@ -235,6 +235,19 @@ rmq_check_if_shared_with_mnesia \ ##--- End of overridden <var_name> variables +## Development-specific environment. +if [ -f "${RABBITMQ_HOME}/erlang.mk" ]; then + # When RabbitMQ or the rabbitmq* scripts are started from the source + # directory, they need the location of rabbit_common. + if [ -d "${RABBITMQ_HOME}/dist" ]; then + ERL_LIBS="${RABBITMQ_HOME}/dist:${ERL_LIBS}" + fi + if [ "${DEPS_DIR}" -a -d "$(dirname "${DEPS_DIR}")" ]; then + ERL_LIBS="$(dirname ${DEPS_DIR})/dist:${ERL_LIBS}" + fi + ERL_LIBS=${ERL_LIBS%:} +fi + RABBITMQ_ENV_LOADED=1 # Since we source this elsewhere, don't accidentally stop execution |
