Skip to content

Commit

Permalink
MINOR: [R] Default to bundled re2 build (apache#39514)
Browse files Browse the repository at this point in the history
### Rationale for this change

The CRAN check on `fedora clang devel` builds with clang against libc++ and has a system re2 installed that was build with C++11  ABI which causes  linking to fail  due to the [abi:cxx11]-symbol annotation on the system version.

A user could manually use the bundled build or path hint a clang version of the library. To avoid extra work for the CRAN maintainers we can just default to the bundled build. The re2 build is small enough that users building from source will not really feel the difference and can still opt to use the system re2 via `EXTRA_CMAKE_FLAGS`. 

### What changes are included in this PR?

Default to use our bundled build to prevent the problems. 

### Are these changes tested?

On a local dev container replicating the cran env.

### Are there any user-facing changes?

Source build now default to use the bundled re2 version, this can be overridden.

Authored-by: Jacob Wujciak-Jens <[email protected]>
Signed-off-by: Jacob Wujciak-Jens <[email protected]>
  • Loading branch information
assignUser authored Jan 8, 2024
1 parent 1f42e6d commit f60c281
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions r/inst/build_arrow_static.sh
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ ${CMAKE} -DARROW_BOOST_USE_SHARED=OFF \
-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_UNITY_BUILD=${CMAKE_UNITY_BUILD:-OFF} \
-Dre2_SOURCE=${re2_SOURCE:-BUNDLED} \
-Dxsimd_SOURCE=${xsimd_SOURCE:-} \
-Dzstd_SOURCE=${zstd_SOURCE:-} \
${EXTRA_CMAKE_FLAGS} \
Expand Down

0 comments on commit f60c281

Please sign in to comment.