2
0
mirror of https://github.com/boostorg/log.git synced 2026-01-21 05:02:10 +00:00
Files
log/example/event_log/Jamfile.v2
René Ferdinand Rivera Morell 2530a4e03a Add support for modular build structure. (#233)
* Make the library modular usable.

* Switch to library requirements instead of source. As source puts extra source in install targets.

* Clean up build dependencies.

* Remove external build references and avoid custom project loading.

* Use relative paths to declare config sub-projects.

* Add missing NO_LIB usage requirements.

* Add missing library ref.

* Add missing import-search for cconfig/predef checks.

* Add requires-b2 check to top-level build file.

* Update dependencies.

* Bump B2 require to 5.2

* Update copyright dates.

* Move inter-lib dependencies to a project variable and into the build targets.

* Remove custom symbolic project names for config subprojects. And use project root relative targets.

* Move private deps to the build project.

* Put back default boost locale link as locale build is now fixed.

* Set default address-model and architecture to avoid extra/custom detection logic. Put back missing check and config rules.

* Adjust doc build to avoid boost-root references.

* Fix ref to predef.jam location.

* Have B2 build use same deps as CML for per-target private/public.

* Add log dep to log_setup, as it's needed on some platforms.

* Add boost_log_with_support target to mirror CML.

* Fix platform specific winapi dependency spec.
2025-05-26 00:48:16 +03:00

95 lines
3.3 KiB
Plaintext

#
# Copyright Andrey Semashev 2007 - 2016.
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)
#
import os ;
import configure ;
import ../../build/log-platform-config ;
rule has-config-flag ( flag : properties * )
{
if ( "<define>$(flag)" in $(properties) || "<define>$(flag)=1" in $(properties) )
{
return 1 ;
}
else
{
return ;
}
}
rule check-message-compiler ( properties * )
{
local result ;
if <target-os>windows in $(properties)
{
if ! [ has-config-flag BOOST_LOG_WITHOUT_EVENT_LOG : $(properties) ]
{
local has_mc = [ configure.builds /boost/log/config/message-compiler//test-availability : $(properties) : message-compiler ] ;
if ! $(has_mc)
{
result += <build>no ;
}
}
}
else
{
result += <build>no ;
}
return $(result) ;
}
project
: requirements
<conditional>@log-platform-config.set-platform-defines
<conditional>@check-message-compiler
<link>shared
<c++-template-depth>1024
<toolset>msvc:<cxxflags>/bigobj
<toolset>msvc:<cxxflags>/wd4503 # decorated name length exceeded, name was truncated
<toolset>msvc:<cxxflags>/wd4456 # declaration of 'A' hides previous local declaration
<toolset>msvc:<cxxflags>/wd4459 # declaration of 'A' hides global declaration
<toolset>msvc:<cxxflags>/wd4003 # not enough actual parameters for macro 'X' - caused by BOOST_PP_IS_EMPTY and BOOST_PP_IS_BEGIN_PARENS which are used by Fusion
<toolset>gcc:<cxxflags>-fno-strict-aliasing # avoids strict aliasing violations in other Boost components
# Disable Intel warnings:
# warning #177: function "X" was declared but never referenced
# warning #780: using-declaration ignored -- it refers to the current namespace
# warning #2196: routine is both "inline" and "noinline"
# remark #1782: #pragma once is obsolete. Use #ifndef guard instead.
# remark #193: zero used for undefined preprocessing identifier "X"
# remark #304: access control not specified ("public" by default)
# remark #981: operands are evaluated in unspecified order
# remark #1418: external function definition with no prior declaration
# Mostly comes from Boost.Phoenix: warning #411: class "X" defines no constructor to initialize the following: reference member "Y"...
# warning #734: "X" (declared at line N of "file.hpp"), required for copy that was eliminated, is inaccessible
# warning #279: controlling expression is constant
<toolset>intel-win:<cxxflags>"/Qwd177,780,2196,1782,193,304,981,1418,411,734,279"
<toolset>intel-linux:<cxxflags>"-wd177,780,2196,1782,193,304,981,1418,411,734,279"
<toolset>intel-darwin:<cxxflags>"-wd177,780,2196,1782,193,304,981,1418,411,734,279"
<library>/boost/log//boost_log
<library>/boost/date_time//boost_date_time
<library>/boost/filesystem//boost_filesystem
<threading>multi
;
lib event_log_messages
: event_log_messages.mc
: <linkflags>-noentry
# <name>event_log_messages
;
exe event_log
: main.cpp
: <implicit-dependency>event_log_messages
;