Merge pull request #18262 from TDT-AG/pr/20220406-strongswan
[feed/packages.git] / libs / boost / patches / 010-fix-b2-install.patch
1 --- a/tools/build/src/tools/stage.jam
2 +++ b/tools/build/src/tools/stage.jam
3 @@ -478,6 +478,10 @@ class install-target-class : basic-targe
4 return [ sequence.unique $(result2) ] ;
5 }
6
7 + rule skip-from-usage-requirements ( )
8 + {
9 + }
10 +
11 # Returns true iff 'type' is subtype of some element of 'types-to-include'.
12 #
13 local rule include-type ( type : types-to-include * )
14 --- /dev/null
15 +++ b/tools/build/test/install_build_no.py
16 @@ -0,0 +1,26 @@
17 +#!/usr/bin/python
18 +
19 +# Copyright 2021 Dmitry Arkhipov (grisumbras@gmail.com)
20 +# Distributed under the Boost Software License, Version 1.0.
21 +# (See accompanying file LICENSE.txt or https://www.bfgroup.xyz/b2/LICENSE.txt)
22 +
23 +# Check that <build>no in usage-requirements of dependencies does not affect
24 +# install rule, i.e. a skipped installed target does not affect insallation of
25 +# other targets.
26 +
27 +import BoostBuild
28 +
29 +t = BoostBuild.Tester()
30 +
31 +t.write("a.cpp", "int main() {}\n")
32 +
33 +t.write("jamroot.jam", """
34 +make x : : maker : <build>no ;
35 +exe a : a.cpp ;
36 +install install : x a ;
37 +""")
38 +
39 +t.run_build_system()
40 +t.expect_addition("install/a.exe")
41 +
42 +t.cleanup()
43 --- a/tools/build/test/test_all.py
44 +++ b/tools/build/test/test_all.py
45 @@ -250,6 +250,7 @@ tests = ["abs_workdir",
46 "inherit_toolset",
47 "inherited_dependency",
48 "inline",
49 + "install_build_no",
50 "libjpeg",
51 "liblzma",
52 "libpng",