Browse Source

fix(mge): macos whl build

From GITHUB 168

COPYBARA_INTEGRATE_REVIEW=https://api.github.com/repos/MegEngine/MegEngine/pulls/168 from Tricster <mediosrity@gmail.com> 5c775d02dd
Closes #168
GitOrigin-RevId: bceecb401b
tags/v1.6.0-rc1
Tricster Megvii Engine Team 4 years ago
parent
commit
6b843ccd93
2 changed files with 6 additions and 7 deletions
  1. +1
    -0
      scripts/whl/macos/macos_build_whl.sh
  2. +5
    -7
      scripts/whl/macos/macos_whl_env_prepare.sh

+ 1
- 0
scripts/whl/macos/macos_build_whl.sh View File

@@ -2,6 +2,7 @@

READLINK=readlink
OS=$(uname -s)
USER=$(whoami)

if [ $OS = "Darwin" ];then
READLINK=greadlink


+ 5
- 7
scripts/whl/macos/macos_whl_env_prepare.sh View File

@@ -46,21 +46,19 @@ SRC_DIR=$($READLINK -f "`dirname $0`/../../../")

echo ${SRC_DIR}
ALL_PYTHON="3.5.9 3.6.10 3.7.7 3.8.3"
USER=$(whoami)

function install_python_package() {
for pak in ${ALL_PYTHON}
do
echo "###### do command: env PYTHON_CONFIGURE_OPTS=\"--enable-shared\" pyenv install ${pak}"
if [ -e /Users/$USER/.pyenv/versions/${pak} ];then
echo "FOUND install /Users/$USER/.pyenv/versions/${pak} strip it..."
if [ -e /Users/${USER}/.pyenv/versions/${pak} ];then
echo "FOUND install /Users/${USER}/.pyenv/versions/${pak} strip it..."
else
env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install ${pak}
fi
echo "###### do command: /Users/${USER}/.pyenv/versions/${pak}/bin/python3 -m pip install numpy wheel requests tqdm tabulate"
/Users/${USER}/.pyenv/versions/${pak}/bin/python3 -m pip install numpy wheel
echo "###### do command: /Users/${USER}/.pyenv/versions/${pak}/bin/python3 -m pip install -r ${SRC_DIR}/python_module/requires-test.txt"
/Users/${USER}/.pyenv/versions/${pak}/bin/python3 -m pip install -r ${SRC_DIR}/python_module/requires-test.txt
echo "###### do command: /Users/$USER/.pyenv/versions/${pak}/bin/python3 -m pip install -r ${SRC_DIR}/imperative/python/requires.txt"
/Users/$USER/.pyenv/versions/${pak}/bin/python3 -m pip install -r ${SRC_DIR}/imperative/python/requires.txt
done
}



Loading…
Cancel
Save