4

I installed Erlang and Elixir as recommended in the Elixir documentation for Ubuntu & Debian.

The results of running elixir -v:

Erlang/OTP 24 [erts-12.2.1] [source] [64-bit] [smp:32:32] [ds:32:32:10] [async-threads:1] [jit]

Elixir 1.13.0 (compiled with Erlang/OTP 24)

When I enter iex and try to start the debugger GUI with :debugger.start(), I get the following error:

12:22:51.248 [error] WX ERROR: Could not load library: :load_failed
Failed to load NIF library /usr/lib/erlang/lib/wx-2.1.1/priv/wxe_driver: 'libwx_gtk3u_webview-3.0.so.0: cannot open shared object file: No such file or directory'
{:error,
 {{:error,
   {:load_failed,
    'Failed to load NIF library /usr/lib/erlang/lib/wx-2.1.1/priv/wxe_driver: \'libwx_gtk3u_webview-3.0.so.0: cannot open shared object file: No such file or directory\''}},
  [
    {:wxe_server, :start, 1, [file: 'wxe_server.erl', line: 65]},
    {:wx, :new, 1, [file: 'wx.erl', line: 115]},
    {:dbg_wx_win, :init, 0, [file: 'dbg_wx_win.erl', line: 46]},
    {:dbg_wx_mon, :init, 3, [file: 'dbg_wx_mon.erl', line: 114]}
  ]}}

I checked the path /usr/lib/erlang/lib/wx-2.1.1/priv/ and found wxe_driver.so there.

2 Answers2

5

I found that the missing object file that was referenced, libwx_gtk3u_webview-3.0.so.0, is included in this package's filelist.

I installed the package with

sudo apt install libwxgtk-webview3.0-gtk3-0v5

and now :debugger.start() and :observer.start() launch their respective GUIs.

I answered my own question in the hopes that it'll help others and my future self. Anyone with further insight into why this package was missing from my installation and is not referenced anywhere in the Erlang or Elixir installation documentation, please add an answer or comment. I'm wondering if I missed something during the initial installation because I haven't found other reports of this issue.

  • 1
    if you are using 3.1.x series - you probably didn't supply the appropriate switch to the install. The webview library is optional and is not installed by default. This is probably Erlang documentation issue and you should report it accordingly. – Igor Mar 14 '22 at 16:46
0

For whom using asdf to manage erlang and elixir. You can fallow these steps if you are still unable to use erlang GUI.

  1. Install required libraries like described in here for the wxWidgets.
  2. Remove & Reinstall erlang and see if it's works.
Cengizz
  • 25
  • 2
  • 8