Skip to content

[R] Failure to install from source when cmake is found but is too old #43612

Description

@rp2927

Describe the bug, including details regarding any error messages, version, and platform.

Hi,

Attempting to install "arrow" on R v4.4 produces this error:

install.packages('arrow')
[...]

  • installing source package ‘arrow’ ...
    ** package ‘arrow’ successfully unpacked and MD5 sums checked
    ** using staged installation
    *** pkg-config found.
    *** Found local C++ source: 'tools/cpp'
    *** Building libarrow from source
    For build options and troubleshooting, see the install guide:
    https://arrow.apache.org/docs/r/articles/install.html
    **** Not using cmake found at /usr/bin/cmake
    Error in .make_numeric_version(x, strict, .standard_regexps()$valid_numeric_version) :
    invalid non-character version specification 'x' (type: double)
    Calls: build_libarrow ... as.numeric_version -> numeric_version -> .make_numeric_version
    Execution halted
    [...]

The failure seems to occur in r/tools/nixlibs.R, in find_cmake, at line 718:

if (found_version > 0) {

which should rather be:

    if (found_version > "0") {

I hope this helps.
Razvan

Component(s)

R

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions