build_conda.sh 735 Bytes
Newer Older
facebook-github-bot's avatar
facebook-github-bot committed
1
2
3
4
5
6
7
#!/bin/bash
# Copyright (c) Facebook, Inc. and its affiliates. All rights reserved.
set -ex

script_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
. "$script_dir/pkg_helpers.bash"

8
9
VERSION=$(python -c "exec(open('${script_dir}/../pytorch3d/__init__.py').read()); print(__version__)")

10
11
12
# Prevent dev tag in the version string.
export BUILD_VERSION=$VERSION

facebook-github-bot's avatar
facebook-github-bot committed
13
export BUILD_TYPE=conda
14
setup_env "$VERSION"
facebook-github-bot's avatar
facebook-github-bot committed
15
16
17
18
19
export SOURCE_ROOT_DIR="$PWD"
setup_conda_pytorch_constraint
setup_conda_cudatoolkit_constraint
setup_visual_studio_constraint
# shellcheck disable=SC2086
Haoqi Fan's avatar
Haoqi Fan committed
20
conda build $CONDA_CHANNEL_FLAGS ${TEST_FLAG:-} -c defaults -c conda-forge --no-anaconda-upload -c fvcore --python "$PYTHON_VERSION" packaging/pytorch3d