kagux / ex_debug_toolbar

A debug web toolbar for Phoenix projects to display all sorts of information about request
https://hex.pm/packages/ex_debug_toolbar
406 stars 11 forks source link

Not working on windows #64

Open lekoala opened 7 years ago

lekoala commented 7 years ago

Hey,

This looks like a wonderful tool! However I'm on windows and erlexec doesn't work. Would there be a way to make this dependancy optionnal?

OvermindDL1 commented 7 years ago

erlexec runs on windows 10 here (via cygwin, I'm not using the bash shell, so this will work on any windows version).

kagux commented 7 years ago

hey @lekoala,

erlexec is required for breakpoints functionality. One solution would be to make breakpoints optional. But I'd rather try to solve the issue with erlexec. Could you copy paste your error log?

OvermindDL1 commented 7 years ago

To be more specific, erlexec is a native binary and needs to be compiled, thus it requires a supported compiler on your system, and as long as you have that it should work fine. :-)

It 'is' possible for kagux to pre-build a windows binary and distribute it in the releases though for those that don't have C build systems installed.

kagux commented 7 years ago

@OvermindDL1, that's an interesting option. Although, if it comes to, erlexec should be doing that.

It's hard to avoid native packages though, and sooner or later you'd face a problem of building one. Unless of course it's a problem specific to erlexec. So maybe the best solution is to provide better build instructions for Windows in such cases.

Either way, @lekoala, seeing your logs would greatly help!

OvermindDL1 commented 7 years ago

It's hard to avoid native packages though, and sooner or later you'd face a problem of building one. Unless of course it's a problem specific to erlexec. So maybe the best solution is to provide better build instructions for Windows in such cases.

Not specific to erlexec at all, you need the same build system set up for bcrypt and such too. :-)

lekoala commented 7 years ago

Here is the error. But I think this is to be expected since erlexec is not supported on windows. I have cygwin but I have no idea how to compile my dependencies using it.

===> Compiling erlexec
===> Compiling ../deps/erlexec/c_src/ei++.cpp
===> g++: error: /c: No such file or directory
g++: error: /Fo ../deps/erlexec/c_src/ei++.o: Invalid argument

** (Mix) Could not compile dependency :erlexec, "escript.exe "c:/Users/MyUser/.mix/rebar3" bare compile --paths "../_build/dev/lib/*/ebin"" command failed. You
 can recompile this dependency with "mix deps.compile erlexec", update it with "mix deps.update erlexec" or clean it with "mix deps.clean erlexec"
sfusato commented 6 years ago

Having the same issue as @lekoala. Googled a bit before posting this. I remember I had a similar issue compiling Bcrypt for Comeonin, but that worked out eventually with VS++. Tried the same approach here without any success.

Is there a way to use ex_debug_toolbar on Windows 10 ?

===> Compiling erlexec
===> Compiling c:/../deps/erlexec/c_src/ei++.cpp
===> g++: error: /Foc:/.../deps/erlexec/c_src/ei++.o: Invalid argument

** (Mix) Could not compile dependency :erlexec, "escript.exe "c:/.../.mix/rebar3" bare compile --paths "c:/.../_build/dev/lib/*/ebin"" command failed. You can recompile this dependency with "mix deps.compile erlexec", update it with "mix deps.update erlexec" or clean it with "mix deps.clean erlexec"
sfusato commented 6 years ago

@OvermindDL1 how to build/compile erlexec under Windows via cygwin ?

OvermindDL1 commented 6 years ago

It just works for me, though I have the full cross-compilation pipeline installed in cygwin (I have to compile ocaml as well).