Skip to content

Commit 018811f

Browse files
zero323HyukjinKwon
authored andcommitted
[SPARK-33105][INFRA] Change default R arch from i386 to x64 and parametrize BINPREF
### What changes were proposed in this pull request? - Change default R `arch` from `i386` to `x64`, to match Rtools version. - Parameterize `BINPREF` with `WIN` (https://stackoverflow.com/a/44035904) Reported on dev: http://apache-spark-developers-list.1001551.n3.nabble.com/Broken-rlang-installation-on-AppVeyor-td30294.html ### Why are the changes needed? It seems like update from rlang 0.4.7 to 0.4.8 exposed an issue, where build fails because of incompatible ddl ``` c:/Rtools40/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/8.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:/R/bin/i386/R.dll when searching for -lR [00:01:52] c:/Rtools40/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/8.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:/R/bin/i386/R.dll when searching for -lR [00:01:52] c:/Rtools40/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/8.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lR [00:01:52] collect2.exe: error: ld returned 1 exit status ``` ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Existing tests. Closes #29991 from zero323/APPVEYOR-DEAFAULT-ARCH. Authored-by: zero323 <[email protected]> Signed-off-by: HyukjinKwon <[email protected]>
1 parent 2e07ed3 commit 018811f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

dev/appveyor-install-dependencies.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ $CRAN = "https://cloud.r-project.org"
1919

2020
Function InstallR {
2121
if ( -not(Test-Path Env:\R_ARCH) ) {
22-
$arch = "i386"
22+
$arch = "x64"
2323
}
2424
Else {
2525
$arch = $env:R_ARCH
@@ -68,7 +68,7 @@ Function InstallRtools {
6868
$gccPath = $env:GCC_PATH
6969
}
7070
$env:PATH = $RtoolsDrive + '\Rtools40\bin;' + $RtoolsDrive + '\Rtools40\mingw64\bin;' + $RtoolsDrive + '\Rtools40\' + $gccPath + '\bin;' + $env:PATH
71-
$env:BINPREF=$RtoolsDrive + '/Rtools40/mingw64/bin/'
71+
$env:BINPREF=$RtoolsDrive + '/Rtools40/mingw$(WIN)/bin/'
7272
}
7373

7474
# create tools directory outside of Spark directory

0 commit comments

Comments
 (0)