aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Damien Martin-Guillerez <dmarting@google.com>2016-11-10 20:15:27 +0000
committerGravatar Klaus Aehlig <aehlig@google.com>2016-11-11 10:04:08 +0000
commitd053df56a57689066cc6695520fd5f52f1726cb6 (patch)
tree1c598662ba7fbfd56681452e21a6e3ed56c516c5
parent51f64da2d9a917a18c292e624260e50544a09347 (diff)
Remove all node specific set-up from the Windows CI compile script
Those set-up have been moved to the Jenkins job or simply removed. -- Change-Id: Ib687ad4ab682d81f94ea2eadacf3d145c9fcfe14 Reviewed-on: https://bazel-review.googlesource.com/7332 MOS_MIGRATED_REVID=138789683
-rw-r--r--scripts/ci/windows/compile_windows.bat1
-rwxr-xr-xscripts/ci/windows/compile_windows.sh37
2 files changed, 8 insertions, 30 deletions
diff --git a/scripts/ci/windows/compile_windows.bat b/scripts/ci/windows/compile_windows.bat
deleted file mode 100644
index 5fd0839c9d..0000000000
--- a/scripts/ci/windows/compile_windows.bat
+++ /dev/null
@@ -1 +0,0 @@
-c:\tools\msys64\usr\bin\bash -l %cd%/scripts/ci/windows/compile_windows.sh %*
diff --git a/scripts/ci/windows/compile_windows.sh b/scripts/ci/windows/compile_windows.sh
index 9f6ab473f6..541b4df41d 100755
--- a/scripts/ci/windows/compile_windows.sh
+++ b/scripts/ci/windows/compile_windows.sh
@@ -14,36 +14,19 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-# Jenkins is capable of executing shell scripts directly, even on Windows,
-# but it uses a shell binary bundled with it and not the msys one. We don't
-# want to use two different shells, so a batch file is used instead to call
-# the msys shell.
-
-# We need to execute bash with -l so that we don't get the usual environment
-# variables from cmd.exe which would interfere with our operation, but that
-# means that PWD will be $HOME. Thus, we need to cd to the source tree.
-cd $(dirname $0)/../../..
-
-# Find Java. Minor versions and thus the name of the directory changes quite
-# often.
-export JAVA_HOME=$(ls -d c:/Program\ Files/Java/jdk* 2> /dev/null | head -n 1)
-if [[ "$JAVA_HOME" == "" ]]; then
- echo "JDK not found under c:\\Program Files\\Java" 1>& 2
- exit 1
-fi
+# Ideally we would call directly script/ci/build.sh just like we do
+# for the linux script but we are not there yet.
-# These variables are temporarily needed for Bazel
-export BAZEL_SH="$(cygpath --windows /bin/bash)"
-export TMPDIR=${TMPDIR:-c:/bazel_ci/temp}
-export PATH="${PATH}:/c/python_27_amd64/files"
-mkdir -p "${TMPDIR}" # mkdir does work with a path starting with 'c:/', wow
+# Ensure we are in the root directory
+cd $(dirname $0)/../../..
# Even though there are no quotes around $* in the .bat file, arguments
# containing spaces seem to be passed properly.
-echo "Bootstrapping Bazel"
-retCode=0
source ./scripts/ci/build.sh
+# Bazel still needs to know where bash is, take it from cygpath.
+export BAZEL_SH="$(cygpath --windows /bin/bash)"
+
# TODO(bazel-team): we should replace ./compile.sh by the same script we use
# for other platform
release_label="$(get_full_release_name)"
@@ -51,11 +34,7 @@ release_label="$(get_full_release_name)"
if [ -n "${release_label}" ]; then
export EMBED_LABEL="${release_label}"
fi
-./compile.sh "$*" || retCode=$?
-if (( $retCode != 0 )); then
- echo "$retCode" > .unstable
- exit 0
-fi
+./compile.sh "$*"
# Copy the resulting artifact.
mkdir -p output/ci