Changes between Version 41 and Version 42 of UsingTheRightCompiler


Ignore:
Timestamp:
May 30, 2022, 12:24:25 AM (2 years ago)
Author:
jmroot (Joshua Root)
Comment:

explain compiler selection options better

Legend:

Unmodified
Added
Removed
Modified
  • UsingTheRightCompiler

    v41 v42  
    5151However, instead of overriding ${configure.compiler} manually,
    5252in most cases you should instead use some combination of the following keywords instead:
    53  - `compiler.blacklist` (prevent the named compiler from being used)
    54  - `compiler.whitelist` (only allow the named compiler to be used)
    55  - `compiler.fallback` (if all other compilers are blacklisted, allow the named compiler to be used)
    56 These keywords all modify the compiler fallback list,
    57 which can be found in the MacPorts sources:  [[browser:tags/release_2_3_1/base/src/port1.0/portconfigure.tcl#L426]]
     53 - `compiler.blacklist` Prevent the named compilers from being used.
     54 - `compiler.whitelist` Only allow the named compilers to be used. If set, `compiler.fallback` will be ignored. (Note that if the first entry in this list is a compiler provided by a port, it will always be used, so there is no point having further entries in that case. Multiple entries may be useful if the first ones are Xcode-provided compilers that may not be available on the system.)
     55 - `compiler.fallback` List of compilers that may be used, in order of preference. The first entry in this list that is not in `compiler.blacklist` and is available (i.e. is either installed by Xcode on the current system or is provided by a port) will be chosen. The fallback list is chosen automatically based on the current OS and Xcode versions, and you should normally not need to modify it, though appending to it may occasionally be useful.
     56These keywords all modify the selection of the default value of `configure.compiler`,
     57which can be found in the MacPorts sources:  [https://github.com/macports/macports-base/blob/master/src/port1.0/portconfigure.tcl#L758]
    5858
    5959MacPorts knows about several compilers:
     
    8282||=macports-clang-12               =|| Clang 12                       || MacPorts (clang-12)             ||
    8383||=macports-clang-13               =|| Clang 13                       || Macports (clang-13)             ||
     84||=macports-clang-14               =|| Clang 14                       || Macports (clang-14)             ||
    8485||=macports-gcc                     =|| FSF GCC                         || MacPorts (port select)           ||
    8586||=macports-gcc-4.3                 =|| FSF GCC 4.3                     || MacPorts (gcc43)                 ||