mirror of
git://code.qt.io/qt/qt5.git
synced 2026-03-17 17:56:11 +08:00
To all linux, macOS and Windows platforms. Task-number: QTQAINFRA-7554 Change-Id: I677440fb9faf3f3d36744b59f91f0036449b639b Reviewed-by: Jukka Jokiniva <jukka.jokiniva@qt.io>
30 lines
1.2 KiB
Bash
Executable File
30 lines
1.2 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Copyright (C) 2021 The Qt Company Ltd.
|
|
# Copyright (C) 2017 Pelagicore AG
|
|
# SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
|
|
|
|
# This script installs python3
|
|
|
|
# shellcheck source=../common/unix/SetEnvVar.sh
|
|
source "${BASH_SOURCE%/*}/../common/unix/SetEnvVar.sh"
|
|
|
|
pyenv install 3.9.7
|
|
|
|
/Users/qt/.pyenv/versions/3.9.7/bin/pip3 install --user virtualenv wheel html5lib
|
|
/Users/qt/.pyenv/versions/3.9.7/bin/pip3 install --user -r ${BASH_SOURCE%/*}/../common/shared/requirements.txt
|
|
|
|
SetEnvVar "PYTHON3_PATH" "/Users/qt/.pyenv/versions/3.9.7/bin/"
|
|
SetEnvVar "PIP3_PATH" "/Users/qt/.pyenv/versions/3.9.7/bin/"
|
|
# Use 3.9 as a default python
|
|
SetEnvVar "PATH" "\$PYTHON3_PATH:\$PATH"
|
|
|
|
# Provisioning during installation says:
|
|
# 'The script sbom2doc is installed in '$HOME/.local/bin' which is not on PATH.'
|
|
# hence the explicit assignment to SBOM_PYTHON_APPS_PATH.
|
|
SetEnvVar "SBOM_PYTHON_APPS_PATH" "/Users/qt/.local/bin"
|
|
|
|
# Set SBOM_PYTHON_INTERP_PATH to Python3 instance which was used to install SBOM packages from requirements
|
|
SetEnvVar "SBOM_PYTHON_INTERP_PATH" "/Users/qt/.pyenv/versions/3.9.7/bin/python3"
|
|
|
|
echo "python3 = 3.9.7" >> ~/versions.txt
|