From Max Bachmann:
- Add missing directories to searched paths for mingw installs
From Joseph Brill:
- Fix issue 4312: the cached installed msvc list had an indirect dependency
on the target architecture in the environment dictionary. The first call
to construct the installed msvc list now forces the target architecture to be
undefined, constructs the installed msvc list, and then restores the original
target architecture.
Note: an indirect dependency on the VSWHERE construction variable in the
environment remains.
- Fix issue 4312: explicitly guard against an empty regular expression list
when msvc is not installed.
- When trying to find a valid msvc batch file, check that the compiler executable
(cl.exe) exists for VS6 to VS2015 to avoid executing the msvc batch file. Always
check that the compiler executable is found on the msvc script environment path
after running the msvc batch file. Only use the sdk batch files when all of the
msvc script host/target combinations have been exhausted and a valid script was
not found.
- Add ARM64 host configurations for windows and msvc.
Note: VS2013 and earlier has not been tested on ARM64.
- If necessary, automatically define VSCMD_SKIP_SENDTELEMETRY for VS2019 and later
on ARM64 hosts when using an arm32 build of python to prevent a powershell dll
not found error pop-up window.
- Fix an issue where test SConfTests.py would fail when mscommon debugging
was enabled. The mscommon debug filter class registered with the logging
module was refactored.
- Add arm64 to the MSVS supported architectures list for VS2017 and later to be
consistent with the current documentation of MSVS_ARCH.
- Fix an issue with an unhandled MissingConfiguration exception due to an msvc
registry query that returns a path that does not exist. Multiple invocation
paths were not prepared to handle the MissingConfiguration exception. The
MissingConfiguration exception type was removed.
- The MSCommon module import was changed from a relative import to a top-level
absolute import in the following Microsoft tools: midl, mslib, mslink, mssdk, msvc,
msvs. Moving any of these tools that used relative imports to the scons site tools
folder would fail on import (i.e., the relative import paths become invalid when
moved).
- The detection of the msvc compiler executable (cl.exe) has been modified:
* The host os environment path is no longer evaluated for the existence of the
msvc compiler executable when searching the detection dictionary.
* The existence of the msvc compiler executable is checked in the detection
dictionary and the scons ENV path before the detection dictionary is merged
into the scons ENV.
* Different warnings are produced when the msvc compiler is not detected in the
detection dictionary based on whether or not an msvc compiler was detected in
the scons ENV path (i.e., a msvc compiler executable already exists in the
user's ENV path prior to detection).
* The warning message issued when a msvc compiler executable is not found in the
detection dictionary was modified by adding the word "requested":
Old warning: "Could not find MSVC compiler 'cl'."
New warning: "Could not find requested MSVC compiler 'cl'.".
* An additonal sentence is appended to the warning message issued when an msvc
compiler executable is not found in the msvc detection dictionary and is found
in the user's ENV path prior to detection:
" A 'cl' was found on the scons ENV path which may be erroneous."
From Vitaly Cheptsov:
- Fix race condition in `Mkdir` which can happen when two `SConscript`
are processed simultaneously by two separate build commands.
From William Deegan:
- The --debug flag now has a 'json' option which will write information
generated by --debug={count, memory, time, action-timestamps} and about
the build.
- Obsoleted YACCVCGFILESUFFIX, being replaced by YACC_GRAPH_FILE_SUFFIX.
If YACC_GRAPH_FILE_SUFFIX is not set, it will respect YACCVCGFILESUFFIX.
From Sten Grüner
- The newly added --debug=sconscript option (new) will output notices when
entering an exiting each SConscript as they are processed.
From Philipp Maierhöfer:
- Fix gfortran tool initialization. Defaults to using binary named gfortran
as would be expected, and properly set's SHFORTRAN flags to include -fPIC
where previously it was only doing so for the other fortran versions (F77,..)
From Jonathon Reinhart:
- Fix another instance of `int main()` in CheckLib() causing failures
when using -Wstrict-prototypes.
From Mats Wichmann
- C scanner's dictifyCPPDEFINES routine did not understand the possible
combinations of CPPDEFINES - not aware of a "name=value" string either
embedded in a sequence, or by itself. The conditional C scanner thus
did not always properly apply the defines. The regular C scanner does
not use these, so was not affected. [fixes 4193]
- Minor cleanup for ValidateOptions - docs and docstring tweaked,
add missed versionadded indicator.
- Added some typing annotations generated by a tool, to eliminate manual
work in future on things which are safe for the tool to produce.
Then manually fixed up some things related to bool that the tool did
not handly ideally. For example, simple functions which just did
"return 1" were interpreted by the tool as returning int, when bool
was really the intent. Functions/methods named like "is_*", "has_*",
"exists" are now pretty consistently marked as "-> bool".
- Simplify some code due to pylint observation: "C2801: Unnecessarily
calls dunder method __call__. Invoke instance directly."
- Python 3.9 dropped the alias base64.decodestring, deprecated since 3.1.
Only used in msvs.py. Use base64.decodebytes instead.
- When debugging (--debug=pdb), the filenames SConstruct and SConscript
are now recognized when manipulating breakpoints. Previously,
only a full pathname to an sconscript file worked, as pdb requires
a .py extension to open a file that is not an absolute path.
- SCons test runner now uses pathlib to normalize and compare paths
to test files.
- D compilers : added support for generation of .di interface files.
New variables DI_FILE_DIR, DI_FILE_DIR_PREFIX, DI_FILE_DIR_SUFFIX,
DI_FILE_SUFFIX.
- Fixed: when using the mingw tool, if an msys2 Python is used (os.sep
is '/' rather than the Windows default '\'), certain Configure checks
could fail due to the construction of the path to run the compiled check.
- Added effort to find mingw if it comes from Chocolatey install of msys2.
- Minor doc fixes: signature of Alias() now matches implementation
to avoid problem if kwargs used; case of Alias with no targets is
mentioned in text (was already shown in example); now mention that
Action([item]) does not return a ListAction - previously implied
that if arg was a list, a ListAction was *always* returned; mention
default Decider and sort the names of available decider functions,
and add a version marking. Minor fiddling with Alias.py docstrings.
- Python 3.12 support: new bytecodes for ActionTests.py, adapt to
changes to pathlib module in runtest.py (PosixPath no longer
converts slashes if given a Windows-style path). Also switch to
using `subTest` in `ActionTests`, so that we can see all 21 fails
due to bytecode changes (previously testcases aborted on the first
assert fail so we only saw seven), and use unittest asserts to
simplify complex printing stanzas.
- Added copyright headers to files in test/ that didn't have them.
- Drop three unused methods from the Environment Base class:
get_src_sig_type and get_tgt_sig_type, as well as "private"
_changed_source. These were orphaned when the long-deprecated
Source Signatures and Target Signatures were removed, these were
missed at that time.
- Remove dead code: some mocked classes in unit tests had methods
which have been removed from the Node class they're mocking,
there's no need to shadow those any more as there are no callers.
The methods are depends_on (base functionality removed in 2005)
and is_pseudeo_derived (base functionality removed in 2006). There
may well be more!
- Added pass_test() call to test/MSVC/MSVC_BATCH-spaces-targetdir.py.
It looked it was missing a more detailed check, but it should be
sufficient just to check the build worked. Renamed the fixture
dir to follow naming convention in test/MSVC overall, and added
a sconstest.skip file, also to follow convention.
- Marked some scanner methods as staticmethod.
- Class ActionBase is now an abstract base class to more accurately
reflect its usage. Derived _ActionAction inherits the ABC, so it
now declares (actually raises NotImplementedError) two methods it
doesn't use so it can be instantiated by unittests and others.
- The yacc tool now understands the bison behavior of --header,
--defines and --graph being called without option-argument as being
synonyms for -d (first two) and -g. -H also recognized as a synonym
for -d. Default value for $YACC_GRAPH_FILE_SUFFIX changed to '.gv'
to match current bison default (since bison 3.8). Set this variable
to '.dot' if using byacc. The graph file name (-g) is now generated
relative to the requested target file name, not to the source file
name, to match actual current behavior (only affects if target
explicitly requested with a different base name
than source). Docs updated. Fixes 4326 and 4327.
- Cleaned up dblite module (checker warnings, etc.).
- Some cleanup in the FortranCommon tool.
- Rewrite the internal _subproc routine - a new scons_subproc_run() now
makes use of Python's subprocess.run in a more natural way, getting
around some of the issues with attempted context manager use, fetching
output, etc. - we let the subprocess module do the hard work,
since it's well debugged and supported. _subproc is no longer
called by internal code, but remains in place in case there are builds
which call to it (even though it was never "published API").
- Changed the message about scons -H to clarify it shows built-in options.
- Improve CacheDir() Documentation.
- Release-building setup tweaked. (most of) the targets listed in
SCons' own "scons --help" now work again.
- Fix platform unit test on Windows for Py 3.12+. Fixes 4376.
- More tweaking of test framework overview (which is duplicated onto
the website, but not in the regular documentation section).
- Extend range of recognized Java versions to 20.
- Builder calls now accept PathLike objects in source lists. Fixes 4398.
- The Help() function now takes an additional keyword argument
keep_local: when starting to build a help message, you can now
retain help from AddOption calls, but omit help for SCons' own
command-line options with "Help(newtext, append=True, local_only=True)".
- A little more code "modernization", done via "pypgrade" tool set
to "3.6 and above" setting.
- Finish the change to make calling SConscript() with a nonexistent
file an error. It has issued a warning since 3.0, with "warn instead
of fail" deprecated since 3.1. Fixes 3958.
- Minor (non-functional) cleanup of some tests, particuarly test/MSVC.
- Added more error handling while reading msvc config cache.
(Enabled/specified by SCONS_CACHE_MSVC_CONFIG).
The existing cache will be discarded if there's a decode error reading it.
It's possible there's a race condition creating this issue in certain CI
builds. Also add a simple filesystem-based locking protocol to try to
avoid the problem occuring.
- Update the first two chapters on building with SCons in the User Guide.
- Update docs on Export/Import - make sure mutable/immutable status has
been mentioned.
- Some cleanup to the Util package, including renaming SCons.Util.types
to SCons.Util.sctypes to avoid any possible confusion with the
Python stdlib types module.
- TeX tests: skip tests that use makeindex or epstopdf not installed, or
if `kpsewhich glossaries.sty` fails.
- Added a .note.GNU-stack section to the test assembler files to
avoid the GNU linker issuing warnings for its absence.
- Eliminate more http: references (mostly in comments/docstrings where
they really weren't harmful). A few links labeled dead with no alt.
- Add JDK 21 LTS support
- Add a LIBLITERALPREFIX variable which can be set to the linker's
prefix for considering a library argument unmodified (e.g. for the
GNU linker, the ':' in '-l:libfoo.a'). Fixes Github issue 3951.
- Update PCH builder docs with some usage notes.