Asdf-erlang: Unable to install erlang 23.0

Created on 13 May 2020  Â·  14Comments  Â·  Source: asdf-vm/asdf-erlang

I get the following error installing erlang 23.0:

Downloading kerl...
Downloading OTP-23.0.tar.gz to /Users/kurayama/.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    170      0 --:--:-- --:--:-- --:--:--   170
100 53.7M  100 53.7M    0     0  4159k      0  0:00:13  0:00:13 --:--:-- 4497k
Extracting source code
Building Erlang/OTP 23.0 (asdf_23.0), please wait...
DOCUMENTATION INFORMATION (See: /Users/kurayama/.asdf/plugins/erlang/kerl-home/builds/asdf_23.0/otp_build_23.0.log)
 * documentation  :
 *                  fop is missing.
 *                  Using fakefop to generate placeholder PDF files.

Erlang/OTP 23.0 (asdf_23.0) has been successfully built
Installing Erlang/OTP 23.0 (asdf_23.0) in /Users/kurayama/.asdf/installs/erlang/23.0...
You can activate this installation running the following command:
. /Users/kurayama/.asdf/installs/erlang/23.0/activate
Later on, you can leave the installation typing:
kerl_deactivate
Cleaning up compilation products for
Cleaned up compilation products for  under /Users/kurayama/.asdf/plugins/erlang/kerl-home/builds
ln: ./erl_call: File exists

Most helpful comment

@lucianoengel I was able to install 23.0.3 by following the instructions at #156:

  1. Remove the asdf_23.0.3 ... line from ~/.asdf/plugins/erlang/kerl-home/otp_installations.
  2. Run asdf plugin-update erlang to upgrade the erlang plugin.
  3. Try installing again.

All 14 comments

I am also getting the same error on MacOS. I was able to build and install 23.0 using kerl directly, so the issue seems to be in asdf-erlang, probably when running this step https://github.com/asdf-vm/asdf-erlang/blob/master/bin/install#L46

The same problem exists on Linux (Pop!_OS 20.04):

Extracting source code
Building Erlang/OTP 23.0 (asdf_23.0), please wait...
Erlang/OTP 23.0 (asdf_23.0) has been successfully built
Installing Erlang/OTP 23.0 (asdf_23.0) in /home/gmc/.asdf/installs/erlang/23.0...
You can activate this installation running the following command:
. /home/gmc/.asdf/installs/erlang/23.0/activate
Later on, you can leave the installation typing:
kerl_deactivate
Cleaning up compilation products for 
Cleaned up compilation products for  under /home/gmc/.asdf/plugins/erlang/kerl-home/builds
ln: failed to create symbolic link './erl_call': File exists
version 23.0 is not installed for erlang

Odd. Does Erlang 23.0 ship with two erl_call binaries?

The code that appears to be failing is this:

    ln -s ../lib/*/bin/* ../lib/*/priv/bin/* .

It appears to ship with 3 😕

➜  release_23.0 pwd
/Users/nico/.kerl/builds/23.0/release_23.0
➜  release_23.0 fd erl_call
bin/erl_call
erts-11.0/bin/erl_call
lib/erl_interface-4.0/bin/erl_call
lib/erl_interface-4.0/src/prog/erl_call.c

😞 that's not going to work out well. Which one should we put on the users path? bin/erl_call I assume.

Looking at the 23.0 notes it seems this was the issue:

 OTP-16602    Application(s): erts

               The executable erl_call is now part of the erts
               distribution in addition to erl_interface.

I was facing the same issue, after updating the plugin (and thus getting the fix from #143) I am now seeing a different error:

$~ asdf install erlang 23.0.2
asdf_23.0.2 is not a kerl-managed Erlang/OTP installation
The asdf_23.0.2 build has been deleted
Extracting source code
Building Erlang/OTP 23.0.2 (asdf_23.0.2), please wait...
DOCUMENTATION INFORMATION (See: /Users/ole/.asdf/plugins/erlang/kerl-home/builds/asdf_23.0.2/otp_build_23.0.2.log)
 * documentation  : 
 *                  fop is missing.
 *                  Using fakefop to generate placeholder PDF files.

Erlang/OTP 23.0.2 (asdf_23.0.2) has been successfully built
ERROR: Installation (asdf_23.0.2) already registered for this location (/Users/ole/.asdf/installs/erlang/23.0.2)

I'd appreciate any tips about how to solve this :)


Update (solved): The solution was already described here https://github.com/asdf-vm/asdf-erlang/issues/143#issuecomment-628453296

I'm having this same issue with 23.0.3, 23.0.2 works fine

@lucianoengel I was able to install 23.0.3 by following the instructions at #156:

  1. Remove the asdf_23.0.3 ... line from ~/.asdf/plugins/erlang/kerl-home/otp_installations.
  2. Run asdf plugin-update erlang to upgrade the erlang plugin.
  3. Try installing again.

Had the same issue from above, after getting

ln: ./erl_call: File exists

installation kept interrupting until I reinstalled asdf erlang plugin and removed existing erlang brew package(previous asdf installs worked well while having it). The weird thing is that the message didn't go, but the installation succeeded anyway:

Extracting source code
Building Erlang/OTP 23.1.1 (asdf_23.1.1), please wait...
Erlang/OTP 23.1.1 (asdf_23.1.1) has been successfully built
Installing Erlang/OTP 23.1.1 (asdf_23.1.1) in /Users/Sergey/.asdf/installs/erlang/23.1.1...
You can activate this installation running the following command:
. /Users/Sergey/.asdf/installs/erlang/23.1.1/activate
Later on, you can leave the installation typing:
kerl_deactivate
Cleaning up compilation products for
Cleaned up compilation products for  under /Users/Sergey/.asdf/plugins/erlang/kerl-home/builds
ln: ./erl_call: File exists

Erlang 23.1.1 has been installed. Activate globally with:

    asdf global erlang 23.1.1

Activate locally in the current folder with:

    asdf local erlang 23.1.1

Is there some way to recover from that last step without having to wait 10-15 minutes for the full build again? It seems like a waste to start the entire build from scratch each time.

@DestyNova are you using the latest version of asdf-erlang? Try asdf plugin-update erlang. I have recently installed a version of Erlang and this issue didn't prevent it from being considered a successful installation.

Hi @Stratus3D -- I followed roughly this process:

  1. asdf install erlang latest
  2. Observe failed build after about 15 minutes (on an old i3 laptop)
  3. Try asdf update and asdf plugin update erlang, then repeat the installation command
  4. Observe failed build after another 15 minutes
  5. Find this issue and follow the advice to Remove the asdf_23.0.3 ... line from ~/.asdf/plugins/erlang/kerl-home/otp_installations, then run the installation command again
  6. Observe successful build after another 15 minutes

So the problem is solved, but I was a bit disappointed to see that the entire source-unpacking and compilation process is repeated from scratch after each failed build. It'd be better if asdf could continue on from the last successful point during installation -- especially in this case since it seemed to fail _right_ at the end each time :disappointed:

@DestyNova I understand, I agree that the process shouldn't start from scratch if some steps have succeeded. That is related to https://github.com/asdf-vm/asdf-erlang/issues/111, which is an unresolved bug.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

CraigCottingham picture CraigCottingham  Â·  4Comments

cehoffman picture cehoffman  Â·  3Comments

denegny picture denegny  Â·  6Comments

sorliem picture sorliem  Â·  4Comments

nathany picture nathany  Â·  6Comments