Comeonin.Bcrypt in Elixir & Phoenix

Comeonin is password hashing library for elixir. It’s used by many elixir packages like coherence for user admin modules. You can also use Comeonin in your application.

In Windows, the elixir or phoenix application will compile and run with comeonin dependency, but the bcrypt will through error.

Use the following from https://github.com/riverrun/comeonin/wiki/Requirements to get comeonin compile on windows machine.

The first, and most straightforward, option:

  • Install a recent version of Visual Studio (you can download the community edition for free). When you install Visual Studio, make sure you also install the C / C++ tools.
  • After installing VS, look in the Program Files (x86) folder and search for Microsoft Visual Studio. Note down the full path of the folder with the highest version number.
  • Open the run command and type in the following command (make sure that the path and version number are correct):

    cmd /K "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" amd64

  • This should open up a command prompt with the necessary environment variables set, and from which you will be able to run the commands mix compile, mix deps.compile and mix test.

Leave a Reply

Your email address will not be published. Required fields are marked *