Fix R package build on CI. (#8445)
Co-authored-by: Hyunsu Cho <chohyu01@cs.washington.edu>
This commit is contained in:
parent
a83748eb45
commit
0252d504d8
@ -6,15 +6,13 @@ source tests/buildkite/conftest.sh
|
||||
|
||||
echo "--- Build XGBoost R package with CUDA"
|
||||
|
||||
if [[ ($is_pull_request == 0) && ($is_release_branch == 1) ]]
|
||||
then
|
||||
|
||||
tests/ci_build/ci_build.sh gpu_build_r_centos7 docker \
|
||||
--build-arg CUDA_VERSION_ARG=${CUDA_VERSION} tests/ci_build/build_r_pkg_with_cuda.sh \
|
||||
${BUILDKITE_COMMIT}
|
||||
|
||||
echo "--- Upload R tarball"
|
||||
aws s3 cp xgboost_r_gpu_linux_*.tar.gz s3://xgboost-nightly-builds/${BRANCH_NAME}/ \
|
||||
if [[ ($is_pull_request == 0) && ($is_release_branch == 1) ]]
|
||||
then
|
||||
echo "--- Upload R tarball"
|
||||
aws s3 cp xgboost_r_gpu_linux_*.tar.gz s3://xgboost-nightly-builds/${BRANCH_NAME}/ \
|
||||
--acl public-read --no-progress
|
||||
|
||||
fi
|
||||
|
||||
@ -5,12 +5,12 @@ $ErrorActionPreference = "Stop"
|
||||
Write-Host "--- Build XGBoost R package with CUDA"
|
||||
|
||||
nvcc --version
|
||||
$arch_flag = "-DGPU_COMPUTE_VER=75"
|
||||
|
||||
bash tests/ci_build/build_r_pkg_with_cuda_win64.sh $Env:BUILDKITE_COMMIT
|
||||
if ($LASTEXITCODE -ne 0) { throw "Last command failed" }
|
||||
|
||||
if ( $is_release_branch -eq 1 ) {
|
||||
$arch_flag = "-DGPU_COMPUTE_VER=75"
|
||||
|
||||
bash tests/ci_build/build_r_pkg_with_cuda_win64.sh $Env:BUILDKITE_COMMIT
|
||||
if ($LASTEXITCODE -ne 0) { throw "Last command failed" }
|
||||
|
||||
Write-Host "--- Upload R tarball"
|
||||
Get-ChildItem . -Filter xgboost_r_gpu_win64_*.tar.gz |
|
||||
Foreach-Object {
|
||||
|
||||
@ -10,7 +10,7 @@ fi
|
||||
|
||||
commit_hash="$1"
|
||||
|
||||
make Rpack
|
||||
python tests/ci_build/test_r_package.py --task=pack
|
||||
mv xgboost/ xgboost_rpack/
|
||||
|
||||
mkdir build
|
||||
|
||||
@ -9,8 +9,11 @@ then
|
||||
fi
|
||||
|
||||
commit_hash="$1"
|
||||
# Clear all positional args
|
||||
set --
|
||||
|
||||
MAKE="/c/Rtools/bin/make" /c/Rtools/bin/make Rpack
|
||||
source activate
|
||||
python tests/ci_build/test_r_package.py --task=pack
|
||||
mv xgboost/ xgboost_rpack/
|
||||
|
||||
mkdir build
|
||||
|
||||
@ -251,7 +251,9 @@ def test_with_cmake(args: argparse.Namespace) -> None:
|
||||
|
||||
@record_time
|
||||
def main(args: argparse.Namespace) -> None:
|
||||
if args.task == "build":
|
||||
if args.task == "pack":
|
||||
pack_rpackage()
|
||||
elif args.task == "build":
|
||||
src_dir = pack_rpackage()
|
||||
build_rpackage(src_dir)
|
||||
elif args.task == "doc":
|
||||
@ -280,7 +282,7 @@ if __name__ == "__main__":
|
||||
parser.add_argument(
|
||||
"--task",
|
||||
type=str,
|
||||
choices=["build", "check", "doc"],
|
||||
choices=["pack", "build", "check", "doc"],
|
||||
default="check",
|
||||
required=False,
|
||||
)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user