-
Notifications
You must be signed in to change notification settings - Fork 99
/
Copy pathJamfile
91 lines (83 loc) · 2.56 KB
/
Jamfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
#
# Copyright (c) 2019 Vinnie Falco (vinnie dot falco at gmail dot com)
# Copyright (c) 2021 Dmitry Arkhipov (grisumbras@gmail.com)
#
# 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)
#
# Official repository: https://github.com/boostorg/json
#
import-search /boost/config/checks ;
import boost-pretty-printers ;
import config ;
import modules ;
rule requires ( tests + )
{
local result ;
for test in $(tests)
{
local name = $(test:D=) ;
local m = $(test:D) ;
if $(m)
{
m = [ modules.binding $(m) ] ;
m = $(m:D)// ;
}
m ?= "" ;
result += [ check-target-builds $(m)$(name) $(name)
: : <build>no <conditional>@warn-if-requested
] ;
}
return $(result) ;
}
.warned = ;
rule warn-if-requested ( properties * )
{
if ! $(.warned)
{
.warned = true ;
local args = [ modules.peek : ARGV ] ;
local var = [ modules.peek project-config : libraries ] ;
if json in [ MATCH ^--with-(json) : $(args) $(var) ]
{
echo "warning:" Boost.Json was explicitly requested, but will not
be built, because it requires C++11. ;
echo "note:" To enable C++11 support, use the 'cxxstd=11' command line
argument. ;
}
}
}
project
: common-requirements
<include>../include
<use>$(boost_dependencies)/<warnings-as-errors>off
<link>shared:<define>BOOST_JSON_DYN_LINK=1
<link>static:<define>BOOST_JSON_STATIC_LINK=1
: requirements
[ requires
config/cxx11_constexpr
config/cxx11_decltype
config/cxx11_hdr_tuple
config/cxx11_template_aliases
config/cxx11_variadic_templates
config/cxx11_alignas
]
<toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS
: usage-requirements
<library>/boost/container//boost_container/<warnings-as-errors>off
<library>/boost/charconv//boost_charconv/<warnings-as-errors>off
<define>BOOST_JSON_NO_LIB=1
: source-location ../src
;
alias json_deps ;
alias json_sources : src.cpp ;
lib boost_json : json_sources ;
boost-pretty-printers.gdb-python-header gdb_printers.hpp
: boost_json_gdb_printers.py
: <location>../include/boost/json/detail
<flags>--header-guard=BOOST_JSON_DETAIL_GDB_PRINTERS_HPP
<flags>--disable-macro=
;
always gdb_printers.hpp ;
explicit regenerate-printers gdb_printers.hpp ;
alias regenerate-printers : gdb_printers.hpp ;