makepackage: don't install Python 2.7 bindings by default in installer

This commit is contained in:
rdb 2020-01-06 03:32:01 +01:00
parent 4032560e51
commit d21d58f12c
2 changed files with 7 additions and 11 deletions

View File

@ -136,12 +136,8 @@ var MANPAGE
!if "${PYVER}" == "${INCLUDE_PYVER}"
SectionIn 1 2 3
!else
!if "${PYVER}" == "2.7"
SectionIn 1 2
!else
; See .onInit function where this is dynamically enabled.
SectionIn 2
!endif
; See .onInit function where this is dynamically enabled.
SectionIn 2
!endif
SetDetailsPrint both
@ -528,7 +524,7 @@ Function .onInit
SetRegView ${REGVIEW}
!endif
; We never check for 2.7; it is always enabled in Auto mode
; We never check for 2.7; it is always disabled in Auto mode
!if "${REGVIEW}" == "32"
!insertmacro MaybeEnablePyBindingSection 3.5-32
!insertmacro MaybeEnablePyBindingSection 3.6-32

View File

@ -650,9 +650,9 @@ def MakeInstallerOSX(version, python_versions=[], installdir=None, **kwargs):
for version_info in python_versions:
pyver = version_info["version"]
if pyver == "2.7":
# Always install Python 2.7 by default; it's included on macOS.
cond = "true"
if pyver in ("2.7", "3.4"):
# Don't install these EOL versions of Python by default.
cond = "false"
else:
cond = "isPythonVersionInstalled('%s')" % (pyver)
dist.write(' <choice id="pybindings%s" start_selected="%s" title="Python %s Bindings" tooltip="Python bindings for the Panda3D libraries" description="Support for Python %s.">\n' % (pyver, cond, pyver, pyver))
@ -963,7 +963,7 @@ def MakeInstaller(version, **kwargs):
fn += version
python_versions = kwargs.get('python_versions', [])
if len(python_versions) == 1 and python_versions[0]["version"] != "2.7":
if len(python_versions) == 1:
fn += '-py' + python_versions[0]["version"]
if GetOptimize() <= 2: