环境:
Linux host 4.19.90-9.ky10.aarch64 #1 SMP Sun Apr 26 11:05:59 CST 2020 aarch64 aarch64 aarch64 GNU/Linux
gcc (GCC) 7.3.0
GNU Make 4.2.1 为 aarch64-koji-linux-gnu 编译
1、安装erlang
http://erlang.org/documentation/doc-9.1/doc/installation_guide/INSTALL.html 依赖项
http://erlang.org/documentation/doc-5.10.4/doc/installation_guide/INSTALL.html#Required-Utilities_Installing
OTP 23
./configure --prefix=/usr/local/erlang --with-ssl --enable-threads --enable-smp-support --enable-kernel-poll --enable-hipe --without-javac
make && make install
添加环境变量,比如添加到 /etc/profile
ERLANG_HOME=/usr/local/erlang
PATH=$PATH:$ERLANG_HOME/bin
然后,source /etc/profile
安装wxWidgets
问题:configure: error: cannot guess build type; you must specify one
[root@host-10-0-0-147 emqx]# /usr/share/automake-1.16/config.guess
aarch64-unknown-linux-gnu
使用该输出即可,--build=aarch64-unknown-linux-gnu
2、https://github.com/emqx/emqx:下载release、tag版本,编译老是失败,报如下错误?
===> Fetching emqx (from {git,"https://github.com/emqx/emqx",
{tag,"/bin/sh: line 1: syntax error near unexpected token `('"}})
===> Failed to fetch and copy dep: {git,"https://github.com/emqx/emqx",
{tag,
"/bin/sh: line 1: syntax error near unexpected token `('"}}
make: *** [Makefile:78:emqx] 错误 1
=》感觉打的tag有问题?
3、https://github.com/emqx/emqx-rel:如果clone到本地,编译成功;
如果直接下载release、tag版,也会失败?
参照https://github.com/emqx/emqx介绍,Build From Source
The EMQ X broker requires Erlang/OTP R21+ to build since 3.0 release.
git clone -b v4.0.0 https://github.com/emqx/emqx-rel.git
cd emqx-rel && make
cd _build/emqx/rel/emqx && ./bin/emqx console
make过程中,会自动下载rebar3到本地,所以,不需要额外安装
编译成功后的版本位置:_build/emqx/rel/emqx
其中
=》编译v4.0.0,最后老是失败
=》编译v4.1.4,最后老是失败
=》编译v4.2.5,成功
......
updated_relup_deps for "emqx_coap"
updated_relup_deps for "emqx_bridge_mqtt"
updated_relup_deps for "emqx_auth_username"
updated_relup_deps for "emqx_auth_redis"
updated_relup_deps for "emqx_auth_pgsql"
updated_relup_deps for "emqx_auth_mysql"
updated_relup_deps for "emqx_auth_mongo"
updated_relup_deps for "emqx_auth_mnesia"
updated_relup_deps for "emqx_auth_ldap"
updated_relup_deps for "emqx_auth_jwt"
updated_relup_deps for "emqx_auth_http"
updated_relup_deps for "emqx_auth_clientid"
===> [relup_helper] running gen_appups
===> Starting relx build process ...
===> Resolving OTP Applications from directories:
/usr/local/src/emqx-rel-4.1.4-test/clone-4.2.5/emqx-rel/_build/emqx/lib
/usr/local/src/emqx-rel-4.1.4-test/clone-4.2.5/emqx-rel/_checkouts
/usr/local/erlang/lib/erlang/lib
===> Resolved emqx-4.2.5
===> Including Erts from /usr/local/erlang/lib/erlang
===> release successfully created!
===> [relup_helper] running otp_vsn
===> [relup_helper] untar previous versions of balls: []
TODO 使用qemu,安装arm64架构系统,编译
makefile
Linux 安装erlang 还需要jdk? erlang --without-javac
rebar3
安装erlang过程中,各种依赖
参考:
https://blog.csdn.net/hjing123/article/details/88863311 libtool,libtool-ltdl-devel
https://blog.csdn.net/ws_kfxd/article/details/85858736
https://www.cnblogs.com/lr1402585172/p/11453984.html
https://blog.csdn.net/caijiapeng0102/article/details/80817525
https://www.pianshen.com/article/4198288186/
https://blog.csdn.net/weixin_43734561/article/details/109494987 kylin yum
https://www.cnblogs.com/jackicalSong/p/11425664.html
https://www.cmdschool.org/archives/6646
https://lists.gnu.org/mailman/listinfo/gnutls-devel
https://pkgs.org/download/gnutls-devel
https://mirrors.sjtug.sjtu.edu.cn/gnu/termcap/
https://www.v2ex.com/amp/t/513898
https://blog.csdn.net/cxjddd/article/details/139990
http://c.biancheng.net/view/1126.html
https://blog.csdn.net/ThefFirsttThelLast/article/details/82705979?utm_medium=distribute.pc_relevant.none-task-blog-BlogCommendFromMachineLearnPai2-2.control&depth_1-utm_source=distribute.pc_relevant.none-task-blog-BlogCommendFromMachineLearnPai2-2.control
https://blog.csdn.net/costeeer/article/details/81268046
https://blog.csdn.net/scottly1/article/details/24243661
https://blog.csdn.net/zhang_danf/article/details/22406297 wxWidgets
http://www.wxwidgets.org/downloads/
https://github.com/wxWidgets/wxWidgets
https://blog.csdn.net/fairytalefu217/article/details/84824123
https://blog.csdn.net/sxhelijian/article/details/25749505
https://github.com/erlang/rebar3#getting-started
https://rebar3.org/
https://github.com/emqx/erlang-bcrypt
https://github.com/deadtrickster/ssl_verify_fun.erl
https://blog.csdn.net/ctwy291314/article/details/104550966/