Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ci] upgrade R CI scripts to work on Ubuntu 20.04 #4084

Merged
merged 3 commits into from
Mar 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .ci/test_r_package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export _R_CHECK_CRAN_INCOMING_REMOTE_=0
# CRAN ignores the "installed size is too large" NOTE,
# so our CI can too. Setting to a large value here just
# to catch extreme problems
export _R_CHECK_PKG_SIZES_THRESHOLD_=60
export _R_CHECK_PKG_SIZES_THRESHOLD_=100

# don't fail builds for long-running examples unless they're very long.
# See https://github.com/microsoft/LightGBM/issues/4049#issuecomment-793412254.
Expand Down Expand Up @@ -59,6 +59,7 @@ if [[ $OS_NAME == "linux" ]]; then
devscripts \
r-base-dev=${R_LINUX_VERSION} \
texinfo \
texlive-latex-extra \
texlive-latex-recommended \
texlive-fonts-recommended \
texlive-fonts-extra \
Expand Down
2 changes: 1 addition & 1 deletion .ci/test_r_package_windows.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ $env:_R_CHECK_CRAN_INCOMING_REMOTE_ = 0
# CRAN ignores the "installed size is too large" NOTE,
# so our CI can too. Setting to a large value here just
# to catch extreme problems
$env:_R_CHECK_PKG_SIZES_THRESHOLD_ = 60
$env:_R_CHECK_PKG_SIZES_THRESHOLD_ = 100

# don't fail builds for long-running examples unless they're very long.
# See https://github.com/microsoft/LightGBM/issues/4049#issuecomment-793412254.
Expand Down
2 changes: 1 addition & 1 deletion R-package/AUTOCONF_UBUNTU_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.69-11
2.69-11.1
8 changes: 4 additions & 4 deletions R-package/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,20 +291,20 @@ This section briefly explains the key files for building a CRAN package. To upda
At build time, `configure` will be run and used to create a file `Makevars`, using `Makevars.in` as a template.

1. Edit `configure.ac`.
2. Create `configure` with `autoconf`. Do not edit it by hand. This file must be generated on Ubuntu 18.04.
2. Create `configure` with `autoconf`. Do not edit it by hand. This file must be generated on Ubuntu 20.04.

If you have an Ubuntu 18.04 environment available, run the provided script from the root of the `LightGBM` repository.
If you have an Ubuntu 20.04 environment available, run the provided script from the root of the `LightGBM` repository.

```shell
./R-package/recreate-configure.sh
```

If you do not have easy access to an Ubuntu 18.04 environment, the `configure` script can be generated using Docker by running the code below from the root of this repo.
If you do not have easy access to an Ubuntu 20.04 environment, the `configure` script can be generated using Docker by running the code below from the root of this repo.

```shell
docker run \
-v $(pwd):/opt/LightGBM \
-t ubuntu:18.04 \
-t ubuntu:20.04 \
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for reviewers...I did re-run this, and configure was not changed at all.

/bin/bash -c "cd /opt/LightGBM && ./R-package/recreate-configure.sh"
```

Expand Down
2 changes: 1 addition & 1 deletion R-package/recreate-configure.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

# recreates 'configure' from 'configure.ac'
# this script should run on Ubuntu 18.04
# this script should run on Ubuntu 20.04
AUTOCONF_VERSION=$(cat R-package/AUTOCONF_UBUNTU_VERSION)

# R packages cannot have versions like 3.0.0rc1, but
Expand Down