'Issues using POCO with OpenSSL to send SMTP email

This is my first time writing a program that has any interaction with email. As such, I simply want a program that when ran, sends an email. After some googling I have found that POCO is a simple library that allows me to do just that.

I would prefer to use C++.

I downloaded the latest version of POCO and included the library as well as the include folders in VS2015 Community on Windows 10. I set up a program just like the one found at this tutorial: https://axistasoft.com/blog/poco/poco-net/item/sending-email-messages-using-poco-securestreamsocket-securesmtpclientsession-class

However, when I compile the program I receive the error:

1>d:\downloads\openssl-1.1.0c\openssl-1.1.0c\include\openssl\e_os2.h(13): fatal error C1083: Cannot open include file: 'openssl/opensslconf.h': No such file or directory

So when I navigate to the folder that is named, I find a filed named 'opensslconf.h.in' - close to the file it is looking for. I'm not really sure what else to do here. This is my first time using POCO. I tried to use a simpler version with no OpenSSL but I do not believe it is possible to send email through GMail without it.

I have researched the errors but they either say that I just need to remove OpenSSL (can't do that) or some things specific to Unix, which I'm on windows.

Any ideas?



Solution 1:[1]

You can add it as an include folder, like -I D:\Path\To\Include\OpenSSL as a compiler argument or add it in your VS project in project settings.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 nk125