Hi Li,

I was just writing this.

AFAIK, currently the Arrow C++ build system does not take prebuilt Substrait 
C++ classes. The usual way is rebuilding Arrow C++ with a custom Substrait 
repository, which is done by setting ARROW_SUBSTRAIT_URL to a local Substrait 
repository. You can download this repository offline and make it available to 
your internal build system. With this, the Arrow C++ build system 
auto-generates the Substrait C++ classes for the local Substrait repository and 
builds into "libarrow_bundled_dependencies.a". I wouldn't recommend doing these 
auto-generation and build steps on your own, as you'd have to change the Arrow 
C++ build system, and specifically 
"cpp/cmake_modules/ThirdpartyToolchain.cmake", to enable this.


Yaron.
________________________________
From: Jeroen van Straten <jeroen.van.stra...@gmail.com>
Sent: Monday, July 18, 2022 2:27 PM
To: dev@arrow.apache.org <dev@arrow.apache.org>
Subject: Re: [C++] Question about substrait dependency in C++

Hi,

I'm not sure I completely understand what you're trying to do, but if lack
of internet access is the only problem, I think you should just be able to
override the URL it tries to download by setting the ARROW_SUBSTRAIT_URL
environment variable to some local file:// URL. I think it should work as
long as the hash matches what Arrow's build system expects from
thirdparty/versions.txt.

I'm not sure why you're not seeing the library. With `--preset
ninja-debug`, I'm getting a libsubstrait.a in build/debug. I'm not familiar
enough with Arrow's build system to provide more help there.

Regards,
Jeroen

On Mon, 18 Jul 2022 at 18:00, Li Jin <ice.xell...@gmail.com> wrote:

> Hello!
>
> I am working on integrating the latest Arrow C++ into our internal build
> system. Currently I am planning to build substrait C++ classes
> independently and provide header locations and so files to the Arrow
> Cmakefile - I wonder if that is a good approach? (We cannot download the
> substrait tarball in the internal build system when building Arrow)
>
> Also, I don't see a libsubstrait.so or libsubstrait.a in the build
> directory - is that statically linked?
>
> Thanks,
> Li
>

Reply via email to