Improve source installation of python bindings.

Add support for conda environments.
Add step by step instructions in the README.
This commit is contained in:
Kevin Zakka
2022-03-26 18:31:45 -07:00
parent 21338e6178
commit 95350ce482
3 changed files with 45 additions and 10 deletions
+2 -2
View File
@@ -13,7 +13,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
if [[ -z ${VIRTUAL_ENV} ]]; then
if [[ -z ${VIRTUAL_ENV} ]] && [[ -z ${CONDA_DEFAULT_ENV} ]] ; then
echo "This script must be run from within a Python virtual environment"
exit 1
fi
@@ -28,7 +28,7 @@ else
readonly tmp_dir="$(mktemp -d)"
fi
python -m pip install --upgrade pip
python -m pip install --upgrade pip setuptools wheel
python -m pip install absl-py
pushd ${tmp_dir}
cp -r "${package_dir}"/* .