arun11299/cpp-jwt

How to Connect to OpenSSL

Closed this issue · 4 comments

Hello,

I was going through the "Installation" section of the "Read Me", and was unsure as to how to connect to OpenSSL using cmake within my project. I am using Visual Studio 2017 on Windows 10. When I try to #include "jwt/jwt.hpp" I am met with the errors "cannot open source file 'openssl/bn.h'" along with multiple other openssl files. I am relatively new to coding and it would help a lot if someone is able to provide a step by step solution to this problem. Thank you so much for your help.

Hello @LinsaneFC

Did you see the "cmake_command" file ? I have put the command to run cmake. I assume that you have installed OpenSSL in your machine.
Running that command (with the correct location the OpenSSL root directory and library from your system), you should be able to build the tests. It requires you to install GTEST as well.
ELSE, you can see the cmake example in "examples" directory and try to add another file for you to play around with and test. I would recommend you to install Gtest for windows though.

Hello @arun11299

Thank you for your help. I was able to install the OpenSSL and change the respective root directory/library in the cmake command, but am unsure about how to run the cmake command in Visual Studio 2017. I have a project I am working on, and want to be able to use this JWT library in it. It would be very helpful if you could guide me through this process. Thank you.

@LinsaneFC Please reopen if you need any further help.

Thank You.