summaryrefslogtreecommitdiffstats
path: root/src/boost/tools/build/test/toolset-mock
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/boost/tools/build/test/toolset-mock/Jamroot.jam8
-rw-r--r--src/boost/tools/build/test/toolset-mock/lib.cpp7
-rw-r--r--src/boost/tools/build/test/toolset-mock/main.cpp7
-rw-r--r--src/boost/tools/build/test/toolset-mock/project-config.jam43
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/Jamroot.jam61
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/MockProgram.py262
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/ar.py24
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/clang-3.9.0-darwin.py49
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/clang-linux-3.9.0.py48
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/clang-vxworks-4.0.1.py42
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/darwin-4.2.1.py38
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/gcc-4.2.1-darwin.py37
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/gcc-4.8.3-linux.py50
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/intel-darwin-10.2.py43
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/ld.py33
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/libtool.py14
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/mock-program.cpp42
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/project-config.jam5
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/ranlib.py22
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/strip.py13
-rw-r--r--src/boost/tools/build/test/toolset-mock/src/verify.py9
21 files changed, 857 insertions, 0 deletions
diff --git a/src/boost/tools/build/test/toolset-mock/Jamroot.jam b/src/boost/tools/build/test/toolset-mock/Jamroot.jam
new file mode 100644
index 000000000..fd5f7907b
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/Jamroot.jam
@@ -0,0 +1,8 @@
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+lib l1 : lib.cpp ;
+exe test : main.cpp l1 ;
diff --git a/src/boost/tools/build/test/toolset-mock/lib.cpp b/src/boost/tools/build/test/toolset-mock/lib.cpp
new file mode 100644
index 000000000..1ba30e32d
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/lib.cpp
@@ -0,0 +1,7 @@
+// Copyright (c) 2017 Steven Watanabe
+//
+// 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)
+
+int f() {}
diff --git a/src/boost/tools/build/test/toolset-mock/main.cpp b/src/boost/tools/build/test/toolset-mock/main.cpp
new file mode 100644
index 000000000..0fc8b9a75
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/main.cpp
@@ -0,0 +1,7 @@
+// Copyright (c) 2017 Steven Watanabe
+//
+// 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)
+
+int main() {}
diff --git a/src/boost/tools/build/test/toolset-mock/project-config.jam b/src/boost/tools/build/test/toolset-mock/project-config.jam
new file mode 100644
index 000000000..30a9e9415
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/project-config.jam
@@ -0,0 +1,43 @@
+# Copyright 2017 Steven Watanabe
+#
+# 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 modules ;
+import os ;
+
+path-constant here : . ;
+
+local PYTHON = [ os.environ PYTHON_CMD ] ;
+
+using gcc : 4.8.3 : $(PYTHON) $(here)/src/gcc-4.8.3-linux.py : : <target-os>linux ;
+using gcc : 4.2.1 : $(PYTHON) $(here)/src/gcc-4.2.1-darwin.py : : <target-os>darwin ;
+
+# hard-code this to make the test work on other platforms
+modules.poke darwin : .host-osx-version : 10.11.0 ;
+using darwin : 4.2.1 : $(PYTHON) $(here)/src/darwin-4.2.1.py
+ : <archiver>$(here)/src/bin/libtool
+ <striper>$(here)/src/bin/strip
+ : <target-os>darwin
+ ;
+
+using clang-darwin : 3.9.0 : $(PYTHON) $(here)/src/clang-3.9.0-darwin.py
+ : <archiver>$(here)/src/bin/ar
+ <ranlib>$(here)/src/bin/ranlib
+ ;
+
+using clang-linux : 3.9.0 : $(PYTHON) $(here)/src/clang-linux-3.9.0.py
+ : <archiver>$(here)/src/bin/ar
+ <ranlib>$(here)/src/bin/ranlib
+ ;
+
+using clang-vxworks : 4.0.1 : $(PYTHON) $(here)/src/clang-vxworks-4.0.1.py
+ : <linker>$(here)/src/bin/ld
+ <archiver>$(here)/src/bin/ar
+ ;
+
+using intel-darwin : 10.2 : $(PYTHON) $(here)/src/intel-darwin-10.2.py
+ : <archiver>$(here)/src/bin/ar
+ <ranlib>$(here)/src/bin/ranlib
+ ;
diff --git a/src/boost/tools/build/test/toolset-mock/src/Jamroot.jam b/src/boost/tools/build/test/toolset-mock/src/Jamroot.jam
new file mode 100644
index 000000000..c8fc0078b
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/Jamroot.jam
@@ -0,0 +1,61 @@
+# Copyright 2017 Steven Watanabe
+#
+# 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 print ;
+import regex ;
+import feature ;
+
+.PYTHON = [ os.environ PYTHON_CMD ] ;
+path-constant .AR : ar.py ;
+path-constant .RANLIB : ranlib.py ;
+path-constant .LIBTOOL : libtool.py ;
+path-constant .STRIP : strip.py ;
+path-constant .LD : ld.py ;
+
+rule c-escape ( str )
+{
+ return [ regex.replace $(str) \\\\ \\\\ ] ;
+}
+
+rule cfg-header ( target : : properties * )
+{
+ local PYTHON = [ c-escape $(.PYTHON) ] ;
+ local AR = [ c-escape $(.AR) ] ;
+ local RANLIB = [ c-escape $(.RANLIB) ] ;
+ local LIBTOOL = [ c-escape $(.LIBTOOL) ] ;
+ local STRIP = [ c-escape $(.STRIP) ] ;
+ local LD = [ c-escape $(.LD) ] ;
+ print.output $(target) ;
+ print.text "#define PYTHON_CMD "\"$(PYTHON)\" : true ;
+ print.text "#define AR_CMD "\"$(AR)\" : true ;
+ print.text "#define RANLIB_CMD "\"$(RANLIB)\" : true ;
+ print.text "#define LIBTOOL_CMD "\"$(LIBTOOL)\" : true ;
+ print.text "#define STRIP_CMD "\"$(STRIP)\" : true ;
+ print.text "#define LD_CMD "\"$(LD)\" : true ;
+}
+
+# We can only build one variant at a time and we need to have a fixed path
+project : requirements <location>bin ;
+
+make config.h : : @cfg-header ;
+
+project : requirements <implicit-dependency>config.h ;
+
+rule write-target-os ( target : : properties * )
+{
+ local target-os = [ feature.defaults <target-os> ] ;
+ print.output $(target) ;
+ print.text $(target-os:G=) : true ;
+}
+
+make target-os.txt : : @write-target-os ;
+
+exe ar : [ obj ar.obj : mock-program.cpp : <define>PY_SCRIPT=AR_CMD ] ;
+exe ranlib : [ obj ranlib.obj : mock-program.cpp : <define>PY_SCRIPT=RANLIB_CMD ] ;
+exe libtool : [ obj libtool.obj : mock-program.cpp : <define>PY_SCRIPT=LIBTOOL_CMD ] ;
+exe strip : [ obj strip.obj : mock-program.cpp : <define>PY_SCRIPT=STRIP_CMD ] ;
+exe ld : [ obj ld.obj : mock-program.cpp : <define>PY_SCRIPT=LD_CMD ] ;
diff --git a/src/boost/tools/build/test/toolset-mock/src/MockProgram.py b/src/boost/tools/build/test/toolset-mock/src/MockProgram.py
new file mode 100644
index 000000000..1ada7e2ad
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/MockProgram.py
@@ -0,0 +1,262 @@
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from __future__ import print_function
+
+import sys
+import os
+import re
+
+# Represents a sequence of arguments that must appear
+# in a fixed order.
+class ordered:
+ def __init__(self, *args):
+ self.args = args
+ def match(self, command_line, pos, outputs):
+ for p in self.args:
+ res = try_match(command_line, pos, p, outputs)
+ if res is None:
+ return
+ pos = res
+ return pos
+
+# Represents a sequence of arguments that can appear
+# in any order.
+class unordered:
+ def __init__(self, *args):
+ self.args = list(args)
+ def match(self, command_line, pos, outputs):
+ unmatched = self.args[:]
+ while len(unmatched) > 0:
+ res = try_match_one(command_line, pos, unmatched, outputs)
+ if res is None:
+ return
+ pos = res
+ return pos
+
+# Represents a single input file.
+# If id is set, then the file must have been created
+# by a prior use of output_file.
+# If source is set, then the file must be that source file.
+class input_file:
+ def __init__(self, id=None, source=None):
+ assert((id is None) ^ (source is None))
+ self.id = id
+ self.source = source
+ def check(self, path):
+ if path.startswith("-"):
+ return
+ if self.id is not None:
+ try:
+ with open(path, "r") as f:
+ data = f.read()
+ if data == make_file_contents(self.id):
+ return True
+ else:
+ return
+ except:
+ return
+ elif self.source is not None:
+ if self.source == path:
+ return True
+ else:
+ return
+ assert(False)
+ def match(self, command_line, pos, outputs):
+ if self.check(command_line[pos]):
+ return pos + 1
+
+# Matches an output file.
+# If the full pattern is matched, The
+# file will be created.
+class output_file:
+ def __init__(self, id):
+ self.id = id
+ def match(self, command_line, pos, outputs):
+ if command_line[pos].startswith("-"):
+ return
+ outputs.append((command_line[pos], self.id))
+ return pos + 1
+
+# Matches the directory containing an input_file
+class target_path(object):
+ def __init__(self, id):
+ self.tester = input_file(id=id)
+ def match(self, command_line, pos, outputs):
+ arg = command_line[pos]
+ if arg.startswith("-"):
+ return
+ try:
+ for path in os.listdir(arg):
+ if self.tester.check(os.path.join(arg, path)):
+ return pos + 1
+ except:
+ return
+
+# Matches a single argument, which is composed of a prefix and a path
+# for example arguments of the form -ofilename.
+class arg(object):
+ def __init__(self, prefix, a):
+ # The prefix should be a string, a should be target_path or input_file.
+ self.prefix = prefix
+ self.a = a
+ def match(self, command_line, pos, outputs):
+ s = command_line[pos]
+ if s.startswith(self.prefix) and try_match([s[len(self.prefix):]], 0, self.a, outputs) == 1:
+ return pos + 1
+
+# Given a file id, returns a string that will be
+# written to the file to allow it to be recognized.
+def make_file_contents(id):
+ return id
+
+# Matches a single pattern from a list.
+# If it succeeds, the matching pattern
+# is removed from the list.
+# Returns the index after the end of the match
+def try_match_one(command_line, pos, patterns, outputs):
+ for p in patterns:
+ tmp = outputs[:]
+ res = try_match(command_line, pos, p, tmp)
+ if res is not None:
+ outputs[:] = tmp
+ patterns.remove(p)
+ return res
+
+# returns the end of the match if any
+def try_match(command_line, pos, pattern, outputs):
+ if pos == len(command_line):
+ return
+ elif type(pattern) is str:
+ if pattern == command_line[pos]:
+ return pos + 1
+ else:
+ return pattern.match(command_line, pos, outputs)
+
+known_patterns = []
+program_name = None
+
+# Registers a command
+# The arguments should be a sequence of:
+# str, ordered, unordered, arg, input_file, output_file, target_path
+# kwarg: stdout is text that will be printed on success.
+def command(*args, **kwargs):
+ global known_patterns
+ global program_name
+ stdout = kwargs.get("stdout", None)
+ pattern = ordered(*args)
+ known_patterns += [(pattern, stdout)]
+ if program_name is None:
+ program_name = args[0]
+ else:
+ assert(program_name == args[0])
+
+# Use this to filter the recognized commands, based on the properties
+# passed to b2.
+def allow_properties(*args):
+ try:
+ return all(a in os.environ["B2_PROPERTIES"].split(" ") for a in args)
+ except KeyError:
+ return True
+
+# Use this in the stdout argument of command to print the command
+# for running another script.
+def script(name):
+ return os.path.join(os.path.dirname(__file__), "bin", re.sub('\.py$', '', name))
+
+def match(command_line):
+ for (p, stdout) in known_patterns:
+ outputs = []
+ if try_match(command_line, 0, p, outputs) == len(command_line):
+ return (stdout, outputs)
+
+# Every mock program should call this after setting up all the commands.
+def main():
+ command_line = [program_name] + sys.argv[1:]
+ result = match(command_line)
+ if result is not None:
+ (stdout, outputs) = result
+ if stdout is not None:
+ print(stdout)
+ for (file,id) in outputs:
+ with open(file, "w") as f:
+ f.write(make_file_contents(id))
+ exit(0)
+ else:
+ print(command_line)
+ exit(1)
+
+# file should be the name of a file in the same directory
+# as this. Must be called after verify_setup
+def verify_file(filename):
+ global known_files
+ if filename not in known_files:
+ known_files.add(filename)
+ srcdir = os.path.dirname(__file__)
+ execfile(os.path.join(srcdir, filename), {})
+
+def verify_setup():
+ """Override the behavior of most module components
+ in order to detect whether they are being used correctly."""
+ global main
+ global allow_properties
+ global output_file
+ global input_file
+ global target_path
+ global script
+ global command
+ global verify_errors
+ global output_ids
+ global input_ids
+ global known_files
+ def allow_properties(*args):
+ return True
+ def main():
+ pass
+ def output_file(id):
+ global output_ids
+ global verify_error
+ if id in output_ids:
+ verify_error("duplicate output_file: %s" % id)
+ output_ids.add(id)
+ def input_file(id=None, source=None):
+ if id is not None:
+ input_ids.add(id)
+ def target_path(id):
+ input_ids.add(id)
+ def script(filename):
+ verify_file(filename)
+ def command(*args, **kwargs):
+ pass
+ verify_errors = []
+ output_ids = set()
+ input_ids = set()
+ known_files = set()
+
+def verify_error(message):
+ global verify_errors
+ verify_errors += [message]
+
+def verify_finalize():
+ for id in input_ids:
+ if not id in output_ids:
+ verify_error("Input file does not exist: %s" % id)
+ for error in verify_errors:
+ print("error: %s" % error)
+ if len(verify_errors) != 0:
+ return 1
+ else:
+ return 0
+
+def verify():
+ srcdir = os.path.dirname(__file__)
+ if srcdir == '':
+ srcdir = '.'
+ verify_setup()
+ for f in os.listdir(srcdir):
+ if re.match(r"(gcc|clang|darwin|intel)-.*\.py", f):
+ verify_file(f)
+ exit(verify_finalize())
diff --git a/src/boost/tools/build/test/toolset-mock/src/ar.py b/src/boost/tools/build/test/toolset-mock/src/ar.py
new file mode 100644
index 000000000..853fe1dd8
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/ar.py
@@ -0,0 +1,24 @@
+#!/usr/bin/python
+#
+# Copyright 2017-2018 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('ar', 'rc', output_file('bin/gcc-gnu-4.8.3/debug/link-static/libl1.a'), input_file('bin/gcc-gnu-4.8.3/debug/link-static/lib.o'))
+command('ar', 'rc', output_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/libl1.a'), input_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/lib.o'))
+command('ar', 'rc', output_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/libl1.a'), input_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/lib.o'))
+command('ar', 'rc', output_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), input_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/lib.o'))
+command('ar', 'rc', output_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/libl1.a'), input_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/lib.o'))
+command('ar', 'rc', output_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), input_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/lib.o'))
+command('ar', 'rc', output_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/libl1.a'), input_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/lib.o'))
+command('ar', 'rc', output_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), input_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/lib.o'))
+command('ar', 'rc', output_file('bin/clang-linux-3.9.0/debug/link-static/libl1.a'), input_file('bin/clang-linux-3.9.0/debug/link-static/lib.o'))
+command('ar', 'rc', output_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/libl1.a'), input_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/lib.o'))
+command('ar', 'rcu', output_file('bin/clang-vxworks-4.0.1/debug/link-static/libl1.a'), input_file('bin/clang-vxworks-4.0.1/debug/link-static/lib.o'))
+command('ar', 'rcu', output_file('bin/clang-vxworks-4.0.1/debug/link-static/runtime-link-static/libl1.a'), input_file('bin/clang-vxworks-4.0.1/debug/link-static/runtime-link-static/lib.o'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/clang-3.9.0-darwin.py b/src/boost/tools/build/test/toolset-mock/src/clang-3.9.0-darwin.py
new file mode 100644
index 000000000..d8c2163ab
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/clang-3.9.0-darwin.py
@@ -0,0 +1,49 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('clang++', '-print-prog-name=ar', stdout=script('ar.py'))
+command('clang++', '-print-prog-name=ranlib', stdout=script('ranlib.py'))
+
+# all builds are multi-threaded for darwin
+if allow_properties("variant=debug", "link=shared", "runtime-link=shared"):
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-fPIC'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/libl1.dylib'), '-single_module', '-dynamiclib', '-install_name', '@rpath/libl1.dylib', input_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/lib.o'), unordered('-g', '-fPIC'))
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-fPIC'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/test'), input_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/main.o'), input_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/libl1.dylib'), unordered('-g', '-fPIC'))
+
+if allow_properties("variant=release", "link=shared", "runtime-link=shared"):
+ command('clang++', '-x', 'c++', unordered('-O3', '-Wno-inline', '-Wall', '-fPIC'), '-DNDEBUG', '-c', '-o', output_file('bin/clang-darwin-3.9.0/release/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-v', '-o', output_file('bin/clang-darwin-3.9.0/release/target-os-darwin/libl1.dylib'), '-single_module', '-dynamiclib', '-install_name', '@rpath/libl1.dylib', input_file('bin/clang-darwin-3.9.0/release/target-os-darwin/lib.o'), '-fPIC')
+ command('clang++', '-x', 'c++', unordered('-O3', '-Wno-inline', '-Wall', '-fPIC'), '-DNDEBUG', '-c', '-o', output_file('bin/clang-darwin-3.9.0/release/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-v', '-o', output_file('bin/clang-darwin-3.9.0/release/target-os-darwin/test'), input_file('bin/clang-darwin-3.9.0/release/target-os-darwin/main.o'), input_file('bin/clang-darwin-3.9.0/release/target-os-darwin/libl1.dylib'), '-fPIC')
+
+if allow_properties("variant=debug", "link=static", "runtime-link=shared"):
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/test'), input_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/main.o'), input_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/libl1.a'), '-g')
+
+if allow_properties("variant=debug", "link=static", "runtime-link=static"):
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/test'), input_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), unordered('-g', '-static'))
+
+if allow_properties("variant=debug", "link=shared", "runtime-link=shared", "architecture=x86", "address-model=32"):
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-march=i686', '-fPIC', '-m32'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/x86/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/x86/target-os-darwin/libl1.dylib'), '-single_module', '-dynamiclib', '-install_name', '@rpath/libl1.dylib', input_file('bin/clang-darwin-3.9.0/debug/x86/target-os-darwin/lib.o'), unordered('-g', '-march=i686', '-fPIC', '-m32'))
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-march=i686', '-fPIC', '-m32'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/x86/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/x86/target-os-darwin/test'), input_file('bin/clang-darwin-3.9.0/debug/x86/target-os-darwin/main.o'), input_file('bin/clang-darwin-3.9.0/debug/x86/target-os-darwin/libl1.dylib'), unordered('-g', '-march=i686', '-fPIC', '-m32'))
+
+if allow_properties("variant=debug", "link=shared", "runtime-link=shared", "cxxstd=latest"):
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-std=c++1z'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/libl1.dylib'), '-single_module', '-dynamiclib', '-install_name', '@rpath/libl1.dylib', input_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/lib.o'), unordered('-g', '-fPIC', '-std=c++1z'))
+ command('clang++', '-x', 'c++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-std=c++1z'), '-c', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-o', output_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/test'), input_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/main.o'), input_file('bin/clang-darwin-3.9.0/debug/target-os-darwin/libl1.dylib'), unordered('-g', '-fPIC', '-std=c++1z'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/clang-linux-3.9.0.py b/src/boost/tools/build/test/toolset-mock/src/clang-linux-3.9.0.py
new file mode 100644
index 000000000..242d25624
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/clang-linux-3.9.0.py
@@ -0,0 +1,48 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('clang++', '-print-prog-name=ar', stdout=script('ar.py'))
+command('clang++', '-print-prog-name=ranlib', stdout=script('ranlib.py'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=single', 'runtime-link=shared'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-o', output_file('bin/clang-linux-3.9.0/debug/libl1.so'), '-Wl,-soname', '-Wl,libl1.so', '-shared', '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/lib.o'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', unordered('-g', '-fPIC'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-Wl,-R', arg('-Wl,', target_path('bin/clang-linux-3.9.0/debug/libl1.so')), '-Wl,-rpath-link', arg('-Wl,', target_path('bin/clang-linux-3.9.0/debug/libl1.so')), '-o', output_file('bin/clang-linux-3.9.0/debug/test'), '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/main.o'), input_file('bin/clang-linux-3.9.0/debug/libl1.so'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', unordered('-g', '-fPIC'))
+
+if allow_properties('variant=release', 'link=shared', 'threading=single', 'runtime-link=shared', 'strip=on'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O3', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG', '-c'), '-o', output_file('bin/clang-linux-3.9.0/release/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-o', output_file('bin/clang-linux-3.9.0/release/libl1.so'), '-Wl,-soname', '-Wl,libl1.so', '-shared', '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/release/lib.o'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', unordered('-fPIC', '-Wl,--strip-all'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O3', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG', '-c'), '-o', output_file('bin/clang-linux-3.9.0/release/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-Wl,-R', arg('-Wl,', target_path('bin/clang-linux-3.9.0/release/libl1.so')), '-Wl,-rpath-link', arg('-Wl,', target_path('bin/clang-linux-3.9.0/release/libl1.so')), '-o', output_file('bin/clang-linux-3.9.0/release/test'), '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/release/main.o'), input_file('bin/clang-linux-3.9.0/release/libl1.so'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', unordered('-fPIC', '-Wl,--strip-all'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=multi', 'runtime-link=shared'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-pthread', '-fPIC', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/threading-multi/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-o', output_file('bin/clang-linux-3.9.0/debug/threading-multi/libl1.so'), '-Wl,-soname', '-Wl,libl1.so', '-shared', '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/threading-multi/lib.o'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-lrt', '-Wl,--end-group', unordered('-g', '-pthread', '-fPIC'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-pthread', '-fPIC', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/threading-multi/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-Wl,-R', arg('-Wl,', target_path('bin/clang-linux-3.9.0/debug/threading-multi/libl1.so')), '-Wl,-rpath-link', arg('-Wl,', target_path('bin/clang-linux-3.9.0/debug/threading-multi/libl1.so')), '-o', output_file('bin/clang-linux-3.9.0/debug/threading-multi/test'), '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/threading-multi/main.o'), input_file('bin/clang-linux-3.9.0/debug/threading-multi/libl1.so'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-lrt', '-Wl,--end-group', unordered('-g', '-pthread', '-fPIC'))
+
+if allow_properties('variant=debug', 'link=static', 'threading=single', 'runtime-link=shared'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/link-static/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/link-static/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-o', output_file('bin/clang-linux-3.9.0/debug/link-static/test'), '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/link-static/main.o'), input_file('bin/clang-linux-3.9.0/debug/link-static/libl1.a'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', '-g')
+
+if allow_properties('variant=debug', 'link=static', 'threading=single', 'runtime-link=static'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-o', output_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/test'), '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/main.o'), input_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/libl1.a'), '-Wl,--end-group', unordered('-g', '-static'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=single', 'runtime-link=shared', 'architecture=x86', 'address-model=32'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-march=i686', '-m32', '-fPIC', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', '-o', output_file('bin/clang-linux-3.9.0/debug/libl1.so'), '-Wl,-soname', '-Wl,libl1.so', '-shared', '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/lib.o'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', unordered('-g', '-march=i686', '-fPIC', '-m32'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-march=i686', '-m32', '-fPIC', '-c'), '-o', output_file('bin/clang-linux-3.9.0/debug/main.o'), input_file(source='main.cpp'))
+ command('clang++', '-Wl,-R', arg('-Wl,', target_path('bin/clang-linux-3.9.0/debug/libl1.so')), '-Wl,-rpath-link', arg('-Wl,', target_path('bin/clang-linux-3.9.0/debug/libl1.so')), '-o', output_file('bin/clang-linux-3.9.0/debug/test'), '-Wl,--start-group', input_file('bin/clang-linux-3.9.0/debug/main.o'), input_file('bin/clang-linux-3.9.0/debug/libl1.so'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', unordered('-g', '-march=i686', '-fPIC', '-m32'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/clang-vxworks-4.0.1.py b/src/boost/tools/build/test/toolset-mock/src/clang-vxworks-4.0.1.py
new file mode 100644
index 000000000..a1fbedb11
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/clang-vxworks-4.0.1.py
@@ -0,0 +1,42 @@
+#!/usr/bin/python
+#
+# Copyright 2018 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('clang++', '-print-prog-name=ar', stdout=script('ar.py'))
+command('clang++', '-print-prog-name=ranlib', stdout=script('ranlib.py'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=single', 'runtime-link=shared'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/main.o'), input_file(source='main.cpp'))
+
+if allow_properties('variant=release', 'link=shared', 'threading=single', 'runtime-link=shared', 'strip=on'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O3', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/release/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O3', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/release/main.o'), input_file(source='main.cpp'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=multi', 'runtime-link=shared'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/threading-multi/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-fPIC', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/threading-multi/main.o'), input_file(source='main.cpp'))
+
+if allow_properties('variant=debug', 'link=static', 'threading=single', 'runtime-link=shared'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/link-static/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/link-static/main.o'), input_file(source='main.cpp'))
+
+if allow_properties('variant=debug', 'link=static', 'threading=single', 'runtime-link=static'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/link-static/runtime-link-static/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/link-static/runtime-link-static/main.o'), input_file(source='main.cpp'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=single', 'runtime-link=shared', 'architecture=x86', 'address-model=32'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-march=i686', '-m32', '-fPIC', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-Wall', '-g', '-march=i686', '-m32', '-fPIC', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/main.o'), input_file(source='main.cpp'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=single', 'runtime-link=shared', 'rtti=off', 'exception-handling=off'):
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-fno-rtti', '-fno-exceptions', '-Wall', '-g', '-fPIC', '-D_NO_RTTI', '-D_NO_EX=1', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/lib.o'), input_file(source='lib.cpp'))
+ command('clang++', unordered(ordered('-x', 'c++'), '-O0', '-fno-inline', '-fno-rtti', '-fno-exceptions', '-Wall', '-g', '-fPIC', '-D_NO_RTTI', '-D_NO_EX=1', '-c'), '-o', output_file('bin/clang-vxworks-4.0.1/debug/main.o'), input_file(source='main.cpp'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/darwin-4.2.1.py b/src/boost/tools/build/test/toolset-mock/src/darwin-4.2.1.py
new file mode 100644
index 000000000..d81359ca5
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/darwin-4.2.1.py
@@ -0,0 +1,38 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+script("libtool.py")
+
+command('g++', '-dumpversion', stdout='4.2.1')
+
+# all builds are multi-threaded for darwin
+if allow_properties("variant=debug", "link=shared", "runtime-link=shared"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-dynamic', '-gdwarf-2', '-fexceptions', '-fPIC'), '-c', '-o', output_file('bin/darwin-4.2.1/debug/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', '-dynamiclib', '-Wl,-single_module', '-install_name', 'libl1.dylib', '-o', output_file('bin/darwin-4.2.1/debug/target-os-darwin/libl1.dylib'), input_file('bin/darwin-4.2.1/debug/target-os-darwin/lib.o'), '-headerpad_max_install_names', unordered('-g', '-fPIC'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-dynamic', '-gdwarf-2', '-fexceptions', '-fPIC'), '-c', '-o', output_file('bin/darwin-4.2.1/debug/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/darwin-4.2.1/debug/target-os-darwin/test'), input_file('bin/darwin-4.2.1/debug/target-os-darwin/main.o'), input_file('bin/darwin-4.2.1/debug/target-os-darwin/libl1.dylib'), unordered('-g', '-fPIC'))
+
+if allow_properties("variant=release", "link=shared", "runtime-link=shared"):
+ command('g++', unordered('-O3', '-Wno-inline', '-Wall', '-dynamic', '-gdwarf-2', '-fexceptions', '-fPIC'), '-DNDEBUG', '-c', '-o', output_file('bin/darwin-4.2.1/release/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', '-dynamiclib', '-Wl,-single_module', '-install_name', 'libl1.dylib', '-o', output_file('bin/darwin-4.2.1/release/target-os-darwin/libl1.dylib'), input_file('bin/darwin-4.2.1/release/target-os-darwin/lib.o'), '-headerpad_max_install_names', unordered(ordered('-Wl,-dead_strip', '-no_dead_strip_inits_and_terms'), '-fPIC'))
+ command('g++', unordered('-O3', '-Wno-inline', '-Wall', '-dynamic', '-gdwarf-2', '-fexceptions', '-fPIC'), '-DNDEBUG', '-c', '-o', output_file('bin/darwin-4.2.1/release/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/darwin-4.2.1/release/target-os-darwin/test'), input_file('bin/darwin-4.2.1/release/target-os-darwin/main.o'), input_file('bin/darwin-4.2.1/release/target-os-darwin/libl1.dylib'), unordered(ordered('-Wl,-dead_strip', '-no_dead_strip_inits_and_terms'), '-fPIC'))
+
+if allow_properties("variant=debug", "link=static", "runtime-link=shared"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-gdwarf-2', '-fexceptions'), '-c', '-o', output_file('bin/darwin-4.2.1/debug/link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-gdwarf-2', '-fexceptions'), '-c', '-o', output_file('bin/darwin-4.2.1/debug/link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/darwin-4.2.1/debug/link-static/target-os-darwin/test'), input_file('bin/darwin-4.2.1/debug/link-static/target-os-darwin/main.o'), input_file('bin/darwin-4.2.1/debug/link-static/target-os-darwin/libl1.a'), '-g')
+
+if allow_properties("variant=debug", "link=static", "runtime-link=static"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-gdwarf-2', '-fexceptions'), '-c', '-o', output_file('bin/darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-gdwarf-2', '-fexceptions'), '-c', '-o', output_file('bin/darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/test'), input_file('bin/darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file('bin/darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), unordered('-g', ordered('-nodefaultlibs', '-shared-libgcc', '-lstdc++-static', '-lgcc_eh', '-lgcc', '-lSystem'), '-static'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/gcc-4.2.1-darwin.py b/src/boost/tools/build/test/toolset-mock/src/gcc-4.2.1-darwin.py
new file mode 100644
index 000000000..76058c320
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/gcc-4.2.1-darwin.py
@@ -0,0 +1,37 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('g++', '-print-prog-name=ar', stdout=script('ar.py'))
+command('g++', '-print-prog-name=ranlib', stdout=script('ranlib.py'))
+
+# all builds are multi-threaded for darwin
+if allow_properties("variant=debug", "link=shared", "runtime-link=shared"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-fPIC'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/debug/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', '-o', output_file('bin/gcc-darwin-4.2.1/debug/target-os-darwin/libl1.dylib'), '-shared', input_file('bin/gcc-darwin-4.2.1/debug/target-os-darwin/lib.o'), unordered('-g', '-fPIC'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-fPIC'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/debug/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-Wl,-rpath', arg('-Wl,', target_path('bin/gcc-darwin-4.2.1/debug/target-os-darwin/libl1.dylib')), '-o', output_file('bin/gcc-darwin-4.2.1/debug/target-os-darwin/test'), input_file('bin/gcc-darwin-4.2.1/debug/target-os-darwin/main.o'), input_file('bin/gcc-darwin-4.2.1/debug/target-os-darwin/libl1.dylib'), unordered('-g', '-fPIC'))
+
+if allow_properties("variant=release", "link=shared", "runtime-link=shared"):
+ command('g++', unordered('-O3', '-finline-functions', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/release/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', '-o', output_file('bin/gcc-darwin-4.2.1/release/target-os-darwin/libl1.dylib'), '-shared', input_file('bin/gcc-darwin-4.2.1/release/target-os-darwin/lib.o'), '-fPIC')
+ command('g++', unordered('-O3', '-finline-functions', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/release/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-Wl,-rpath', arg('-Wl,', target_path('bin/gcc-darwin-4.2.1/release/target-os-darwin/libl1.dylib')), '-o', output_file('bin/gcc-darwin-4.2.1/release/target-os-darwin/test'), input_file('bin/gcc-darwin-4.2.1/release/target-os-darwin/main.o'), input_file('bin/gcc-darwin-4.2.1/release/target-os-darwin/libl1.dylib'), '-fPIC')
+
+if allow_properties("variant=debug", "link=static", "runtime-link=shared"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/test'), input_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/main.o'), input_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/libl1.a'), '-g')
+
+if allow_properties("variant=debug", "link=static", "runtime-link=static"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/test'), input_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), unordered('-g', '-static'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/gcc-4.8.3-linux.py b/src/boost/tools/build/test/toolset-mock/src/gcc-4.8.3-linux.py
new file mode 100644
index 000000000..5604ee5d1
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/gcc-4.8.3-linux.py
@@ -0,0 +1,50 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('g++', '-print-prog-name=ar', stdout=script('ar.py'))
+command('g++', '-print-prog-name=ranlib', stdout=script('ranlib.py'))
+
+if allow_properties("variant=debug", "link=shared", "threading=single", "runtime-link=shared"):
+ command("g++", unordered("-O0", "-fno-inline", "-Wall", "-g", "-fPIC"), "-c", "-o", output_file("bin/gcc-gnu-4.8.3/debug/lib.o"), input_file(source="lib.cpp"))
+ command("g++", "-o", output_file("bin/gcc-gnu-4.8.3/debug/libl1.so"), "-Wl,-h", "-Wl,libl1.so", "-shared", "-Wl,--start-group", input_file("bin/gcc-gnu-4.8.3/debug/lib.o"), "-Wl,-Bstatic", "-Wl,-Bdynamic", "-Wl,--end-group", unordered("-g", "-fPIC"))
+ command("g++", unordered("-O0", "-fno-inline", "-Wall", "-g", "-fPIC"), "-c", "-o", output_file("bin/gcc-gnu-4.8.3/debug/main.o"), input_file(source="main.cpp"))
+ command("g++", "-Wl,-rpath", arg("-Wl,", target_path("bin/gcc-gnu-4.8.3/debug/libl1.so")), "-Wl,-rpath-link", arg("-Wl,", target_path("bin/gcc-gnu-4.8.3/debug/libl1.so")), "-o", output_file("bin/gcc-gnu-4.8.3/debug/test"), "-Wl,--start-group", input_file("bin/gcc-gnu-4.8.3/debug/main.o"), input_file("bin/gcc-gnu-4.8.3/debug/libl1.so"), "-Wl,-Bstatic", "-Wl,-Bdynamic", "-Wl,--end-group", unordered("-g", "-fPIC"))
+
+if allow_properties("variant=release", "link=shared", "threading=single", "runtime-link=shared"):
+ command('g++', unordered('-O3', '-finline-functions', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG'), '-c', '-o', output_file('bin/gcc-gnu-4.8.3/release/lib.o'), input_file(source='lib.cpp'))
+ command('g++', '-o', output_file('bin/gcc-gnu-4.8.3/release/libl1.so'), '-Wl,-h', '-Wl,libl1.so', '-shared', '-Wl,--start-group', input_file('bin/gcc-gnu-4.8.3/release/lib.o'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', '-fPIC')
+ command('g++', unordered('-O3', '-finline-functions', '-Wno-inline', '-Wall', '-fPIC', '-DNDEBUG'), '-c', '-o', output_file('bin/gcc-gnu-4.8.3/release/main.o'), input_file(source='main.cpp'))
+ command('g++', '-Wl,-rpath', arg('-Wl,', target_path('bin/gcc-gnu-4.8.3/release/libl1.so')), '-Wl,-rpath-link', arg('-Wl,', target_path('bin/gcc-gnu-4.8.3/release/libl1.so')), '-o', output_file('bin/gcc-gnu-4.8.3/release/test'), '-Wl,--start-group', input_file('bin/gcc-gnu-4.8.3/release/main.o'), input_file('bin/gcc-gnu-4.8.3/release/libl1.so'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', '-fPIC')
+
+if allow_properties("variant=debug", "link=shared", "threading=multi", "runtime-link=shared"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-pthread', '-fPIC'), '-c', '-o', output_file('bin/gcc-gnu-4.8.3/debug/threading-multi/lib.o'), input_file(source='lib.cpp'))
+ command('g++', '-o', output_file('bin/gcc-gnu-4.8.3/debug/threading-multi/libl1.so'), '-Wl,-h', '-Wl,libl1.so', '-shared', '-Wl,--start-group', input_file('bin/gcc-gnu-4.8.3/debug/threading-multi/lib.o'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-lrt', '-Wl,--end-group', unordered('-g', '-pthread', '-fPIC'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-pthread', '-fPIC'), '-c', '-o', output_file('bin/gcc-gnu-4.8.3/debug/threading-multi/main.o'), input_file(source='main.cpp'))
+ command('g++', '-Wl,-rpath', arg('-Wl,', target_path('bin/gcc-gnu-4.8.3/debug/threading-multi/libl1.so')), '-Wl,-rpath-link', arg('-Wl,', target_path('bin/gcc-gnu-4.8.3/debug/threading-multi/libl1.so')), '-o', output_file('bin/gcc-gnu-4.8.3/debug/threading-multi/test'), '-Wl,--start-group', input_file('bin/gcc-gnu-4.8.3/debug/threading-multi/main.o'), input_file('bin/gcc-gnu-4.8.3/debug/threading-multi/libl1.so'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-lrt', '-Wl,--end-group', unordered('-g', '-pthread', '-fPIC'))
+
+if allow_properties("variant=debug", "link=static", "threading=single", "runtime-link=shared"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/gcc-gnu-4.8.3/debug/link-static/lib.o'), input_file(source='lib.cpp'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g'), '-c', '-o', output_file('bin/gcc-gnu-4.8.3/debug/link-static/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/gcc-gnu-4.8.3/debug/link-static/test'), '-Wl,--start-group', input_file('bin/gcc-gnu-4.8.3/debug/link-static/main.o'), input_file('bin/gcc-gnu-4.8.3/debug/link-static/libl1.a'), '-Wl,-Bstatic', '-Wl,-Bdynamic', '-Wl,--end-group', '-g')
+
+if allow_properties("variant=debug", "link=static", "threading=single", "runtime-link=static"):
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/lib.o'), input_file(source='lib.cpp'))
+ command('g++', unordered('-O0', '-fno-inline', '-Wall', '-g', '-c'), '-o', output_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/main.o'), input_file(source='main.cpp'))
+ command('g++', '-o', output_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/test'), '-Wl,--start-group', input_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/main.o'), input_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/libl1.a'), '-Wl,--end-group', unordered('-g', '-static'))
+
+
+if allow_properties("variant=debug", "link=shared", "threading=single", "runtime-link=shared"):
+ command("g++", unordered("-O0", "-fno-inline", "-Wall", "-g", "-fPIC", "-std=c++1y"), "-c", "-o", output_file("bin/gcc-gnu-4.8.3/debug/lib.o"), input_file(source="lib.cpp"))
+ command("g++", "-o", output_file("bin/gcc-gnu-4.8.3/debug/libl1.so"), "-Wl,-h", "-Wl,libl1.so", "-shared", "-Wl,--start-group", input_file("bin/gcc-gnu-4.8.3/debug/lib.o"), "-Wl,-Bstatic", "-Wl,-Bdynamic", "-Wl,--end-group", unordered("-g", "-fPIC", "-std=c++1y"))
+ command("g++", unordered("-O0", "-fno-inline", "-Wall", "-g", "-fPIC", "-std=c++1y"), "-c", "-o", output_file("bin/gcc-gnu-4.8.3/debug/main.o"), input_file(source="main.cpp"))
+ command("g++", "-Wl,-rpath", arg("-Wl,", target_path("bin/gcc-gnu-4.8.3/debug/libl1.so")), "-Wl,-rpath-link", arg("-Wl,", target_path("bin/gcc-gnu-4.8.3/debug/libl1.so")), "-o", output_file("bin/gcc-gnu-4.8.3/debug/test"), "-Wl,--start-group", input_file("bin/gcc-gnu-4.8.3/debug/main.o"), input_file("bin/gcc-gnu-4.8.3/debug/libl1.so"), "-Wl,-Bstatic", "-Wl,-Bdynamic", "-Wl,--end-group", unordered("-g", "-fPIC", "-std=c++1y"))
+
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/intel-darwin-10.2.py b/src/boost/tools/build/test/toolset-mock/src/intel-darwin-10.2.py
new file mode 100644
index 000000000..314d6c458
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/intel-darwin-10.2.py
@@ -0,0 +1,43 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('icc', '-print-prog-name=ar', stdout=script('ar.py'))
+command('icc', '-print-prog-name=ranlib', stdout=script('ranlib.py'))
+
+# all builds are multi-threaded for darwin
+if allow_properties("variant=debug", "link=shared", "runtime-link=shared"):
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0', '-fPIC'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/debug/target-os-darwin/libl1.dylib'), '-single_module', '-dynamiclib', '-install_name', 'libl1.dylib', input_file('bin/intel-darwin-10.2/debug/target-os-darwin/lib.o'), unordered('-g', ordered('-shared-intel', '-lstdc++', '-lpthread'), '-fPIC'))
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0', '-fPIC'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/debug/target-os-darwin/test'), input_file('bin/intel-darwin-10.2/debug/target-os-darwin/main.o'), input_file('bin/intel-darwin-10.2/debug/target-os-darwin/libl1.dylib'), unordered('-g', ordered('-shared-intel', '-lstdc++', '-lpthread'), '-fPIC'))
+
+if allow_properties("variant=release", "link=shared", "runtime-link=shared"):
+ command('icc', '-xc++', unordered('-O3', '-inline-level=2', '-w1', '-vec-report0', '-fPIC'), '-DNDEBUG', '-c', '-o', output_file('bin/intel-darwin-10.2/release/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/release/target-os-darwin/libl1.dylib'), '-single_module', '-dynamiclib', '-install_name', 'libl1.dylib', input_file('bin/intel-darwin-10.2/release/target-os-darwin/lib.o'), unordered(ordered('-shared-intel', '-lstdc++', '-lpthread'), '-fPIC'))
+ command('icc', '-xc++', unordered('-O3', '-inline-level=2', '-w1', '-vec-report0', '-fPIC'), '-DNDEBUG', '-c', '-o', output_file('bin/intel-darwin-10.2/release/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/release/target-os-darwin/test'), input_file('bin/intel-darwin-10.2/release/target-os-darwin/main.o'), input_file('bin/intel-darwin-10.2/release/target-os-darwin/libl1.dylib'), unordered(ordered('-shared-intel', '-lstdc++', '-lpthread'), '-fPIC'))
+
+if allow_properties("variant=debug", "link=static", "runtime-link=shared"):
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/test'), input_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/main.o'), input_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/libl1.a'), '-g', ordered('-shared-intel', '-lstdc++', '-lpthread'))
+
+if allow_properties("variant=debug", "link=static", "runtime-link=static"):
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/test'), input_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/main.o'), input_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), unordered('-g', ordered('-static', '-static-intel', '-lstdc++', '-lpthread'), '-static'))
+
+if allow_properties("variant=debug", "link=shared", "runtime-link=shared", "architecture=x86", "address-model=32"):
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0', '-march=i686', '-fPIC', '-m32'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/x86/target-os-darwin/lib.o'), input_file(source='lib.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/debug/x86/target-os-darwin/libl1.dylib'), '-single_module', '-dynamiclib', '-install_name', 'libl1.dylib', input_file('bin/intel-darwin-10.2/debug/x86/target-os-darwin/lib.o'), unordered('-g', ordered('-shared-intel', '-lstdc++', '-lpthread'), '-march=i686', '-fPIC', '-m32'))
+ command('icc', '-xc++', unordered('-O0', '-inline-level=0', '-w1', '-g', '-vec-report0', '-march=i686', '-fPIC', '-m32'), '-c', '-o', output_file('bin/intel-darwin-10.2/debug/x86/target-os-darwin/main.o'), input_file(source='main.cpp'))
+ command('icc', '-o', output_file('bin/intel-darwin-10.2/debug/x86/target-os-darwin/test'), input_file('bin/intel-darwin-10.2/debug/x86/target-os-darwin/main.o'), input_file('bin/intel-darwin-10.2/debug/x86/target-os-darwin/libl1.dylib'), unordered('-g', ordered('-shared-intel', '-lstdc++', '-lpthread'), '-march=i686', '-fPIC', '-m32'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/ld.py b/src/boost/tools/build/test/toolset-mock/src/ld.py
new file mode 100644
index 000000000..2b644e501
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/ld.py
@@ -0,0 +1,33 @@
+#!/usr/bin/python
+#
+# Copyright 2018 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+if allow_properties('variant=debug', 'link=shared', 'threading=single', 'runtime-link=shared'):
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/libl1.so'), input_file('bin/clang-vxworks-4.0.1/debug/lib.o'), unordered('-g', '-fPIC'), '-fpic', '-shared', '-non-static')
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/test'), input_file('bin/clang-vxworks-4.0.1/debug/main.o'), input_file('bin/clang-vxworks-4.0.1/debug/libl1.so'), unordered('-g', '-fPIC'))
+
+if allow_properties('variant=release', 'link=shared', 'threading=single', 'runtime-link=shared', 'strip=on'):
+ command('ld', '-t', '-o', output_file('bin/clang-vxworks-4.0.1/release/libl1.so'), input_file('bin/clang-vxworks-4.0.1/release/lib.o'), unordered('-fPIC', '-Wl,--strip-all'), '-fpic', '-shared', '-non-static')
+ command('ld', '-t', '-o', output_file('bin/clang-vxworks-4.0.1/release/test'), input_file('bin/clang-vxworks-4.0.1/release/main.o'), input_file('bin/clang-vxworks-4.0.1/release/libl1.so'), unordered('-fPIC', '-Wl,--strip-all'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=multi', 'runtime-link=shared'):
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/threading-multi/libl1.so'), input_file('bin/clang-vxworks-4.0.1/debug/threading-multi/lib.o'), unordered('-g', '-fPIC'), '-fpic', '-shared', '-non-static')
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/threading-multi/test'), input_file('bin/clang-vxworks-4.0.1/debug/threading-multi/main.o'), input_file('bin/clang-vxworks-4.0.1/debug/threading-multi/libl1.so'), unordered('-g', '-fPIC'))
+
+if allow_properties('variant=debug', 'link=static', 'threading=single', 'runtime-link=shared'):
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/link-static/test'), input_file('bin/clang-vxworks-4.0.1/debug/link-static/main.o'), input_file('bin/clang-vxworks-4.0.1/debug/link-static/libl1.a'), '-g')
+
+if allow_properties('variant=debug', 'link=static', 'threading=single', 'runtime-link=static'):
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/link-static/runtime-link-static/test'), input_file('bin/clang-vxworks-4.0.1/debug/link-static/runtime-link-static/main.o'), input_file('bin/clang-vxworks-4.0.1/debug/link-static/runtime-link-static/libl1.a'), unordered('-g'))
+
+if allow_properties('variant=debug', 'link=shared', 'threading=single', 'runtime-link=shared', 'architecture=x86', 'address-model=32'):
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/libl1.so'), input_file('bin/clang-vxworks-4.0.1/debug/lib.o'), unordered('-g', '-march=i686', '-fPIC', '-m32'), '-fpic', '-shared', '-non-static')
+ command('ld', '-o', output_file('bin/clang-vxworks-4.0.1/debug/test'), input_file('bin/clang-vxworks-4.0.1/debug/main.o'), input_file('bin/clang-vxworks-4.0.1/debug/libl1.so'), unordered('-g', '-march=i686', '-fPIC', '-m32'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/libtool.py b/src/boost/tools/build/test/toolset-mock/src/libtool.py
new file mode 100644
index 000000000..9f58dc96d
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/libtool.py
@@ -0,0 +1,14 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('libtool', '-static', '-o', output_file('bin/darwin-4.2.1/debug/link-static/target-os-darwin/libl1.a'), input_file('bin/darwin-4.2.1/debug/link-static/target-os-darwin/lib.o'))
+command('libtool', '-static', '-o', output_file('bin/darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'), input_file('bin/darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/lib.o'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/mock-program.cpp b/src/boost/tools/build/test/toolset-mock/src/mock-program.cpp
new file mode 100644
index 000000000..62dd4b8a4
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/mock-program.cpp
@@ -0,0 +1,42 @@
+// mock-program.cpp
+//
+// Copyright (c) 2017 Steven Watanabe
+//
+// 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)
+
+// This program does nothing except to exec a python script
+
+#include <vector>
+#include <iostream>
+#include <stdio.h>
+#include "config.h"
+
+#if defined(_WIN32)
+ #include <process.h>
+ #define execv _execv
+#else
+ #include <unistd.h>
+#endif
+
+#ifndef PY_SCRIPT
+#error PY_SCRIPT must be defined to the absolute path to the script to run
+#endif
+
+#ifndef PYTHON_CMD
+#error PYTHON_CMD must be defined to the absolute path to the python interpreter
+#endif
+
+int main(int argc, char ** argv)
+{
+ std::vector<char *> args;
+ char python_cmd[] = PYTHON_CMD;
+ char script[] = PY_SCRIPT;
+ args.push_back(python_cmd);
+ args.push_back(script);
+ args.insert(args.end(), argv + 1, argv + argc);
+ args.push_back(NULL);
+ execv(python_cmd, &args[0]);
+ perror("exec");
+}
diff --git a/src/boost/tools/build/test/toolset-mock/src/project-config.jam b/src/boost/tools/build/test/toolset-mock/src/project-config.jam
new file mode 100644
index 000000000..73dcf42df
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/project-config.jam
@@ -0,0 +1,5 @@
+# Copyright 2017 Steven Watanabe
+#
+# 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)
diff --git a/src/boost/tools/build/test/toolset-mock/src/ranlib.py b/src/boost/tools/build/test/toolset-mock/src/ranlib.py
new file mode 100644
index 000000000..4abe21ed0
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/ranlib.py
@@ -0,0 +1,22 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('ranlib', input_file('bin/gcc-gnu-4.8.3/debug/link-static/libl1.a'))
+command('ranlib', input_file('bin/gcc-gnu-4.8.3/debug/link-static/runtime-link-static/libl1.a'))
+command('ranlib', input_file('bin/gcc-darwin-4.2.1/debug/link-static/target-os-darwin/libl1.a'))
+command('ranlib', input_file('bin/gcc-darwin-4.2.1/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'))
+command('ranlib', input_file('bin/clang-darwin-3.9.0/debug/link-static/target-os-darwin/libl1.a'))
+command('ranlib', input_file('bin/clang-darwin-3.9.0/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'))
+command('ranlib', '-cs', input_file('bin/intel-darwin-10.2/debug/link-static/target-os-darwin/libl1.a'))
+command('ranlib', '-cs', input_file('bin/intel-darwin-10.2/debug/link-static/runtime-link-static/target-os-darwin/libl1.a'))
+command('ranlib', input_file('bin/clang-linux-3.9.0/debug/link-static/libl1.a'))
+command('ranlib', input_file('bin/clang-linux-3.9.0/debug/link-static/runtime-link-static/libl1.a'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/strip.py b/src/boost/tools/build/test/toolset-mock/src/strip.py
new file mode 100644
index 000000000..6245588bf
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/strip.py
@@ -0,0 +1,13 @@
+#!/usr/bin/python
+#
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+command('strip', '-S', '-x', input_file('bin/darwin-4.2.1/release/target-os-darwin/test'))
+
+main()
diff --git a/src/boost/tools/build/test/toolset-mock/src/verify.py b/src/boost/tools/build/test/toolset-mock/src/verify.py
new file mode 100644
index 000000000..6e5e0ea7b
--- /dev/null
+++ b/src/boost/tools/build/test/toolset-mock/src/verify.py
@@ -0,0 +1,9 @@
+# Copyright 2017 Steven Watanabe
+#
+# 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)
+
+from MockProgram import *
+
+verify()