Add Jamfile, make CMake scripts Boost compliant

Summary: related to T15996

Reviewers: ivica, korina

Reviewed By: ivica

Subscribers: iljazovic, miljen

Differential Revision: https://repo.mireo.local/D33480
This commit is contained in:
Bruno Iljazovic
2025-02-12 15:49:45 +01:00
parent 53fe64d015
commit 7d18f20e56
41 changed files with 1195 additions and 620 deletions

View File

@ -1,16 +1,17 @@
cmake_minimum_required(VERSION 3.15)
#
# Copyright (c) 2025 Ivica Siladic, Bruno Iljazovic, Korina Simicevic
#
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE or copy at http://www.boost.org/LICENSE_1_0.txt)
#
project(async-mqtt5-examples CXX)
cmake_minimum_required(VERSION 3.8...3.20)
include(../cmake/project-is-top-level.cmake)
if(PROJECT_IS_TOP_LEVEL)
find_package(async-mqtt5 REQUIRED)
endif()
project(async-mqtt5-examples LANGUAGES CXX)
function(add_example name)
add_executable("${name}" ${ARGN})
target_link_libraries("${name}" PRIVATE Async::MQTT5)
target_link_libraries("${name}" PRIVATE Boost::mqtt5)
string(FIND "${example_name}" "tls" found_tls)
if(found_tls GREATER -1)
target_link_libraries("${name}" PRIVATE OpenSSL::SSL)

View File

@ -21,6 +21,7 @@
#include <boost/asio/strand.hpp>
#include <boost/asio/thread_pool.hpp>
#include <cassert>
#include <iostream>
#include <string>
#include <thread>

View File

@ -18,6 +18,7 @@
#include <boost/asio/strand.hpp>
#include <boost/asio/thread_pool.hpp>
#include <cassert>
#include <iostream>
#include <string>
#include <thread>