fix linux wheel build (#9896)

This commit is contained in:
chaokunyang
2020-11-17 15:49:42 +08:00
committed by GitHub
parent 09d6ea5784
commit bea0031491
4 changed files with 17 additions and 5 deletions
+1
View File
@@ -285,6 +285,7 @@ build_wheels() {
-e "encrypted_1c30b31fe1ee_iv=${encrypted_1c30b31fe1ee_iv-}"
-e "TRAVIS_COMMIT=${TRAVIS_COMMIT}"
-e "CI=${CI}"
-e "RAY_INSTALL_JAVA=${RAY_INSTALL_JAVA:-}"
)
# This command should be kept in sync with ray/python/README-building-wheels.md,
-1
View File
@@ -22,7 +22,6 @@ def gen_java_deps():
"net.java.dev.jna:jna:5.5.0",
],
repositories = [
"https://repo.spring.io/plugins-release/",
"https://repo1.maven.org/maven2/",
],
)
+16 -3
View File
@@ -26,6 +26,12 @@ yum -y install unzip zip sudo
yum -y install java-1.8.0-openjdk java-1.8.0-openjdk-devel xz
yum -y install openssl
java -version
java_bin=$(readlink -f "$(command -v java)")
echo "java_bin path $java_bin"
java_home=${java_bin%jre/bin/java}
export JAVA_HOME="$java_home"
/ray/ci/travis/install-bazel.sh
# Put bazel into the PATH if building Bazel from source
# export PATH=/root/bazel-3.2.0/output:$PATH:/root/bin
@@ -35,6 +41,10 @@ yum -y install openssl
#echo "build --config=manylinux2010" >> /root/.bazelrc
echo "build --incompatible_linkopts_to_linklibs" >> /root/.bazelrc
if [[ -n "${RAY_INSTALL_JAVA:-}" ]]; then
bazel build //java:ray_java_pkg
unset RAY_INSTALL_JAVA
fi
# Install and use the latest version of Node.js in order to build the dashboard.
set +x
@@ -58,9 +68,9 @@ for ((i=0; i<${#PYTHONS[@]}; ++i)); do
# The -f flag is passed twice to also run git clean in the arrow subdirectory.
# The -d flag removes directories. The -x flag ignores the .gitignore file,
# and the -e flag ensures that we don't remove the .whl directory and the
# dashboard directory.
git clean -f -f -x -d -e .whl -e python/ray/new_dashboard/client -e dashboard/client
# and the -e flag ensures that we don't remove the .whl directory, the
# dashboard directory and jars directory.
git clean -f -f -x -d -e .whl -e python/ray/new_dashboard/client -e dashboard/client -e python/ray/jars
pushd python
# Fix the numpy version because this will be the oldest numpy version we can
@@ -88,3 +98,6 @@ for path in .whl/*.whl; do
mv "${path}" "${path//linux/manylinux2014}"
fi
done
# Clean the build output so later operations is on a clean directory.
git clean -f -f -x -d -e .whl -e python/ray/dashboard/client
-1
View File
@@ -27,7 +27,6 @@ def gen_streaming_java_deps():
"commons-collections:commons-collections:3.2.2",
],
repositories = [
"https://repo.spring.io/plugins-release/",
"https://repo1.maven.org/maven2/",
],
)