FC++  v0.9.0-9e9b65
FileCatalyst Fast File Transfers - C++ Library
Linking
Warning
In August 2020, the build process for FC++ was modified to use vcpkg. This means that FC++ should now always build with the latest version of important libraries, such as Boost and OpenSSL. (In the past, some of these libraries had been fixed to specific versions which caused problems when important security updates were released.) Thus, some of the build and link instructions in this document may be slightly out-of-date. Please contact Unlimi-Tech support for the most recent instructions.

The FC++ API installation for Windows requires files from both OpenSSL and Boost. The necessary files are installed as part of the FC++ API. The default installation directories are "C:\Program Files\FCpp\bin" and "C:\Program Files\FCpp\lib". Projects that use FC++ will need to link against these library files:

filename description
"C:\Program Files\FCpp\lib\fcpp.lib" FileCatalyst C++ library (upload, download, UDP, TCP, etc.)
"C:\Program Files\FCpp\lib\boost_regex-vc140-mt-1_58.lib" support for regular expressions
"C:\Program Files\FCpp\lib\boost_system-vc140-mt-1_58.lib" support for error status (used by ASIO and fc::Exception)
"C:\Program Files\FCpp\lib\libeay32.lib" OpenSSL
"C:\Program Files\FCpp\lib\ssleay32.lib" OpenSSL
"C:\Program Files\FCpp\bin\boost_regex-vc140-mt-1_58.dll" regular expressions
"C:\Program Files\FCpp\bin\boost_system-vc140-mt-1_58.dll" error status
"C:\Program Files\FCpp\bin\libeay32.dll" OpenSSL
"C:\Program Files\FCpp\bin\ssleay32.dll" OpenSSL

If using a build system such as CMake, then the usual calls to FIND_PACKAGE will help find the right libraries. For example:

SET ( Boost_USE_MULTITHREADED ON )
SET ( Boost_USE_STATIC_LIBS ON )
SET ( Boost_USE_STATIC_RUNTIME OFF )
SET ( Boost_USE_DEBUG_RUNTIME OFF )
FIND_PACKAGE ( Boost REQUIRED COMPONENTS regex system )
FIND_PACKAGE ( OpenSSL REQUIRED )
INCLUDE_DIRECTORIES ( AFTER ${Boost_INCLUDE_DIR} ${OPENSSL_INCLUDE_DIR} )

If creating Visual Studio C++ project manually, make the following modifications to "Project Properties":

  • Edit the "Project Properties"
  • Click on "Configuration Properties -> VC++ Directories -> Include Directories"
    • Add the path to where the FC++ include files were installed, e.g., "C:\Program Files\FCpp\include"
    • Add the path to Boost, e.g., "C:\local\boost_1_58_0"
  • Click on "Configuration Properties -> VC++ Directories -> Library Directories"
    • Add the path to where the FC++ libraries were installed, e.g., "C:\Program Files\FCpp\lib"
  • Click on "Configuration Properties -> Linker -> Input"
    • Add the OpenSSL library libeay32.lib
    • Add the OpenSSL library ssleay32.lib
    • Add the Boost library boost_regex-vc140-mt-1_58.lib
    • Add the Boost library boost_system-vc140-mt-1_58.lib