script
I have asdf installed with the all the dependencies mentioned on the site. I am able to successfully installed and use different versions of elixir, but when it comes to Erlang I am unable to install any version with asdf. I tried 21.x and also 22.x versions. I have latest Erlang version installed with brew and it’s working. I got the below error when I try to install any version.
asdf install erlang 22.0
Downloading kerl...
asdf_22.0 is not a kerl-managed Erlang/OTP installation
No build named asdf_22.0
Downloading OTP-22.0.tar.gz to /Users/weiswise/.asdf/plugins/erlang/kerl-home/archives...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 120 100 120 0 0 200 0 --:--:-- --:--:-- --:--:-- 200
100 52.2M 0 52.2M 0 0 1495k 0 --:--:-- 0:00:35 --:--:-- 1568k
Extracting source code
Building Erlang/OTP 22.0 (asdf_22.0), please wait...
Configure failed.
checking size of int... 0
checking size of long... 0
checking size of long long... 0
checking size of __int64... 0
checking size of __int128_t... 0
checking whether byte ordering is bigendian... no
checking whether double word ordering is middle-endian... yes
configure: error: cannot build emulator since no thread library was found
ERROR: /Users/weiswise/.asdf/plugins/erlang/kerl-home/builds/asdf_22.0/otp_src_22.0/erts/configure failed!
./configure: line 343: kill: (-60536) - No such process
I think Erlang 21.x and 22.x are not supported on apple silicon Macs, at least not all the versions that’s why it’s not installing.
I tried with version 23.3.4 stable build and asdf is able to install it successfully.
I tried with 22.3.4.19 stable build and asdf is also able to install it without any issue.
For this issue
./configure: line 343: kill: (-60536) - No such process
add the below line in your bash or zsh file.
CFLAGS="-O2 -g"
Also add this line in the bash or zsh
KERL_CONFIGURE_OPTIONS="--disable-debug --without-javac"
So, asdf is working fine, the only issue is arm base architecture of MacBook.
I am leaving the post here, so that anyone in the future can get help from here.
Thank you.
Trending in Questions
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixirconf-us
- #ai
- #blog-post
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #metaprogramming
- #hex
- #security










Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
drl123
I don’t have an m1 Mac, but ran into tons of issues and none of the posts in the 24.0.1 released topic worked. Turns out it has something to do with the version of Kerl used by ASDF installs. See this post Erlang OTP-24.0.1 released! - #17 by drl123. There is a workaround linked there that worked for me on Mojave. Maybe it will work for you too.
bapti
I’ve got an M1 MacBook running Monterey 12.3.1 and experiencing the same issue. @script I tried the same exports in my zsh file as you listed but it didn’t do the trick do for me.
Could you point to where you discovered your fix?
Here’s my console output
moogle19
Erlang/OTP 22.3.4.2 doesn’t work with M1 Macs.
If it is an option, you can use OTP >= 22.3.4.16.
The Apple Silicon build was fixed in that release.
7stud
I’ve also got an M1 MacBook running Monterey 12.3.1, and a couple days ago I successfully installed Erlang 24.3.4 with wxWidgets using asdf. I did struggle for a couple of days trying to solve some wxWidgets issues, and I posted an issue on github about my problems:
https://github.com/asdf-vm/asdf-erlang/issues/251
When I first attempted the install, I was running Monterey 12.2.1, and I stupidly agreed to a system update, which bumped me up to Monterey 12.3.1, and the next day I tried some things to correct the wxWidgets problems, and suddenly the install worked.
Even though the initial output poined to some issues with wxWidgets, I think erlang 24.3.4 installed successfully on the first go:
bapti
Thanks a million, this solved my issue, once I bumped up my version then I had no further problems
sridhar
FYI, I was able to backport fixes to an older version (22.0.7) and create OTP binaries on my M1 machine with that (if anyone’s interested). I don’t think you can do it with kerl/asdf but directly from source is possible Commits · smocherla-brex/otp · GitHub
If anyone’s interested, these are the steps
Ivor
Changing from 24.1.7 to 24.3.4 resolved my issue. Ventura + M1. Observer is working as well.
heathrm
fixed an issue I had installing Erlang 25.3. In looking it up, it seems it’s an optimization flag. Any idea why that would fix something on an M1?
htdat148
hi all, I have a problem with my asdf on mac M1. I install asdf with brew commnad
brew install asdfand its current version is0.18.0 (revision unknown). I been able to install OTP 26 which usingasdf install erlang 26.2.5.6. But my asdf does not haveglobaloption to activate the erlang version. I also have asdf with my ubuntu machine, it has theglobaloption so I can easily switch the version.To activate the erlang in my mac I have to put this command in my bash
#. /Users/m1/.asdf/installs/erlang/26.2.5.6/activatewhich iskerlcommandDo you know how to activate the erlang with asdf on mac M chip?
arcanemachine
asdf had a rewrite lately, I think you would use
asdf setnow.Take another look at the instructions, particularly the All Commands page.
And (off the top of my head), I think you would set a “global” version in
~/.tool-versions. I could be way off base though, asdf is very set-it-and-forget-it for me.