#!/usr/bin/python # Copy-paste-modify from zlib.py # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester(arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Generic definitions that aren't configuration specific common_stuff = ''' source_file('test.cpp', 'test.cpp') source_file('main.cpp', 'int main() {}') source_file('lzma.h.cpp', '#include <lzma.h>\\n') action('-c -x c++ $main.cpp -o $main.o') ''' t.write('test.cpp', 'test.cpp') # Default initialization - static library t.rm('bin') t.write("Jamroot.jam", """ path-constant here : . ; using lzma ; exe test : test.cpp /lzma//lzma : : <link>static <link>shared ; """)
#!/usr/bin/python # Copyright (C) 2013 Steven Watanabe # Distributed under the Boost Software License, Version 1.0. # (See accompanying file LICENSE.txt or copy at # https://www.bfgroup.xyz/b2/LICENSE.txt) import BoostBuild import MockToolset t = BoostBuild.Tester( arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("libjpeg/jpeglib.h", 'libjpeg') t.write("libjpeg/jerror.c", 'jpeg') t.write( "Jamroot.jam", """ path-constant here : . ; using libjpeg : : <source>$(here)/libjpeg ; alias libjpeg : /libjpeg//libjpeg : : <link>static <link>shared ; """) MockToolset.set_expected( t, ''' source_file('jerror.c', 'jpeg') action('-c -x c -I./libjpeg -o $jerror.o $jerror.c')
#!/usr/bin/python # Copyright (C) 2013 Steven Watanabe # Distributed under the Boost Software License, Version 1.0. # (See accompanying file LICENSE.txt or copy at # https://www.bfgroup.xyz/b2/LICENSE.txt) import BoostBuild import MockToolset t = BoostBuild.Tester( arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("zlib/zlib.h", 'zlib') t.write("zlib/deflate.c", 'deflate') t.write( "Jamroot.jam", """ path-constant here : . ; using zlib : : <source>$(here)/zlib ; alias zlib : /zlib//zlib : : <link>static <link>shared ; """) MockToolset.set_expected( t, ''' source_file('deflate.c', 'deflate') action('-c -x c -I./zlib -o $deflate.o $deflate.c')
#!/usr/bin/python # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester(arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("libtiff/tiff.h", 'libtiff') t.write("libtiff/tiff.c", 'tiff') t.write("Jamroot.jam", """ path-constant here : . ; using libtiff : : <source>$(here)/libtiff ; alias libtiff : /libtiff//libtiff : : <link>static <link>shared ; """) MockToolset.set_expected(t, ''' source_file('tiff.c', 'tiff') action('-c -x c -I./libtiff -o $tiff.o $tiff.c') action('--dll $tiff.o -o $tiff.so') action('--archive $tiff.o -o $tiff.a') ''')
#!/usr/bin/python # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester( arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("zlib/zlib.h", 'zlib') t.write("zlib/deflate.c", 'deflate') t.write( "Jamroot.jam", """ path-constant here : . ; using zlib : : <source>$(here)/zlib ; alias zlib : /zlib//zlib : : <link>static <link>shared ; """) MockToolset.set_expected( t, ''' source_file('deflate.c', 'deflate') action('-c -x c -I./zlib -o $deflate.o $deflate.c')
#!/usr/bin/python # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester(arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("libpng/png.h", 'libpng') t.write("libpng/png.c", 'png') t.write("Jamroot.jam", """ path-constant here : . ; using libpng : : <source>$(here)/libpng ; alias libpng : /libpng//libpng : : <link>static <link>shared ; """) MockToolset.set_expected(t, ''' source_file('png.c', 'png') action('-c -x c -I./libpng -o $png.o $png.c') action('--dll $png.o -o $png.so') action('--archive $png.o -o $png.a') ''')
#!/usr/bin/python # Copy-paste-modify from zlib.py # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester(arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Generic definitions that aren't configuration specific common_stuff = ''' source_file('test.cpp', 'test.cpp') source_file('main.cpp', 'int main() {}') source_file('zstd.h.cpp', '#include <zstd.h>\\n') action('-c -x c++ $main.cpp -o $main.o') ''' t.write('test.cpp', 'test.cpp') # Default initialization - static library t.rm('bin') t.write("Jamroot.jam", """ path-constant here : . ; using zstd ; exe test : test.cpp /zstd//zstd : : <link>static <link>shared ; """)
#!/usr/bin/python # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester(arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("zlib/zlib.h", 'zlib') t.write("zlib/deflate.c", 'deflate') t.write("Jamroot.jam", """ path-constant here : . ; using zlib : : <source>$(here)/zlib ; alias zlib : /zlib//zlib : : <link>static <link>shared ; """) MockToolset.set_expected(t, ''' source_file('deflate.c', 'deflate') action('-c -x c -I./zlib -o $deflate.o $deflate.c') action('--dll $deflate.o -o $deflate.so') action('--archive $deflate.o -o $deflate.a') ''')
#!/usr/bin/python # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester( arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("bzip2/bzlib.h", 'bzip2') t.write("bzip2/blocksort.c", 'blocksort') t.write( "Jamroot.jam", """ path-constant here : . ; using bzip2 : : <source>$(here)/bzip2 ; alias bzip2 : /bzip2//bzip2 : : <link>static <link>shared ; """) MockToolset.set_expected( t, ''' source_file('blocksort.c', 'blocksort') action('-c -x c -I./bzip2 -o $blocksort.o $blocksort.c')
#!/usr/bin/python # Copyright (C) 2013 Steven Watanabe # Distributed under the Boost Software License, Version 1.0. # (See accompanying file LICENSE.txt or copy at # https://www.bfgroup.xyz/b2/LICENSE.txt) import BoostBuild import MockToolset t = BoostBuild.Tester(arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("libpng/png.h", 'libpng') t.write("libpng/png.c", 'png') t.write("Jamroot.jam", """ path-constant here : . ; using libpng : : <source>$(here)/libpng ; alias libpng : /libpng//libpng ; """) MockToolset.set_expected(t, ''' source_file('png.c', 'png') action('-c -x c -I./libpng -o $png.o $png.c') action('--archive $png.o -o $png.a') ''') t.run_build_system(["link=static"])
#!/usr/bin/python # Copyright (C) 2013 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 BoostBuild import MockToolset t = BoostBuild.Tester(arguments=['toolset=mock', '--ignore-site-config', '--user-config='], pass_toolset=0) MockToolset.create(t) # Build from source t.write("bzip2/bzlib.h", 'bzip2') t.write("bzip2/blocksort.c", 'blocksort') t.write("Jamroot.jam", """ path-constant here : . ; using bzip2 : : <source>$(here)/bzip2 ; alias bzip2 : /bzip2//bzip2 : : <link>static <link>shared ; """) MockToolset.set_expected(t, ''' source_file('blocksort.c', 'blocksort') action('-c -x c -I./bzip2 -o $blocksort.o $blocksort.c') action('--dll $blocksort.o -o $bz2.so') action('--archive $blocksort.o -o $bz2.a') ''')