This repository was archived by the owner on Jul 1, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ FROM gcr.io/swift-tensorflow/base-deps-cuda10.2-cudnn7-ubuntu18.04
33# Allows the caller to specify the toolchain to use.
44ARG swift_tf_url=https://storage.googleapis.com/swift-tensorflow-artifacts/nightlies/latest/swift-tensorflow-DEVELOPMENT-notf-ubuntu18.04.tar.gz
55ARG bazel_version=3.1.0
6+ ARG TENSORFLOW_USE_STANDARD_TOOLCHAIN=NO
67
78RUN if test -d /swift-apis/google-cloud-sdk; then \
89 mv /swift-apis/google-cloud-sdk /opt/google-cloud-sdk; \
@@ -61,6 +62,7 @@ RUN cmake
6162 -D CMAKE_BUILD_TYPE=Release \
6263 -D CMAKE_INSTALL_PREFIX=/swift-tensorflow-toolchain/usr \
6364 -D CMAKE_Swift_COMPILER=/swift-tensorflow-toolchain/usr/bin/swiftc \
65+ -D TENSORFLOW_USE_STANDARD_TOOLCHAIN="$TENSORFLOW_USE_STANDARD_TOOLCHAIN" \
6466 -G Ninja \
6567 -S /swift-apis
6668RUN cmake --build /BinaryCache/tensorflow-swift-apis --verbose
Original file line number Diff line number Diff line change @@ -10,6 +10,12 @@ gcloud beta auth configure-docker
1010# 'swift_tf_bigstore_gfile', if it exists.
1111if [[ ! -z ${swift_tf_bigstore_gfile+x} ]]; then
1212 export swift_tf_url=" ${swift_tf_bigstore_gfile/ \/ bigstore/ https:// storage.googleapis.com} "
13+ case " $swift_tf_url " in
14+ * stock* ) export TENSORFLOW_USE_STANDARD_TOOLCHAIN=YES ;;
15+ * ) export TENSORFLOW_USE_STANDARD_TOOLCHAIN=NO ;;
16+ esac
17+ else
18+ export TENSORFLOW_USE_STANDARD_TOOLCHAIN=NO
1319fi
1420
1521# Help debug the job's disk space.
2632
2733cd github/swift-apis
2834cp -R /opt/google-cloud-sdk .
29- sudo -E docker build -t build-img -f Dockerfile --build-arg swift_tf_url .
35+ sudo -E docker build -t build-img -f Dockerfile \
36+ --build-arg swift_tf_url \
37+ --build-arg TENSORFLOW_USE_STANDARD_TOOLCHAIN \
38+ .
3039
3140sudo docker create --name build-container build-img
3241mkdir -p " $KOKORO_ARTIFACTS_DIR /swift_apis_benchmarks"
You can’t perform that action at this time.
0 commit comments