cpython: a9d34685ec47 (original) (raw)
--- a/Misc/NEWS +++ b/Misc/NEWS @@ -289,6 +289,10 @@ Library Tools/Demos ----------- +- Issue #3561: The Windows installer now has an option, off by default, for
- placing the Python installation into the system "Path" environment variable.
- This was backported from Python 3.3. +
- Add support for
yield from
to 2to3. - Add support for the PEP 465 matrix multiplication operator to 2to3.
--- a/Tools/msi/msi.py +++ b/Tools/msi/msi.py @@ -445,6 +445,10 @@ def add_ui(db): ("SetDLLDirToTarget", 'DLLDIR=""', 751), ])
Prepend TARGETDIR to the system path, and remove it on uninstall.
- add_data(db, "Environment",
[("PathAddition", "=-*Path", "[TARGETDIR];[~]", "REGISTRY.path")])[](#l2.9)
+ # Execute Sequences add_data(db, "InstallExecuteSequence", [("InitialTargetDir", 'TARGETDIR=""', 750), @@ -668,11 +672,11 @@ def add_ui(db): c=features.xbutton("Advanced", "Advanced", None, 0.30) c.event("SpawnDialog", "AdvancedDlg")
- c=features.text("ItemDescription", 140, 180, 210, 40, 3, "Multiline description of the currently selected item.") c.mapping("SelectionDescription","Text")
- c=features.text("ItemSize", 140, 225, 210, 33, 3,
"The size of the currently selected item.")
c.mapping("SelectionSize", "Text")
@@ -826,7 +830,7 @@ def add_features(db):
(i.e. additional Python libraries) need to follow the parent feature.
Features that have no advertisement trigger (e.g. the test suite)
must not support advertisement
- global default_feature, tcltk, htmlfiles, tools, testsuite, ext_feature, private_crt, prepend_path default_feature = Feature(db, "DefaultFeature", "Python", "Python Interpreter and Libraries", 1, directory = "TARGETDIR")
@@ -851,6 +855,15 @@ def add_features(db): testsuite = Feature(db, "Testsuite", "Test suite", "Python test suite (Lib/test/)", 11, parent = default_feature, attributes=2|8)
prepend_path is an additional feature which is to be off by default.
Since the default level for the above features is 1, this needs to be
at least level higher.
- prepend_path = Feature(db, "PrependPath", "Add python.exe to Path",
"Prepend [TARGETDIR] to the system Path variable. "[](#l2.45)
"This allows you to type 'python' into a command "[](#l2.46)
"prompt without needing the full path.", 13,[](#l2.47)
parent = default_feature, attributes=2|8,[](#l2.48)
level=2)[](#l2.49)
def extract_msvcr90(): # Find the redistributable files @@ -1168,6 +1181,8 @@ def add_registry(db): "InstallPath"), ("REGISTRY.doc", msilib.gen_uuid(), "TARGETDIR", registry_component, None, "Documentation"),
("REGISTRY.path", msilib.gen_uuid(), "TARGETDIR", registry_component, None,[](#l2.57)
None),[](#l2.58) ("REGISTRY.def", msilib.gen_uuid(), "TARGETDIR", registry_component,[](#l2.59) None, None)] + tcldata)[](#l2.60)
@@ -1184,6 +1199,7 @@ def add_registry(db): See "FeatureComponents Table". add_data(db, "FeatureComponents", [(default_feature.id, "REGISTRY"), (htmlfiles.id, "REGISTRY.doc"),
(prepend_path.id, "REGISTRY.path"),[](#l2.66) (ext_feature.id, "REGISTRY.def")] +[](#l2.67) tcldata[](#l2.68) )[](#l2.69)