Skip to content

[C++][R] package build fails after simdjson introduction due to system simdjson pickup #50581

Description

@thisisnic

The macOS cran-release, ubuntu-r-only-r, and ubuntu-r-only-r (SYSTEM deps) nightly jobs all fail to compile Arrow C++ after the simdjson introduction in #50469. All are caused by the R package build interacting badly with system simdjson.

1. macOS cran-release

The build picks up Homebrew simdjson from /opt/homebrew/include/simdjson.h and compiles it against the old macOS 11.3 SDK used for CRAN binary compatibility. The simdjson header uses std::numeric_limits patterns incompatible with that SDK:

/opt/homebrew/include/simdjson.h:67912: error: class template argument 'T' for template
'numeric_limits' does not satisfy the constraint ...
20 errors generated.

Failed run: https://github.com/ursacomputing/crossbow/actions/runs/29799266759/job/88536926914

2. ubuntu-r-only-r (AUTO deps)

The build finds the system simdjson shared library and tries to bundle it into a static archive, which fails:

/usr/bin/ar: /usr/lib/x86_64-linux-gnu/libsimdjson.so.9.0.0: file format not recognized

Failed run: https://github.com/ursacomputing/crossbow/actions/runs/29799265099/job/88536922431

3. ubuntu-r-only-r (SYSTEM deps)

The build uses ARROW_DEPENDENCY_SOURCE=SYSTEM. The Docker image installs libsimdjson-dev from Ubuntu 22.04 apt repos, but that version is older than the required >= 3.0.0:

Couldn't find simdjson >= 3.0.0

The per-dependency override simdjson_SOURCE=BUNDLED is ignored because ARROW_DEPENDENCY_SOURCE=SYSTEM takes precedence.

Failed run: https://github.com/ursacomputing/crossbow/actions/runs/29799266838/job/88536927144

Fix

Failures 1 and 2: Add simdjson_SOURCE = "BUNDLED" unconditionally in r/tools/nixlibs.R (around line 590), same pattern already used for Boost and lz4 on macOS.

Failure 3: Either remove libsimdjson-dev from the CI Docker image apt install list (since the available version is too old anyway), or update to a base image with simdjson >= 3.0.0.

Component: R

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions