tis-wapt-python310-relocatable icon

tis-wapt-python310-relocatable

Silent install package for tis-wapt-python310-relocatable

3.10.19-39

Preprod packages are packages built on LUTI. They remain in PREPROD usually for 5 days, after which a new VirusTotal scan is performed.
If the package passes this last check, it is promoted to PROD and published on the store.

  • package: tis-wapt-python310-relocatable
  • version: 3.10.19-39
  • maintainer: sfonteneau
  • locale: all
  • target_os: windows
  • architecture: x64
  • signature_date:
  • size: 9.79 Mo

package           : tis-wapt-python310-relocatable
version           : 3.10.19-39
architecture      : x64
section           : base
priority          : optional
name              : 
categories        : 
maintainer        : sfonteneau
description       : Package for tis-python-3.10-tranquilit
depends           : 
conflicts         : 
maturity          : PREPROD
locale            : all
target_os         : windows
min_wapt_version  : 2.0
sources           : 
installed_size    : 
impacted_process  : 
description_fr    : Paquet pour tis-python-3.10-tranquilit
description_pl    : Pakiet dla tis-python-3.10-tranquilit
description_de    : Paket für tis-python-3.10-tranquilit
description_es    : Paquete para tis-python-3.10-tranquilit
description_pt    : Pacote para tis-python-3.10-tranquilit
description_it    : Pacchetto per tis-python-3.10-tranquilit
description_nl    : Pakket voor tis-python-3.10-tranquilit
description_ru    : Пакет для tis-python-3.10-tranquilit
audit_schedule    : 
editor            : 
keywords          : 
licence           : 
homepage          : 
package_uuid      : 5f786625-2b0d-404f-819f-76f32d4bfab9
valid_from        : 
valid_until       : 
forced_install_on : 
changelog         : 
min_os_version    : 
max_os_version    : 
icon_sha256sum    : b55b23fa81945c6cd4c2f4f114188aa9f8f3d0c3cbb9fb353b2803ffbb67b43b
signer            : test
signer_fingerprint: b82fc8ef4a4475c0f69ac168176c2bfc58f572eb716c4eadd65e4785c155dd8e
signature_date    : 2025-10-14T15:32:04.000000
signed_attributes : package,version,architecture,section,priority,name,categories,maintainer,description,depends,conflicts,maturity,locale,target_os,min_wapt_version,sources,installed_size,impacted_process,description_fr,description_pl,description_de,description_es,description_pt,description_it,description_nl,description_ru,audit_schedule,editor,keywords,licence,homepage,package_uuid,valid_from,valid_until,forced_install_on,changelog,min_os_version,max_os_version,icon_sha256sum,signer,signer_fingerprint,signature_date,signed_attributes
signature         : FlEEsWrivWUwGQ0UMvRy75/CTPSTht0TKaw30GIzcy3Y3tPV2lFslgLiX2f04HQWtvhJPxQUjOspvHZivP6hhwEJjlf9kl/t6H7oem8bhwGa7wLG3PZERPnngorREP6ha6hibnsboKj5R9/dSARdcx302KiHunaFBmjuJarJxMl5z6olm1zsAuJKMVngHOAMqKEHOWPh6nip2EiGVoXz4hBBSZAVQcO0puKOoOKn43dNLYvEhdbbuZXPKp0cXheywIX+oyaRK26ZT/+p7qBN8GcSXxaf2EOdQ/aPJHlluoaWv0OA0YsXWeF1zGVvt24R34i/pwzO6A32EokL8LFuJw==

# -*- coding: utf-8 -*-
from setuphelpers import *


def install():
    unzip('Python-windows_amd64-x64.zip',r'c:\pythonwapt-x64')


def uninstall():
    pass

# -*- coding: utf-8 -*-
from setupdevhelpers import *
import os
import shutil
import os
import glob
import distro
import platform

python_name_file = str(platform.system().lower() + '_' + platform.machine().lower() + '_' + '_'.join([u.split('.')[0] for u in distro.linux_distribution(False) if u][:2])).strip('_')


