@@ -2,7 +2,7 @@ rem generate_a_winpython_distro.bat: to be launched from a winpython directory,
22@ echo on
33
44REM Initialize variables
5- if " %my_release_level% " == " " set my_release_level = b4
5+ if " %my_release_level% " == " " set my_release_level =
66if " %my_create_installer% " == " " set my_create_installer = True
77
88rem Set archive directory and log file
@@ -25,10 +25,10 @@ rem 2021-04-22 : path PyPy3 (as we don't try to copy PyPy3.exe to Python.exe)
2525if " %target_python_exe% " == " " set target_python_exe = python.exe
2626
2727rem Set Python target release based on my_python_target
28- if %my_python_target% == 311 set my_python_target_release = 3119& set my_release = 1
29- if %my_python_target% == 312 set my_python_target_release = 31210& set my_release = 1
30- if %my_python_target% == 313 set my_python_target_release = 3133 & set my_release = 1
31- if %my_python_target% == 314 set my_python_target_release = 3140& set my_release = 0
28+ if %my_python_target% == 311 set my_python_target_release = 3119& set my_release = 2
29+ if %my_python_target% == 312 set my_python_target_release = 31210& set my_release = 2
30+ if %my_python_target% == 313 set my_python_target_release = 3135 & set my_release = 1
31+ if %my_python_target% == 314 set my_python_target_release = 3140& set my_release = 1
3232
3333echo -------------------------------------- >> %my_archive_log%
3434echo (%date% %time% ) preparing winPython for %my_pyver% (%my_python_target% )release %my_release%%m y_flavor% (%my_release_level% ) *** %my_arch% bit ***>> %my_archive_log%
@@ -59,7 +59,7 @@ call %my_buildenv%\scripts\env.bat
5959
6060REM Create basic build infrastructure
6161echo " (%date% %time% ) Create basic build infrastructure" >> %my_archive_log%
62- python.exe -c " from make import *;make_all(%my_release% , '%my_release_level% ', pyver='%my_pyver% ', basedir=r'%my_basedir% ', verbose=True, architecture=%my_arch% , flavor='%my_flavor% ', install_options=r'%my_install_options% ', find_links=r'%my_find_links% ', source_dirs=r'%my_source_dirs% ', toolsdirs=r'%my_toolsdirs% ', docsdirs=r' %my_docsdirs% ', create_installer='False', python_target_release='%my_python_target_release% ')" >> %my_archive_log%
62+ python.exe -c " from make import *;make_all(%my_release% , '%my_release_level% ', pyver='%my_pyver% ', basedir=r'%my_basedir% ', verbose=True, architecture=%my_arch% , flavor='%my_flavor% ', install_options=r'%my_install_options% ', find_links=r'%my_find_links% ', source_dirs=r'%my_source_dirs% ', toolsdirs=r'%my_toolsdirs% ', create_installer='False', python_target_release='%my_python_target_release% ')" >> %my_archive_log%
6363
6464REM Check infrastructure is in place
6565echo " (%date% %time% ) Check infrastructure" >> %my_archive_log%
@@ -99,7 +99,7 @@ echo -------------------------------------- >>%my_archive_log%
9999echo " (%date% %time% ) Add requirement packages" >> %my_archive_log%
100100echo -------------------------------------- >> %my_archive_log%
101101python -m pip install -r %my_requirements% -c %my_constraints% --pre --no-index --trusted-host=None --find-links=%my_find_links% >> %my_archive_log%
102- python -c " from winpython import wppm;dist=wppm.Distribution(r'%WINPYDIR% ');dist.patch_standard_packages('spyder', to_movable=True)"
102+ python -c " from wppm import wppm;dist=wppm.Distribution(r'%WINPYDIR% ');dist.patch_standard_packages('spyder', to_movable=True)"
103103
104104REM Add Wheelhouse (to replace per pip lock direct ? would allow paralellism)
105105echo -------------------------------------- >> %my_archive_log%
@@ -125,13 +125,19 @@ set pip_lock_includedweb=%LOCKDIR%pylock.%my_flavor%-%WINPYARCH%bit-%WINPYVERLOC
125125set req_lock_includedlocal = %LOCKDIR% requirement.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% _includedwheelslocal.txt
126126set req_lock_includedweb = %LOCKDIR% requirement.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% _includedwheels.txt
127127
128+ set pip_lock_includedlocal = %LOCKDIR% pylock.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% _wheelslocal.toml
129+ set pip_lock_includedweb = %LOCKDIR% pylock.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% _wheels.toml
130+ set req_lock_includedlocal = %LOCKDIR% requir.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% _wheelslocal.txt
131+ set req_lock_includedweb = %LOCKDIR% requir.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% _wheels.txt
132+
133+
128134if not " Z%wheelhousereq% Z" == " ZZ" if exist " %wheelhousereq% " (
129135echo JOYYYwheelhousereq=%wheelhousereq%
130136echo z%pip_lock_includedlocal% z=%pip_lock_includedlocal%
131137rem no winpython in it naturally, with deps
132138python.exe -m pip lock --no-index --trusted-host=None --find-links=%my_find_links% -c C:\WinP\constraints.txt -r " %wheelhousereq% " -o %pip_lock_includedlocal%
133139rem generating also classic requirement with hash-256, from obtained pylock.toml
134- python.exe -c " from winpython import wheelhouse as wh;wh.pylock_to_req(r'%pip_lock_includedlocal% ', r'%req_lock_includedlocal% ')"
140+ python.exe -c " from wppm import wheelhouse as wh;wh.pylock_to_req(r'%pip_lock_includedlocal% ', r'%req_lock_includedlocal% ')"
135141
136142rem same with frozen web from local
137143python.exe -m pip lock --no-deps --require-hashes -c C:\WinP\constraints.txt -r " %req_lock_includedlocal% " -o %pip_lock_includedweb%
@@ -154,20 +160,17 @@ set LOCKDIR=%WINPYDIRBASE%\..\
154160set WINPYVERLOCK = %WINPYVER2:. =_ %
155161set req = %LOCKDIR% requirement.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% _raw.txt
156162set wanted_req = %LOCKDIR% requirement.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% .txt
157- set pip_lock_web = %LOCKDIR% pylock.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% .toml
158- set pip_lock_local = %LOCKDIR% pylock.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% _local.toml
159- set req_lock_web = %LOCKDIR% requirement.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% .txt
160- set req_lock_local = %LOCKDIR% requirement.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% _local.txt
161163
162164set pip_lock_web = %LOCKDIR% pylock.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% .toml
163165set pip_lock_local = %LOCKDIR% pylock.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% _local.toml
164- set req_lock_web = %LOCKDIR% requirement .%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% .txt
165- set req_lock_local = %LOCKDIR% requirement .%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% _local.txt
166+ set req_lock_web = %LOCKDIR% requir .%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% .txt
167+ set req_lock_local = %LOCKDIR% requir .%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% _local.txt
166168
167169
168170set my_archive_lockfile = %my_archive_dir% \pylock.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% _%date:/ =- % at_%my_time% .toml
169171set my_archive_lockfile_local = %my_archive_dir% \pylock.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% _%date:/ =- % at_%my_time% .local.toml
170- set my_changelog_lockfile = %~dp0 changelogs\pylock.%my_flavor% -%WINPYARCH% bit-%WINPYVERLOCK% .toml
172+ set my_changelog_lockfile = %~dp0 changelogs\pylock.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% .toml
173+ set my_changelog_reqfile = %~dp0 changelogs\requir.%WINPYARCH% -%WINPYVERLOCK%%my_flavor%%my_release_level% .txt
171174
172175python.exe -m pip freeze> %req%
173176findstr /v " winpython" %req% > %wanted_req%
@@ -180,14 +183,15 @@ rem pip lock from local WheelHouse, from the frozen req
180183python.exe -m pip lock --no-deps --no-index --trusted-host=None --find-links=C:\WinP\packages.srcreq -c C:\WinP\constraints.txt -r " %wanted_req% " -o %pip_lock_local%
181184
182185rem generating also classic requirement with hash-256, from obtained pylock.toml
183- python.exe -c " from winpython import wheelhouse as wh;wh.pylock_to_req(r'%pip_lock_web% ', r'%req_lock_web% ')"
184- python.exe -c " from winpython import wheelhouse as wh;wh.pylock_to_req(r'%pip_lock_local% ', r'%req_lock_local% ')"
186+ python.exe -c " from wppm import wheelhouse as wh;wh.pylock_to_req(r'%pip_lock_web% ', r'%req_lock_web% ')"
187+ python.exe -c " from wppm import wheelhouse as wh;wh.pylock_to_req(r'%pip_lock_local% ', r'%req_lock_local% ')"
185188
186189rem compare the two (result from pypi and local Wheelhouse must be equal)
187190fc " %req_lock_web% " " %req_lock_local% "
188191
189192copy/Y %pip_lock_web% %my_archive_lockfile%
190193copy/Y %pip_lock_web% %my_changelog_lockfile%
194+ copy/Y %req_lock_web% %my_changelog_reqfile%
191195
192196
193197REM Archive success
0 commit comments