Hello.
I am following the OTP and Mix tutorial and I got to the step where I need to start the observer using :observer.start. I am currently getting the following error:
Could not find 'wxe_driver.so' in: /Users/valio/.asdf/installs/erlang/23.2.1/lib/wx-1.9.2/priv
I have followed the instruction for installing erlang via asdf:
Install wxmac using brew
Install erlang using asdf
Still getting the error.
During the build process for erlang I see:
APPLICATIONS INFORMATION (See: /Users/valio/.asdf/plugins/erlang/kerl-home/builds/asdf_23.2.1/otp_build_23.2.1.log)
* wx : No OpenGL headers found, wx will NOT be usable
* No GLU headers (glu.h) found, wx will NOT be usable
I am not sure if this is relevant.
I have tried reinstalling everything multiple times with no success.
When installing erlang with asdf, which uses kerl under the hood, you will want to set some environment variables in your shells profile (example: .bash_profile) so that the installation can find programs like wx-config. Here is what I have set in my .bash_profile
To find the paths of javac and wx-config you can type which javac and which wx-config in your terminal. After setting these in your shell, reinstall erlang. Observer needs wx widgets because it is a graphical interface. With erlang installed knowing where to find wx-config, observer should work.
Hi Logan. Unfortunately that didn’t work for some reason.
Here is what I did:
uninstalled erlang using asdf uninstall erlang 23.2.1
Checked the paths to javac and wx-config
Added the variables to my shell
Installed erlang using asdf install erlang latest
I then run iex -S mix inside my project folder and try to run :observer.start
I get the same error.
In the build logs for erlang I see:
checking for debug build of wxWidgets... checking for wx-config... /usr/local/bin/wx-config
checking for wxWidgets version >= 2.8.4 (--unicode --debug=yes)... yes (version 3.0.5)
checking for wxWidgets static library... no
checking for standard build of wxWidgets... checking for wx-config... /usr/local/bin/wx-config
checking for wxWidgets version >= 2.8.4 (--unicode --debug=no)... yes (version 3.0.5)
checking for wxWidgets static library... no
Also, I have force uninstalled the erlang the comes with elixir when it is installed using brew.
I am on Elixir 1.11.3-otp-23 and Erlang 23.2.1, I have wxmac installed (at 3.0.5.1_1) and I don’t have to use any variables to have :observer.start() working.
Are you on the latest macOS? Did you do xcode-select --install after your last macOS upgrade?