def update_package():

    colum1 = bs_find_all('https://www.python.org/downloads/source/','div','class',"column")[0].findAll('li')
    versionpython = None
    for entry in colum1:
        if versionpython:
            continue
        if not hasattr(entry,'contents'):
            continue
        for i in entry.contents :
            if not hasattr(i,'contents'):
                continue
            v = [t for t in i.contents if str(t).startswith('Python 3.10')]
            if v:
                versionpython = v[0].split(' ')[1]
                break

    openssl_version = '3.5.4'

    #Download and extract python source
    wget(f'https://www.python.org/ftp/python/{versionpython}/Python-{versionpython}.tgz',f'Python-{versionpython}.tgz')
    unzip_with_7zip(f'Python-{versionpython}.tgz',f'Python-{versionpython}-tar')
    unzip_with_7zip(rf'Python-{versionpython}-tar\Python-{versionpython}.tar','.')

    remove_tree(f'Python-{versionpython}-tar')
    remove_file(f'Python-{versionpython}.tgz')

    #Download and extract openssl source
    wget(rf'https://github.com/openssl/openssl/releases/download/openssl-{openssl_version}/openssl-{openssl_version}.tar.gz',rf'openssl-{openssl_version}.tar.gz')
    unzip_with_7zip(rf'openssl-{openssl_version}.tar.gz',rf'openssl-{openssl_version}-tar')
    unzip_with_7zip(rf'openssl-{openssl_version}-tar\openssl-{openssl_version}.tar','.')
    remove_tree(rf'openssl-{openssl_version}-tar')
    remove_file(rf'openssl-{openssl_version}.tar.gz')

    if not isfile(r'C:\Program Files\NASM\nasm.exe'):
        error(r'C:\Program Files\NASM\nasm.exe not found')

    run(rf'Python-{versionpython}\PCbuild\get_externals.bat',timeout=5000)

    with open(rf'openssl-{openssl_version}\Configurations\60-custom.conf','w') as f:
        f.write(data_custom)

    add_to_system_path(r'C:\Program Files\NASM')

    run(rf'cd openssl-{openssl_version} & set path=C:\Program Files\NASM;%path% &"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Auxiliary\Build\vcvars64.bat" &"C:\Strawberry\perl\bin\perl.exe" configure VC-WIN64A-rtt & nmake',timeout=5000)
    #run(rf'cd openssl-{openssl_version} & set path=C:\Program Files\NASM;%path% &"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Auxiliary\Build\vcvars32.bat" &"C:\Strawberry\perl\bin\perl.exe" configure VC-WIN32-rtt & nmake',timeout=1200)

    name_openssl_folder = glob.glob(rf'Python-{versionpython}\externals\openssl-bin-*')[0].split('\\')[-1]
    shutil.move(rf'Python-{versionpython}\externals\{name_openssl_folder}\amd64',rf'Python-{versionpython}\externals\{name_openssl_folder}\amd64old')
    shutil.move(rf'openssl-{openssl_version}',rf'Python-{versionpython}\externals\{name_openssl_folder}\amd64')
    filecopyto(rf'Python-{versionpython}\externals\{name_openssl_folder}\amd64old\include\applink.c',rf'Python-{versionpython}\externals\{name_openssl_folder}\amd64\include\applink.c')


    with open(makepath(f'Python-{versionpython}','PCbuild','openssl.props'), 'r') as f:
        data=f.read()
    data = data.replace(r"<_DLLSuffix>-1_1</_DLLSuffix>",r"<_DLLSuffix>-3-x64</_DLLSuffix>")
    with open(makepath(f'Python-{versionpython}','PCbuild','openssl.props'), 'w') as f:
        f.write(data)

    run(rf'Python-{versionpython}\PCbuild\build.bat -t Rebuild',timeout=5000)

    run(rf'"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin\msbuild.exe" "%s\Python-{versionpython}\Tools\msi\make_zip.proj" /t:Build /p:Platform=x64 /p:OutputPath="%s"' % (basedir,basedir))

    name_generate = glob.glob('*.zip')[0]
    os.rename(name_generate,'Python-%s-x64.zip' % python_name_file)

    remove_tree(f'Python-{versionpython}')
    commit_count = params.get("commit_count",0)
    control.version = "%s-%s" % (Version(versionpython), commit_count)
    control.save_control_to_wapt()



data_custom = r"""## -*- mode: perl; -*-
## Personal configuration targets

my %targets = (
    "VC-WIN32-rtt" => {
        inherit_from     => [ "VC-WIN32" ],
        cflags           => sub{my $v=pop; $v=~ s/\/MD/\/MT/ig; return $v},
        lflags           => "/nologo /release",
    },
    "VC-WIN64A-rtt" => {
        inherit_from     => [ "VC-WIN64A" ],
        cflags           => sub{my $v=pop; $v=~ s/\/MD/\/MT/ig; return $v},
        lflags           => "/nologo /release",
    },
);"""

d96e859faa213c45605e975d5aad83155039ce66e2a06dc007c7e02c8c3b42e6 : Python-windows_amd64-x64.zip
01ca7fe94636e5a08fcb73849d3b5df25d51e2c82f4dd1a08f01798b25899819 : WAPT/certificate.crt
89d3400f945edfefca7b8a7b54c47c89b97eb11fa6a8b8de0d9660b7c0ca10c4 : WAPT/control
b55b23fa81945c6cd4c2f4f114188aa9f8f3d0c3cbb9fb353b2803ffbb67b43b : WAPT/icon.png
44b4c69cf12f4860714eb96c8e7c6603c00ca97fbf3c813f66d92fb8d72bcd44 : luti.json
a439471cd713b1c143ca7ebad066cd4fa4db4c0ee793b62aa84e085100b05d6f : setup.py
6970f6687c4c484667b3e6d95140677f9e60dc1369001d2a338437ed0a540553 : update_package.py