diff --git a/manual/release/index.html b/manual/release/index.html index 5714e4ad64..54d7a86e27 100644 --- a/manual/release/index.html +++ b/manual/release/index.html @@ -4,7 +4,7 @@ - + B2 User Manual @@ -886,6 +886,7 @@

B2 User Manual

  • 5.8. Generated headers
  • 5.9. Cross-compilation
  • 5.10. Package Managers
  • +
  • 5.11. Searching For Projects
  • 6. Reference @@ -955,30 +956,31 @@

    B2 User Manual

  • 13. History
  • @@ -4289,7 +4291,7 @@

    5.10. Package Managers

    -

    B2 support automatic, or manual, loading of generated build files +

    B2 supports automatic, or manual, loading of generated build files from package managers. For example using the Conan package manager which generates conanbuildinfo.jam files B2 will load that files automatically when it loads the project at the same location. The included file can @@ -4372,6 +4374,189 @@

    +

    5.11. Searching For Projects

    +
    +

    B2 supports automatic searching for referenced global projects. For example, +if you have references to /boost/predef with some minimal configuration B2 +can find the B2 project for it and automatically resolve the reference. The +searching supports two modes: finding regular B2 project directories, and +package/config style loading of single jam files.

    +
    +
    +

    5.11.1. Search Path

    +
    +

    To control which and where projects are found one can use different methods:

    +
    +
    +
      +
    • +

      B2_PROJECT_PATH environment variable.

      +
    • +
    • +

      --project-search command line argument.

      +
    • +
    • +

      rule project-search project rule.

      +
    • +
    +
    +
    +

    The search path in both B2_PROJECT_PATH and --project-search specifies a +key-value list of project-id and path. The parts of that key-value list, as +the name indicates, is a path delimiter separated list. For example if we had +these two projects we wanted to find: /zlib and /boost/asio the search paths +could look like:

    +
    +
    + + + + + + + + + + + + + +
    +Linux + +

    /zlib:/usr/local/share/zlib:/boost/asio:/home/user/external/boost-1.81/libs/asio

    +
    +Windows, VxWorks + +

    /zlib;C:/Dev/zlib;/boost/asio;C:Dev/boost-1.81/libs/asio

    +
    +VMS + +

    /zlib,X:external.zlib,/boost/asio,X:external.boost181.libs.asio

    +
    +
    +
    +

    The project-id in the search path specification maps that project root to the +indicated path. Which B2 will use to search for any projects and sub-projects +with that project-id root.

    +
    +
    +
    +

    5.11.2. Search Process

    +
    +

    Regardless of how the search path is specified, how the search happens is the +same. Searching involves either searching for a B2 project directory, i.e. +a directory containing a jamfile, or searching for a specially named *.jam +file to include (similar to how the Package Managers support includes +jam files).

    +
    +
    +

    For a given project-id of the form /d1/d2/../dn we search for the following, +in this order:

    +
    +
    +
      +
    1. +

      The project at d1/d2/../dn in any path registered for the / root.

      +
    2. +
    3. +

      The project at dn in any path registered for the /d1/d2/../dn-1 root.

      +
    4. +
    5. +

      The jamfile dn.jam in any path registered for the /d1/d2/../dn-1 root.

      +
    6. +
    7. +

      The project at dn-1_dn in any path registered for the /d1/d2/../dn-2 root.

      +
    8. +
    9. +

      The jamfile dn-1_dn.jam in any path registered for the /d1/d2/../dn-2 +root.

      +
    10. +
    11. +

      And so on until it searches for the project d1_d2_.._dn in any path +registered for the / root.

      +
    12. +
    13. +

      And for the jamfile d1_d2_.._dn.jam in any path registered for the / root.

      +
    14. +
    +
    +
    +

    For example, with this search paths:

    +
    +
    +
      +
    • +

      /boost: /usr/share/boost-1.81.0, /home/user/boost-dev/libs

      +
    • +
    • +

      /: /usr/share/b2/external

      +
    • +
    +
    +
    +

    And given the /boost/core project-id to resolve, we search for:

    +
    +
    +
      +
    1. +

      /usr/share/b2/external/boost/core/<jamfile>

      +
    2. +
    3. +

      /usr/share/boost-1.81.0/core/<jamfile>

      +
    4. +
    5. +

      /home/user/boost-dev/libs/core/<jamfile>

      +
    6. +
    7. +

      /usr/share/boost-1.81.0/core.jam

      +
    8. +
    9. +

      /home/user/boost-dev/libs/core.jam

      +
    10. +
    11. +

      /usr/share/boost-1.81.0/boost_core/<jamfile>

      +
    12. +
    13. +

      /home/user/boost-dev/libs/boost_core/<jamfile>

      +
    14. +
    15. +

      /usr/share/boost-1.81.0/boost_core.jam

      +
    16. +
    17. +

      /home/user/boost-dev/libs/boost_core.jam

      +
    18. +
    19. +

      /usr/share/b2/external/boost_core.jam

      +
    20. +
    +
    +
    +

    The first project jamfile will be assigned to the project-id. Or the first +*.jam file found will be loaded.

    +
    +
    +
    +

    5.11.3. Loading Process

    +
    +

    Depending on whether a project jamfile or *.jam file determines how the +project is loaded.

    +
    +
    +

    When loading a project jamfile with a project-id and path it is equivalent +to calling use-project project-id : path ; from the context of the project +that has the reference.

    +
    +
    +

    When loading a *.jam file as the path it is equivalent to calling: +use-packages path ; from the context of the project that has the reference. +In this case it means that the file will be loaded as part of the referenced +project and hence any bare targets or information it declares will be part of +the project.

    +
    +
    +

    @@ -4682,6 +4867,12 @@

    compileflags +
    +

    The value of this feature is passed without modification to the corresponding +tools. The values from the compileflags is applied to all compilation of any +language for the tools.

    +
    conditional

    Used to introduce indirect conditional requirements. The value should have the @@ -5075,6 +5266,17 @@

    linemarkers +
    +

    Allowed values: off.

    +
    +

    On preprocessing targets changes behavior to emit/omit line directives +like #line and #linenum.

    +
    +
    +

    NOTE: The value doesn’t propagate.

    +
    +
    link

    Allowed values: shared, static

    @@ -5407,6 +5609,14 @@

    Cross-compilation for details of cross-compilation.

    +
    threadapi
    +
    +

    Allowed values: pthread, win32.

    +
    +

    Selects threading implementation. The default is win32 if <target-os> is +windows and pthread otherwise.

    +
    +
    threading

    Allowed values: single, multi

    @@ -6060,6 +6270,157 @@
    +
    Embarcadero C++ Compiler
    +
    +

    The embarcadero module supports the 32-bit command line C compiler +bcc32x and the 64-bit command line C compiler bcc64, both clang-based, +running on Microsoft Windows. These are the clang-based Windows compilers +for all versions of Embarcadero C++.

    +
    +
    +

    The module is initialized using the following syntax:

    +
    +
    +
    +
    using embarcadero : [version] : [c++-compile-command] : [compiler options] ;
    +
    +
    +
    +

    This statement may be repeated several times, if you want to configure +several versions of the compiler.

    +
    +
    +

    version:

    +
    +
    +

    The version should be the compiler version if specified. if the +version is not specified Boost Build will find the latest installed +version of Embarcadero C and use that for the version. If the version +is specified Boost Build does not check if this matches any particular +version of Embarcadero C, so you may use the version as a mnemonic to +configure separate 'versions'.

    +
    +
    +

    c++-compile-command:

    +
    +
    +

    If the c-compile-command is not specified, Boost.Build will default to the +bcc64 compiler. If you specify a compiler option of <address-model>32 the +default compiler will be bcc32x. In either case when the command is not given +Boost Build will assume the compiler is in the PATH. So it is not necessary +to specify a command if you accept the default compiler and the Embarcadero +C binary directory is in the PATH.

    +
    +
    +

    If the command is specified it will be used as is to invoke the compiler. +If the command has either 'bcc32x(.exe)' or 'bcc64(.exe)' in it Boost Build +will use the appropriate compiler to configure the toolset. If the command +does not have either 'bcc32x(.exe)' or 'bcc64(.exe)' in it, Boost Build +will use the default compiler to configure the toolset. If you have your +own command, which does not have 'bcc32x(.exe)' in it but invokes the +'bcc32x(.exe)' compiler, specify the <address-model>32 compiler option.

    +
    +
    +

    compiler options:

    +
    +
    +

    The following options can be provided, using +`<option-name>option-value syntax`:

    +
    +
    +
    +
    cflags
    +
    +

    Specifies additional compiler flags that will be used when compiling C +and C++ sources.

    +
    +
    cxxflags
    +
    +

    Specifies additional compiler flags that will be used when compiling C++ +sources.

    +
    +
    linkflags
    +
    +

    Specifies additional command line options that will be passed to the linker.

    +
    +
    asmflags
    +
    +

    Specifies additional command line options that will be passed to the assembler.

    +
    +
    archiveflags
    +
    +

    Specifies additional command line options that will be passed to the archiver, +which creates a static library.

    +
    +
    address-model
    +
    +

    This option can be used to specify the default compiler as specified in the +dicsussion above of the c++-compile-command. Otherwise the address model +is not used to initialize the toolset.

    +
    +
    user-interface
    +
    +

    Specifies the user interface for applications. Valid choices are console +for a console applicatiuon and gui for a Windows application.

    +
    +
    root
    +
    +

    Normallly Boost Build will automatically be able to determine the root of +the Embarcadero C installation. It does this in various ways, but primarily +by checking a registry entry. If you specify the root it will use that +path, and the root you specify should be the full path to the Embarcadero +C installation on your machine ( without a trailing \ or / ). You should +not need to specify this option unless Boost Build can not find the +Embarcadero C++ root directory.

    +
    +
    Examples
    +
    +

    using embarcadero ;

    +
    +
    +
    +
    +

    Configures the toolset to use the latest version, with bcc64 as the compiler. +The bcc64 compiler must be in the PATH.

    +
    +
    +

    using embarcadero : 7.40 ;

    +
    +
    +

    Configures the toolset to use the 7.40 version, with bcc64 as the compiler. +The bcc64 compiler must be in the PATH.

    +
    +
    +

    using embarcadero : 7.40 : bcc32x ; +using embarcadero : 7.40 : : <address-model>32 ;

    +
    +
    +

    Configures the toolset to use the 7.40 version, with bcc32x as the compiler. +The bcc32x compiler must be in the PATH.

    +
    +
    +

    using embarcadero : : c:/some_path/bcc64 ;

    +
    +
    +

    Configures the toolset to use the latest version, with full command specified.

    +
    +
    +

    using embarcadero : : full_command : <address-model>32 ;

    +
    +
    +

    Configures the toolset to use the latest version, with full command specified +and bcc32x as the compiler.

    +
    +
    +

    using embarcadero : : : <root>c:/root_path ;

    +
    +
    +

    Configures the toolset to use the latest version, with bcc64 as the compiler +and the root directory of the installation specified. The bcc64 compiler must +be in the PATH.

    +
    + +
    GNU C++

    The gcc module supports the GNU C++ compiler on @@ -14193,7 +14554,108 @@

    13. History

    -

    13.1. Version 4.9.6

    +

    13.1. Version 4.10.0

    +
    +

    This release contains many bug fixes but along the way also cleanup and +refactoring of many toolsets, thanks to Nikita.

    +
    +
    +
      +
    • +

      New: Scan assembler files for C Preprocessor includes. — Nikita Kniazev

      +
    • +
    • +

      Fix: Inherit generator overrides from a base toolset. — Nikita Kniazev

      +
    • +
    • +

      New: Add linemarkers feature that on preprocessing targets changes behavior to +emit/omit line directives like #line and #<linenum>. — Nikita Kniazev

      +
    • +
    • +

      Fix compiler name for QNX. — James Choi

      +
    • +
    • +

      Fix openssl name handling. — Dmitry Arkhipov

      +
    • +
    • +

      Fix clang-win assembler path deduction. — Nikita Kniazev

      +
    • +
    • +

      Fix toolset sub-feature requirements inheritance. — Nikita Kniazev

      +
    • +
    • +

      Unify compile and link of clang-linux toolset with gcc toolset. — Nikita Kniazev

      +
    • +
    • +

      Fix same directory pch header generation for msvc toolset. — Nikita Kniazev

      +
    • +
    • +

      Implement --durations which reports top targets by execution time. — Nikita Kniazev

      +
    • +
    • +

      Change clang-darwin to inherit from clang-linux and unify compile commands. — Nikita Kniazev

      +
    • +
    • +

      Fix clang-linux to not override RPATH_OPTION. — Nikita Kniazev

      +
    • +
    • +

      Fix inadvertently running configuration checks that shouldn’t (as reported by +Alexander Grund). By changing <build>no conditionals evaluation to short +circuit. — Nikita Kniazev

      +
    • +
    • +

      Fix same toolset overrides (inherit-overrides). — Nikita Kniazev

      +
    • +
    • +

      New: Add using the C processors for assembly source files. — Nikita Kniazev

      +
    • +
    • +

      Many improvements and cleanup of internal testing. — Nikita Kniazev

      +
    • +
    • +

      Unify gcc and clang-linux soname option handling and disable it on Windows. — Nikita Kniazev

      +
    • +
    • +

      Unity gcc/mingw linking of shared and import libs. — Nikita Kniazev

      +
    • +
    • +

      Fix pdb generation ordering and naming issues. — Nikita Kniazev

      +
    • +
    • +

      Unify clang-darwin linking with gcc. — Nikita Kniazev

      +
    • +
    • +

      Fix mingw/msys/cygwin, winthreads/pthread inconsistencies to correct compiler +flags. — Nikita Kniazev

      +
    • +
    • +

      Unify clang-vxworks by inheriting from clang-linux. — Nikita Kniazev

      +
    • +
    • +

      Don’t store empty config cache and log. — Nikita Kniazev

      +
    • +
    • +

      Fix generator custom rule name inheritance. This affects cygwin/mingw linking. — Nikita Kniazev

      +
    • +
    • +

      Fix testing.execute=off to correct run-fail behavior. — Nikita Kniazev

      +
    • +
    • +

      Fix use-project with native paths. — René Ferdinand Rivera Morell

      +
    • +
    • +

      Fix msvc auto config version priority. Now msvc toolsets are configured in +correct newest to oldest regardless of being found from the registry or not. — René Ferdinand Rivera Morell

      +
    • +
    • +

      New: Add support for automatic searching of external projects for global +target and project references. — René Ferdinand Rivera Morell

      +
    • +
    +
    +
    +
    +

    13.2. Version 4.9.6

    • @@ -14203,7 +14665,7 @@

      13.1. Versi

    -

    13.2. Version 4.9.5

    +

    13.3. Version 4.9.5

    • @@ -14231,7 +14693,7 @@

      13.2. Versi

    -

    13.3. Version 4.9.4

    +

    13.4. Version 4.9.4

    • @@ -14262,7 +14724,7 @@

      13.3. Versi

    -

    13.4. Version 4.9.3

    +

    13.5. Version 4.9.3

    • @@ -14272,7 +14734,7 @@

      13.4. Versi

    -

    13.5. Version 4.9.2

    +

    13.6. Version 4.9.2

    • @@ -14282,7 +14744,7 @@

      13.5. Versi

    -

    13.6. Version 4.9.1

    +

    13.7. Version 4.9.1

    • @@ -14297,7 +14759,7 @@

      13.6. Versi

    -

    13.7. Version 4.9.0

    +

    13.8. Version 4.9.0

    This release has mostly internal cleanups and restructuring. The most significant being: fixing all memory leaks, automatic build system @@ -14366,7 +14828,7 @@

    13.7. Versi

    -

    13.8. Version 4.8.2

    +

    13.9. Version 4.8.2

    • @@ -14377,7 +14839,7 @@

      13.8. Versi

    -

    13.9. Version 4.8.1

    +

    13.10. Version 4.8.1

    • @@ -14388,7 +14850,7 @@

      13.9. Versi

    -

    13.10. Version 4.8.0

    +

    13.11. Version 4.8.0

    • @@ -14431,7 +14893,7 @@

      13.10. Vers

    -

    13.11. Version 4.7.2

    +

    13.12. Version 4.7.2

    • @@ -14445,7 +14907,7 @@

      13.11. Vers

    -

    13.12. Version 4.7.1

    +

    13.13. Version 4.7.1

    • @@ -14455,7 +14917,7 @@

      13.12. Vers

    -

    13.13. Version 4.7.0

    +

    13.14. Version 4.7.0

    Many, many fixes and internal cleanups in this release. But also adding auto-detection and bootstrap for VS 2022 preview toolset.

    @@ -14519,7 +14981,7 @@

    13.13. Vers

    -

    13.14. Version 4.6.1

    +

    13.15. Version 4.6.1

    • @@ -14532,7 +14994,7 @@

      13.14. Vers

    -

    13.15. Version 4.6.0

    +

    13.16. Version 4.6.0

    This release wraps up a few new features that make using some toolsets easier (thanks to Nikita). It’s now also possible to specify empty flags features on @@ -14595,7 +15057,7 @@

    13.15. Vers

    -

    13.16. Version 4.5.0

    +

    13.17. Version 4.5.0

    Some minor fixes to improve some old issues.

    @@ -14617,7 +15079,7 @@

    13.16. Vers

    -

    13.17. Version 4.4.2

    +

    13.18. Version 4.4.2

    This release is the first of the new home for B2 at Build Frameworks Group.

    @@ -14634,7 +15096,7 @@

    13.17. Vers

    -

    13.18. Version 4.4.1

    +

    13.19. Version 4.4.1

    Minor patch to correct missing fix for macOS default engine compiler.

    @@ -14647,7 +15109,7 @@

    13.18. Vers

    -

    13.19. Version 4.4.0

    +

    13.20. Version 4.4.0

    Along with a variety of fixes this version introduces "dynamic" response file support for some toolsets. This means that under most circumstances, if @@ -14738,7 +15200,7 @@

    13.19. Vers

    -

    13.20. Version 4.3.0

    +

    13.21. Version 4.3.0

    There are many invidual fixes in this release. Many thanks for the contributions. Special thanks to Nikita for the many improvements to msvc @@ -14838,7 +15300,7 @@

    13.20. Vers

    -

    13.21. Version 4.2.0

    +

    13.22. Version 4.2.0

    This release is predominantly minor fixes and cleanup of the engine. In particular the bootstrap/build process now clearly communicates C++11 @@ -14880,7 +15342,7 @@

    13.21. Vers

    -

    13.22. Version 4.1.0

    +

    13.23. Version 4.1.0

    Many small bug fixes in this release. But there are some new features also. There’s now an lto feature to specify the use of LTO, and what kind. The @@ -14962,7 +15424,7 @@

    13.22. Vers

    -

    13.23. Version 4.0.1

    +

    13.24. Version 4.0.1

    This patch release fixes a minor issue when trying to configure toolsets that override the toolset version with a non-version tag. Currently this is only @@ -14972,7 +15434,7 @@

    13.23. Vers

    -

    13.24. Version 4.0.0

    +

    13.25. Version 4.0.0

    After even more years of development the landscape of build systems has changed considerably, and so has the landscape of compilers. This version marks the