问题描述
我是Erlang的新人,我一直试图在EC2 ubuntu机器上安装Erlang和ejabberd,一切顺利,直到我开始在ejabberd中编译一些外部模块。它开始抛出错误undefined parse transformlager_transform'。我尝试了一切如下所示:- 使用螺纹钢筋,做好清洁,制造,安装。之后,我可以看到lager_transform.beam是在// lib /文件夹中创建和存在的。
- 检查了rebar.config文件,它有大量的顶部,这是广泛的建议,甚至没有帮助。
- 在模块顶部添加了
-compile [{parse_tranform},{lager_transform}]
,即使他们没有运气。
我真的被阻止了,无法完成安装。我已经在Fedora上用ejabberd 15.11和otp 18.2这样做了,当时它使用 p1_logger
而不是Lager。但现在当我安装新的otp 18.2和ejabberd 16.0或15.11时,我得到lager_transform未定义的错误。
请建议和帮助
请确保您按照文档中所述编译ejabberd:
例如,您可以通过以下方式编译它:
./ configure --enable -lager --enable-mysql
make
您需要运行configure并使其设置正确构建链。
I am new to Erlang, I have been trying to install Erlang and ejabberd on EC2 ubuntu machine, everything went well till I started compiling some external modules in ejabberd. It started throwing error "undefined parse transform 'lager_transform'". I tried everything which is as below :
- Did rebar get-deps, make clean, make deps, make install. After this I am able to see that lager_transform.beam is made and present in //lib/ folder.
- Checked rebar.config file, it had lager deps on top, which is widely suggested, no help even after that.
- Added
-compile[{parse_tranform},{lager_transform}]
on top of module, even then their is no luck.
I am really blocked on this, and not able to complete the installation. I have done this before on fedora with ejabberd 15.11 and otp 18.2, at that time it was using p1_logger
instead of lager. But now when I am installing fresh with otp 18.2 and ejabberd 16.0 or 15.11, I am getting lager_transform undefined error.
Please suggest and help
Please make sure you compile ejabberd as described in documentation: http://docs.ejabberd.im/admin/guide/installation/#installing-ejabberd-from-source-code
For example, you can compile it with:
./configure --enable-lager --enable-mysql
make
You need to run configure and make to set properly the build chain.
这篇关于ejabberd和Erlang安装与lager_transform未定义的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!