Failed to build rabbitmq-server on macos

179 views
Skip to first unread message

Chang Runqing

unread,
Dec 26, 2019, 7:32:19 AM12/26/19
to rabbitmq-users

Recently I try to build a rabbitmq-server by instruction that described in https://www.rabbitmq.com/build-server.html
but i failed.

Environment

  • Macos version: 10.14.6
  • Source code: tags/v3.8.2
  • Python version: 2.7.17
    • simplejson version: 3.17.0
  • Erlang version: 22.2.1
  • GNU make version: 4.2.1

Steps to reproduce

cd rabbitmq-server
make -j1 V=1

Error description

GNU make reports a error while building depends packages.
first error message say:

env: escript\r: No such file or directory
/Users/changrunqing/Projects/rabbitmq-server
{“init terminating in doboot”,{undef,[{rmemo,start,[],[]},{erl_eval,do_apply,6,[{file,”erl_eval.erl”},{line,680}]},{erl_eval,exprs,5,[{file,”erl_eval.erl”},{line,126}]},{init,start_it,1,[]},{init,start_em,1,[]},{init,do_boot,3,[]}]}}^M
init terminating in do_boot ({undef,[{rmemo,start,[],[]},{erl_eval,do_apply,6,[{
},{}]},{erl_eval,exprs,5,[{},{_}]},{init,start_it,1,[]},{init,start_em,1,[]},{init,do_boot,3,[]}]})^M
^M
Crash dump is being written to: erl_crash.dump…done^M

Two things are strange:

  1. there’s a \r in the end of the first error line, it seems that some script use CRLF as line ending, so script can not run, and i have tested that escript can work correctly.
  2. the rest of the error message is ending with CRLF(^M).

Attachment

any suggestions are welcome.

Luke Bakken

unread,
Dec 26, 2019, 12:20:16 PM12/26/19
to rabbitmq-users
Hello,

We do not recommend that users build RabbitMQ from source code. Please use one of the official packages. On OS X, I usually use the generic-unix package for testing:


The output you have provided shows what the problem is:

env: escript\r: No such file or directory

You either don't have Erlang installed or it is not installed correctly, since the escript program should be in your PATH. I have no idea why you are seeing those line endings. I have never seen it on OS X.

Thanks,
Luke

Chang Runqing

unread,
Dec 26, 2019, 10:12:05 PM12/26/19
to rabbitmq-users

Thanks for your reply, the reason that i build from source is i need modify some code.
And I tested that Erlang was Installed correctly.

which escript
> /usr/local/bin/escript
which erl
> /usr/local/bin/erl

Michael Klishin

unread,
Dec 26, 2019, 11:31:00 PM12/26/19
to rabbitmq-users
It's one of the dependencies that fails to build as far as I can tell, specifically
when erlang.mk tries to patch a rebar-managed project. That's the only reference of "rmemo" that I could find [1].

the "escript\r" part makes me wonder if there's a bogus newline character of sorts.

You can try a Debian VM or container to compare. I'm on macOS Catalina but cannot reproduce.


--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-user...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/rabbitmq-users/07bd5eb2-6088-4d5f-b66c-39d1d40e90bc%40googlegroups.com.


--
MK

Staff Software Engineer, Pivotal/RabbitMQ

Chang Runqing

unread,
Dec 27, 2019, 2:40:55 AM12/27/19
to rabbitmq-users
Thanks a lot!. i found the reason. as your suggestion, i try to build deps one by one.
i found even the first rabbitmq-common failed to build, with same error msg. so i try to find is there have some files with CRLF ending,
and i found all script with CRLF ending, i think back i did a config on git, set autocrlf = true(reason was complex), so i turn it to false.
build sucess!
thanks again for everyone's help.


在 2019年12月27日星期五 UTC+8下午12:31:00,Michael Klishin写道:
It's one of the dependencies that fails to build as far as I can tell, specifically
when erlang.mk tries to patch a rebar-managed project. That's the only reference of "rmemo" that I could find [1].

the "escript\r" part makes me wonder if there's a bogus newline character of sorts.

You can try a Debian VM or container to compare. I'm on macOS Catalina but cannot reproduce.


On Fri, Dec 27, 2019 at 6:12 AM Chang Runqing <changr...@gmail.com> wrote:

Thanks for your reply, the reason that i build from source is i need modify some code.
And I tested that Erlang was Installed correctly.

which escript
> /usr/local/bin/escript
which erl
> /usr/local/bin/erl

--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitm...@googlegroups.com.

Michael Klishin

unread,
Dec 27, 2019, 5:35:27 AM12/27/19
to rabbitmq-users
Oh, it's certainly good to know that local git configuration can affect build stability.

Thank you for reporting back to the list!

To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-user...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/rabbitmq-users/7f7c7d62-0bb6-444c-b6c6-2f8f865b054a%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages