Skip to content

How to build the SMTP client library

Jeremy Dumais edited this page Apr 19, 2025 · 2 revisions

Generic Build Instructions

Setup

To build CPP-SMTPClient-library, you need to tell your build system where to find its headers and source files. The exact way to do it depends on which build system you use, and is usually straightforward.

Build with CMake

CMake
CPP-SMTPClient-library comes with a CMake build script (CMakeLists.txt) that can be used on a wide range of platforms ("C" stands for cross-platform.). If you don't have CMake installed already, you can download it for free from http://www.cmake.org/.

CMake works by generating native makefiles or build projects that can be used in the compiler environment of your choice. You can either build CPP-SMTPClient-library as a standalone project or it can be incorporated into an existing CMake build for another project.

Windows and OpenSSL (for CPP-SMTPClient-library version 1.1.0 and later)

OpenSSL
CPP-SMTPClient-library require OpenSSL so you can download one the precompiled version here: https://www.npcglib.org/~stathis/blog/precompiled-openssl/.


Platform-specific build instructions


Linux
Build the CPP-SMTPClient-library on Linux

Windows
Build the CPP-SMTPClient-library on Windows

macOS
Build the CPP-SMTPClient-library on macOS

Clone this wiki locally