Skip to content

Commit 1cae687

Browse files
authored
Merge branch 'master' into jbrill-msvc-detect
2 parents 6a4c52b + a6f4983 commit 1cae687

File tree

166 files changed

+1004
-779
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

166 files changed

+1004
-779
lines changed

.editorconfig

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,17 @@ trim_trailing_whitespace = true
1010
end_of_line = lf
1111
charset = utf-8
1212

13-
[*.py]
14-
max_line_length = 78
13+
[{*.py,SConstruct,SConscript}]
14+
max_line_length = 88
1515
ensure_newline_before_comments = true
1616
include_trailing_comma = true
1717
use_parentheses = true
1818

19-
[*.xml]
19+
[*.{xml,yml,yaml}]
2020
indent_size = 2
2121

2222
[*.rst]
2323
indent_size = 3
2424

25-
[*.bat]
25+
[*.{bat,cmd,ps1}]
2626
end_of_line = crlf

.git-blame-ignore-revs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
11
# files reformatted from DOS line-endings
22
1277d8e5ab6457ed18d291100539f31d1bdb2d7c
3+
# enforced .editorconfig eol settings
4+
fbb026ef1145fe29e0ec3c1b66a3e99cac51e18d

.gitattributes

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
1+
* text=auto eol=lf
2+
*.bat eol=crlf
3+
*.cmd eol=crlf
4+
*.ps1 eol=crlf
5+
16
doc/* linguist-documentation
27
SCons/Tool/docbook/docbook-xsl-1.76.1 linguist-vendored
38
*.xml linguist-documentation
49
*.xsl linguist-documentation
510
*.gen linguist-documentation
6-
7-
*.in eol=lf

.github/workflows/experimental_tests.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ on:
1313
# Allows you to run this workflow manually from the Actions tab
1414
workflow_dispatch:
1515

16+
env:
17+
# for use by the Windows runner (ignored by the others):
18+
SCONS_CACHE_MSVC_CONFIG: 1
19+
1620
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
1721
jobs:
1822
# This workflow contains a single job called "build"
@@ -50,8 +54,8 @@ jobs:
5054

5155
- name: Install dependencies including ninja ${{ matrix.os }}
5256
run: |
53-
python -m pip install --upgrade pip setuptools wheel
54-
python -m pip install ninja psutil
57+
python -m pip install --progress-bar off --upgrade pip
58+
python -m pip install --progress-bar off ninja psutil
5559
# sudo apt-get update
5660
5761
- name: Test experimental packages ${{ matrix.os }}

.github/workflows/runtest-win.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ on:
1313
# Allows you to run this workflow manually from the Actions tab
1414
workflow_dispatch:
1515

16+
env:
17+
SCONS_CACHE_MSVC_CONFIG: 1
18+
1619
jobs:
1720
runtest-win32:
1821
runs-on: windows-latest
@@ -23,11 +26,16 @@ jobs:
2326
uses: actions/setup-python@v5.1.0
2427
with:
2528
python-version: '3.12'
29+
cache: 'pip'
30+
31+
- name: Install Python dependencies
32+
run: |
33+
python -m pip install --progress-bar off --upgrade pip
34+
python -m pip install --progress-bar off -r requirements-dev.txt
2635
27-
- name: Install dependencies including ninja
36+
- name: Install Chocolatey packages
2837
run: |
29-
python -m pip install --upgrade pip
30-
python -m pip install -r requirements-dev.txt
38+
choco install --yes --no-progress dmd winflexbison3
3139
3240
- name: runtest
3341
run: |

.github/workflows/runtest.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,12 @@ jobs:
3737
uses: actions/setup-python@v5.1.0
3838
with:
3939
python-version: '3.12'
40+
cache: 'pip'
4041

41-
- name: Install dependencies including ninja ${{ matrix.os }}
42+
- name: Install Python dependencies ${{ matrix.os }}
4243
run: |
43-
python -m pip install --upgrade pip setuptools wheel
44-
python -m pip install -r requirements-dev.txt
44+
python -m pip install --progress-bar off --upgrade pip
45+
python -m pip install --progress-bar off -r requirements-dev.txt
4546
# sudo apt-get update
4647
4748
- name: runtest ${{ matrix.os }}

.github/workflows/scons-package.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,13 @@ jobs:
2020
uses: actions/setup-python@v5.1.0
2121
with:
2222
python-version: '3.12'
23+
cache: 'pip'
2324

2425
- name: Install dependencies
2526
run: |
26-
python -m pip install --upgrade pip setuptools wheel build
27+
python -m pip install --progress-bar off --upgrade pip setuptools wheel
2728
#python -m pip install flake8 pytest
28-
if [ -f requirements-pkg.txt ]; then pip install -r requirements-pkg.txt; elif [ -f requirements.txt ]; then pip install -r requirements.txt; fi
29+
if [ -f requirements-pkg.txt ]; then pip install --progress-bar off -r requirements-pkg.txt; elif [ -f requirements.txt ]; then pip install --progress-bar off -r requirements.txt; fi
2930
sudo apt-get update
3031
sudo apt-get -y install docbook-xml docbook-xsl xsltproc fop docbook-xsl-doc-pdf
3132
# try to keep the texlive install as small as we can to save some time/space

CHANGES.txt

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,11 @@
44

55
Change Log
66

7-
NOTE: The 4.0.0 Release of SCons dropped Python 2.7 Support
8-
NOTE: 4.3.0 now requires Python 3.6.0 and above. Python 3.5.x is no longer supported
7+
NOTE: The 4.0.0 release of SCons dropped Python 2.7 support. Use 3.1.2 if
8+
Python 2.7 support is required (but note old SCons releases are unsupported).
9+
NOTE: Since SCons 4.3.0, Python 3.6.0 or above is required.
10+
NOTE: Python 3.6 support is deprecated and will be dropped in a future reease.
11+
python.org no longer supports 3.6 or 3.7, and will drop 3.8 in Oct. 2024.
912

1013
RELEASE VERSION/DATE TO BE FILLED IN LATER
1114

@@ -71,6 +74,7 @@ RELEASE VERSION/DATE TO BE FILLED IN LATER
7174
- GetSConsVersion() to grab the latest SCons version without needing to
7275
access SCons internals.
7376
- Migrate setup.cfg logic to pyproject.toml; remove setup.cfg.
77+
- Update .gitattributes to match .editorconfig; enforce eol settings.
7478

7579
From Raymond Li:
7680
- Fix issue #3935: OSErrors are now no longer hidden during execution of
@@ -133,6 +137,26 @@ RELEASE VERSION/DATE TO BE FILLED IN LATER
133137
- Framework for scons-time tests adjusted so a path with a long username
134138
Windows has squashed doesn't get re-expanded. Fixes a problem seen
135139
on GitHub Windows runner which uses a name "runneradmin".
140+
- SCons.Environment.is_valid_construction_var() now returns a boolean to
141+
match the convention that functions beginning with "is" have yes/no
142+
answers (previously returned either None or an re.match object).
143+
Now matches the annotation and docstring (which were prematurely
144+
updated in 4.6). All SCons usage except unit test was already fully
145+
consistent with a bool.
146+
- When a variable is added to a Variables object, it can now be flagged
147+
as "don't perform substitution" by setting the argument subst.
148+
This allows variables to contain characters which would otherwise
149+
cause expansion. Fixes #4241.
150+
- The test runner now recognizes the unittest module's return code of 5,
151+
which means no tests were run. SCons/Script/MainTests.py currently
152+
has no tests, so this particular error code is expected - should not
153+
cause runtest to give up with an "unknown error code".
154+
- Updated the notes about reproducible builds with SCons and the example.
155+
- The Clone() method now respects the variables argument (fixes #3590)
156+
- is_valid_construction_var() (not part of the public API) moved from
157+
SCons.Environment to SCons.Util to avoid the chance of import loops. Variables
158+
and Environment both use the routine and Environment() uses a Variables()
159+
object so better to move to a safer location.
136160

137161

138162
RELEASE 4.7.0 - Sun, 17 Mar 2024 17:22:20 -0700

README.rst

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,19 @@ notifications and other GitHub events (``#github-update``),
249249
if those are of interest. See the website for more contact information:
250250
https://scons.org/contact.html.
251251

252+
Reproducible Builds
253+
===================
254+
SCons itself is set up to do "reproducible builds"
255+
(see (https://reproducible-builds.org/specs/source-date-epoch/)
256+
if environment variables ``SOURCE_DATE_EPOCH`` is set - that is,
257+
fields in the package which could change each time the package is
258+
constructed are forced to constant values.
259+
260+
To support other projects which wish to do the same, a sample script
261+
is provided which can be placed in a site directory, which imports
262+
``SOURCE_DATE_EPOCH`` and sets it in the execution environment of
263+
every created construction envirionment. There's also an installer
264+
script (POSIX shell only). See packaging/etc/README.txt for more details.
252265

253266
Donations
254267
=========
@@ -258,15 +271,6 @@ software, or hardware) to support continued work on the project. Information
258271
is available at https://www.scons.org/donate.html
259272
or the GitHub Sponsors button on https://github.com/scons/scons.
260273

261-
Reproducible Builds
262-
===================
263-
In order to suppor those users who which to produce reproducible builds
264-
(https://reproducible-builds.org/specs/source-date-epoch/) we're now including
265-
logic to force SCons to propagate SOURCE_DATE_EPOCH from your shell environment for
266-
all SCons builds to support reproducible builds we're now providing an example
267-
site_init.py and a script to install it in your ~/.scons. See packaging/etc/README.txt
268-
for more info
269-
270274
For More Information
271275
====================
272276

RELEASE.txt

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,15 @@ CHANGED/ENHANCED EXISTING FUNCTIONALITY
5353
- The vswhere executable locations for the WinGet and Scoop package managers were
5454
added to the default vswhere executable search list after the Chocolatey
5555
installation location.
56+
- SCons.Environment.is_valid_construction_var() now returns a boolean to
57+
match the convention that functions beginning with "is" have yes/no
58+
answers (previously returned either None or an re.match object).
59+
Now matches the annotation and docstring (which were prematurely
60+
updated in 4.6). All SCons usage except unit test was already fully
61+
consistent with a bool.
62+
- The Variables object Add method now accepts a subst keyword argument
63+
(defaults to True) which can be set to inhibit substitution prior to
64+
calling the variable's converter and validator.
5665

5766
FIXES
5867
-----
@@ -92,6 +101,7 @@ FIXES
92101
executable that detects new msvc installations.
93102
- MSVC: Visual Studio 2022 v143 BuildTools now supports msvc toolset versions from
94103
14.30 to 14.4X. Fixes Issue #4543.
104+
- The Clone() method now respects the variables argument (fixes #3590)
95105

96106
IMPROVEMENTS
97107
------------
@@ -127,6 +137,7 @@ DOCUMENTATION
127137
- Restructured API Docs build so main package contents are listed
128138
before contents of package submodules.
129139
- Updated manpage description of Command "builder" and function.
140+
- Updated the notes about reproducible builds with SCons and the example.
130141

131142

132143

@@ -139,7 +150,18 @@ DEVELOPMENT
139150
by adding SKIP_PDF=1. This should help with distro packaging of SCons,
140151
which now does not need "fop" and other tools to be set up in order to
141152
build pdf versions which are then ignored.
142-
153+
- .gitattributes has been setup to mirror .editorconfig's eol settings.
154+
The repo-wide line-ending is now `lf`, with the exception of a few
155+
Windows-only files using `crlf` instead. Any files not already fitting
156+
this format have been explicitly converted.
157+
- The test runner now recognizes the unittest module's return code of 5,
158+
which means no tests were run. SCons/Script/MainTests.py currently
159+
has no tests, so this particular error code is expected - should not
160+
cause runtest to give up with an "unknown error code".
161+
- is_valid_construction_var() (not part of the public API) moved from
162+
SCons.Environment to SCons.Util to avoid the chance of import loops. Variables
163+
and Environment both use the routine and Environment() uses a Variables()
164+
object so better to move to a safer location.
143165

144166
Thanks to the following contributors listed below for their contributions to this release.
145167
==========================================================================================

0 commit comments

Comments
 (0)