Skip to content

Apache DataFusion SQL Query Engine

ARROW-5686: [R] Review R Windows CI build

Neal Richardson77000a01124b
diff --git a/ci/windows-pkg-arrow-for-r.sh b/ci/windows-pkg-arrow-for-r.sh
index f5abdb68c5..718ce0f436 100644
--- a/ci/windows-pkg-arrow-for-r.sh
+++ b/ci/windows-pkg-arrow-for-r.sh
@@ -28,39 +28,51 @@ mkdir $DST_DIR
# Grab the headers from one, either one is fine
mv mingw64/include $DST_DIR
-# Move the 64-bit versions into the expected location
+# Make the rest of the directory structure
+# lib-4.9.3 is for libraries compiled with gcc 4.9 (Rtools 3.5)
mkdir -p $DST_DIR/lib-4.9.3/x64
+mkdir -p $DST_DIR/lib-4.9.3/i386
+# lib is for the new gcc 8 toolchain (Rtools 4.0)
+mkdir -p $DST_DIR/lib/x64
+mkdir -p $DST_DIR/lib/i386
+
+# Move the 64-bit versions of libarrow into the expected location
mv mingw64/lib/*.a $DST_DIR/lib-4.9.3/x64
# Same for the 32-bit versions
-mkdir -p $DST_DIR/lib-4.9.3/i386
mv mingw32/lib/*.a $DST_DIR/lib-4.9.3/i386
-mkdir deps && cd deps
-# Get these from "backports" so they were compiled with gcc 4.9
+# Get dependencies from rtools-backports
+mkdir deps35 && cd deps35
wget https://dl.bintray.com/rtools/backports/mingw-w64-i686-boost-1.67.0-8000-any.pkg.tar.xz
wget https://dl.bintray.com/rtools/backports/mingw-w64-x86_64-boost-1.67.0-8000-any.pkg.tar.xz
-# wget https://dl.bintray.com/rtools/mingw32/mingw-w64-i686-boost-1.67.0-9002-any.pkg.tar.xz
-# wget https://dl.bintray.com/rtools/mingw64/mingw-w64-x86_64-boost-1.67.0-9002-any.pkg.tar.xz
wget https://dl.bintray.com/rtools/backports/mingw-w64-i686-thrift-0.12.0-8000-any.pkg.tar.xz
wget https://dl.bintray.com/rtools/backports/mingw-w64-x86_64-thrift-0.12.0-8000-any.pkg.tar.xz
-# wget https://dl.bintray.com/rtools/mingw32/mingw-w64-i686-thrift-0.12.0-1-any.pkg.tar.xz
-# wget https://dl.bintray.com/rtools/mingw64/mingw-w64-x86_64-thrift-0.12.0-1-any.pkg.tar.xz
-
wget https://dl.bintray.com/rtools/backports/mingw-w64-i686-snappy-1.1.7-2-any.pkg.tar.xz
wget https://dl.bintray.com/rtools/backports/mingw-w64-x86_64-snappy-1.1.7-2-any.pkg.tar.xz
-# wget https://dl.bintray.com/rtools/mingw32/mingw-w64-i686-snappy-1.1.7-2-any.pkg.tar.xz
-# wget https://dl.bintray.com/rtools/mingw64/mingw-w64-x86_64-snappy-1.1.7-2-any.pkg.tar.xz
+ls | xargs -n 1 tar -xJf
+mv mingw64/lib/*.a ../${DST_DIR}/lib-4.9.3/x64
+mv mingw32/lib/*.a ../${DST_DIR}/lib-4.9.3/i386
+
+cd ..
+
+mkdir deps40 && cd deps40
# double-conversion is only available in the Rtools4.0 builds, but apparently that's ok
wget https://dl.bintray.com/rtools/mingw64/mingw-w64-x86_64-double-conversion-3.1.2-1-any.pkg.tar.xz
wget https://dl.bintray.com/rtools/mingw32/mingw-w64-i686-double-conversion-3.1.2-1-any.pkg.tar.xz
+# These are the other Rtools 4.0 packages, for future reference
+# wget https://dl.bintray.com/rtools/mingw32/mingw-w64-i686-boost-1.67.0-9002-any.pkg.tar.xz
+# wget https://dl.bintray.com/rtools/mingw64/mingw-w64-x86_64-boost-1.67.0-9002-any.pkg.tar.xz
+# wget https://dl.bintray.com/rtools/mingw32/mingw-w64-i686-thrift-0.12.0-1-any.pkg.tar.xz
+# wget https://dl.bintray.com/rtools/mingw64/mingw-w64-x86_64-thrift-0.12.0-1-any.pkg.tar.xz
+# wget https://dl.bintray.com/rtools/mingw32/mingw-w64-i686-snappy-1.1.7-2-any.pkg.tar.xz
+# wget https://dl.bintray.com/rtools/mingw64/mingw-w64-x86_64-snappy-1.1.7-2-any.pkg.tar.xz
+
ls | xargs -n 1 tar -xJf
-cd ..
+mv mingw64/lib/*.a ../${DST_DIR}/lib/x64
+mv mingw32/lib/*.a ../${DST_DIR}/lib/i386
-mkdir -p $DST_DIR/lib/x64
-mkdir -p $DST_DIR/lib/i386
-mv deps/mingw64/lib/*.a $DST_DIR/lib/x64
-mv deps/mingw32/lib/*.a $DST_DIR/lib/i386
+cd ..
# Create build artifact
zip -r ${DST_DIR}.zip $DST_DIR