Skip to content

Commit

Permalink
jam file cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
grisumbras committed Aug 26, 2024
1 parent 18fe2b4 commit 72175b0
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 43 deletions.
10 changes: 4 additions & 6 deletions build.jam
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,15 @@ constant boost_dependencies :
/boost/system//boost_system
/boost/throw_exception//boost_throw_exception ;

project /boost/json
: common-requirements
<include>include
;
project /boost/json ;

alias boost_json : build//boost_json ;
alias json_deps : build//json_deps ;
alias json_sources : build//json_sources ;

alias all : boost_json json_deps json_sources bench example fuzzing test ;

call-if : boost-library json
call-if
: boost-library json
: install boost_json
;

34 changes: 9 additions & 25 deletions build/Jamfile
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,11 @@ rule warn-if-requested ( properties * )
}

project
: common-requirements <use>$(boost_dependencies)/<warnings-as-errors>off
: 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
Expand All @@ -68,33 +72,13 @@ project
# so we have to use a custom check
cxx11_basic_alignas
]
<link>shared:<define>BOOST_JSON_DYN_LINK=1
<link>static:<define>BOOST_JSON_STATIC_LINK=1
<define>BOOST_JSON_SOURCE
<toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS
: usage-requirements
<link>shared:<define>BOOST_JSON_DYN_LINK=1
<link>static:<define>BOOST_JSON_STATIC_LINK=1
<toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS
<library>/boost/container//boost_container/<warnings-as-errors>off
<define>BOOST_JSON_NO_LIB=1
: source-location ../src
;

alias json_deps
: usage-requirements
<library>/boost/container//boost_container/<warnings-as-errors>off
;

alias json_sources
: src.cpp
: usage-requirements
<library>/boost/container//boost_container/<warnings-as-errors>off
;

explicit json_deps json_sources ;

lib boost_json
: json_sources
: usage-requirements
<library>/boost/container//boost_container/<warnings-as-errors>off
;
alias json_deps ;
alias json_sources : src.cpp ;
lib boost_json : json_sources ;
20 changes: 8 additions & 12 deletions test/Jamfile
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ project
: requirements
<include>.
<toolset>msvc:<define>_SCL_SECURE_NO_WARNINGS
<toolset>msvc:<define>_CRT_SECURE_NO_WARNINGS
;

for local f in $(SOURCES)
Expand All @@ -71,26 +72,21 @@ for local f in $(SOURCES)
extra-reqs += <toolset>msvc:<cxxflags>/bigobj ;
}

run $(f) main.cpp /boost/json//boost_json
: requirements
<toolset>msvc:<define>_CRT_SECURE_NO_WARNINGS
$(extra-reqs)
;
run $(f) main.cpp /boost/json//boost_json : requirements $(extra-reqs) ;
}

run limits.cpp main.cpp /boost/json//json_sources
: requirements
<define>BOOST_JSON_SOURCE
<define>BOOST_JSON_MAX_STRING_SIZE=1000
<define>BOOST_JSON_MAX_STRUCTURED_SIZE=20
<define>BOOST_JSON_STACK_BUFFER_SIZE=256
<define>BOOST_JSON_MAX_STRING_SIZE=1000
<define>BOOST_JSON_MAX_STRUCTURED_SIZE=20
<define>BOOST_JSON_STACK_BUFFER_SIZE=256
;

run no_exceptions.cpp main.cpp /boost/json//json_sources
: requirements
<exception-handling>off
<toolset>msvc:<cxxflags>"/wd4530" # C++ exception handler used
<toolset>msvc:<cxxflags>"/wd4577" # noexcept used without /EHsc
<exception-handling>off
<toolset>msvc:<cxxflags>"/wd4530" # C++ exception handler used
<toolset>msvc:<cxxflags>"/wd4577" # noexcept used without /EHsc
;

run intrusive_macros.cpp main.cpp /boost/json//json_deps ;

0 comments on commit 72175b0

Please sign in to comment.