Skip to content

Commit 92913aa

Browse files
authored
[CI] Use Vault repository to re-gain access to devtoolset-4 (#5589)
* [CI] Use Vault repository to re-gain access to devtoolset-4 * Use manylinux2010 tag * Update Dockerfile.jvm * Fix rename_whl.py * Upgrade Pip, to handle manylinux2010 tag * Update insert_vcomp140.py * Update test_python.sh
1 parent e4f5b6c commit 92913aa

File tree

6 files changed

+16
-9
lines changed

6 files changed

+16
-9
lines changed

Jenkinsfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ def BuildCUDA(args) {
249249
sh """
250250
${dockerRun} ${container_type} ${docker_binary} ${docker_args} tests/ci_build/build_via_cmake.sh -DUSE_CUDA=ON -DUSE_NCCL=ON -DOPEN_MP:BOOL=ON
251251
${dockerRun} ${container_type} ${docker_binary} ${docker_args} bash -c "cd python-package && rm -rf dist/* && python setup.py bdist_wheel --universal"
252-
${dockerRun} ${container_type} ${docker_binary} ${docker_args} python3 tests/ci_build/rename_whl.py python-package/dist/*.whl ${commit_id} manylinux1_x86_64
252+
${dockerRun} ${container_type} ${docker_binary} ${docker_args} python3 tests/ci_build/rename_whl.py python-package/dist/*.whl ${commit_id} manylinux2010_x86_64
253253
"""
254254
// Stash wheel for CUDA 9.0 target
255255
if (args.cuda_version == '9.0') {

tests/ci_build/Dockerfile.gpu_build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ FROM nvidia/cuda:$CUDA_VERSION-devel-centos6
33

44
# Environment
55
ENV DEBIAN_FRONTEND noninteractive
6-
ENV DEVTOOLSET_URL_ROOT http://mirror.centos.org/centos/6/sclo/x86_64/rh/devtoolset-4
6+
ENV DEVTOOLSET_URL_ROOT http://vault.centos.org/6.9/sclo/x86_64/rh/devtoolset-4/
77

88
# Install all basic requirements
99
RUN \

tests/ci_build/Dockerfile.jvm

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
11
FROM centos:6
22

3+
ENV DEVTOOLSET_URL_ROOT http://vault.centos.org/6.9/sclo/x86_64/rh/devtoolset-4/
4+
35
# Install all basic requirements
46
RUN \
57
yum -y update && \
68
yum install -y tar unzip wget xz git centos-release-scl yum-utils java-1.8.0-openjdk-devel && \
79
yum-config-manager --enable centos-sclo-rh-testing && \
810
yum -y update && \
9-
yum install -y devtoolset-6-gcc devtoolset-6-binutils devtoolset-6-gcc-c++ && \
11+
yum install -y $DEVTOOLSET_URL_ROOT/devtoolset-4-gcc-5.3.1-6.1.el6.x86_64.rpm \
12+
$DEVTOOLSET_URL_ROOT/devtoolset-4-gcc-c++-5.3.1-6.1.el6.x86_64.rpm \
13+
$DEVTOOLSET_URL_ROOT/devtoolset-4-binutils-2.25.1-8.el6.x86_64.rpm \
14+
$DEVTOOLSET_URL_ROOT/devtoolset-4-runtime-4.1-3.sc1.el6.x86_64.rpm \
15+
$DEVTOOLSET_URL_ROOT/devtoolset-4-libstdc++-devel-5.3.1-6.1.el6.x86_64.rpm && \
1016
# Python
1117
wget -O Miniconda3.sh https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh && \
1218
bash Miniconda3.sh -b -p /opt/python && \
@@ -19,9 +25,9 @@ RUN \
1925
ln -s /opt/apache-maven-3.6.1/ /opt/maven
2026

2127
ENV PATH=/opt/python/bin:/opt/maven/bin:$PATH
22-
ENV CC=/opt/rh/devtoolset-6/root/usr/bin/gcc
23-
ENV CXX=/opt/rh/devtoolset-6/root/usr/bin/c++
24-
ENV CPP=/opt/rh/devtoolset-6/root/usr/bin/cpp
28+
ENV CC=/opt/rh/devtoolset-4/root/usr/bin/gcc
29+
ENV CXX=/opt/rh/devtoolset-4/root/usr/bin/c++
30+
ENV CPP=/opt/rh/devtoolset-4/root/usr/bin/cpp
2531

2632
# Install Python packages
2733
RUN \

tests/ci_build/insert_vcomp140.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
vcomp140_path = 'C:\\Windows\\System32\\vcomp140.dll'
1111

1212
for wheel_path in sorted(glob.glob(sys.argv[1])):
13-
m = re.search(r'xgboost-(.*)-py2.py3', wheel_path)
13+
m = re.search(r'xgboost-(.*)-py3', wheel_path)
1414
assert m
1515
version = m.group(1)
1616

tests/ci_build/rename_whl.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def cd(path):
2121
commit_id = sys.argv[2]
2222
platform_tag = sys.argv[3]
2323

24-
assert platform_tag in ['manylinux1_x86_64', 'win_amd64']
24+
assert platform_tag in ['manylinux1_x86_64', 'manylinux2010_x86_64', 'win_amd64']
2525

2626
dirname, basename = os.path.dirname(whl_path), os.path.basename(whl_path)
2727

@@ -32,6 +32,6 @@ def cd(path):
3232
'version': tokens[1],
3333
'commit_id': commit_id,
3434
'platform_tag': platform_tag}
35-
new_name = '{pkg_name}-{version}+{commit_id}-py2.py3-none-{platform_tag}.whl'.format(**keywords)
35+
new_name = '{pkg_name}-{version}+{commit_id}-py3-none-{platform_tag}.whl'.format(**keywords)
3636
print('Renaming {} to {}...'.format(basename, new_name))
3737
os.rename(basename, new_name)

tests/ci_build/test_python.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ suite=$1
77
# Install XGBoost Python package
88
function install_xgboost {
99
wheel_found=0
10+
pip install --upgrade pip --user
1011
for file in python-package/dist/*.whl
1112
do
1213
if [ -e "${file}" ]

0 commit comments

Comments
 (0)