0

I'm trying to do something simple: save data in Apache Parquet format in C++. However, I cannot figure out how to properly link the Apache Arrow library to my project in order to use the necessary #include<".h"> headers. I haven't used C++ in decades and I wasn't very good even back then, so this is out of my league.

I've used NuGet (for pthreads library) and have physically linked libraries using the Project Properties of Visual Studio 2019 on Windows 10 (for Npcap library), but following the Apache Arrow instructions (https://arrow.apache.org/docs/developers/cpp/index.html) is currently beyond me.

So far I've installed Git and CMake and I can get CMake to put arrow VS Project files into a ./build folder I've created, but I cannot run any example nor can I link the header files. I've tried adding a VS Project to the 'arrow' solution in the build folder, but I never got that code to compile. In previous attempts I've used CMake through VS as well as used Ninja to try and build the libraries. But for the most part, I am straight-up guessing on pretty much every step of this process.

Some questions that come to mind are: do I even want to specify the "Visual Studio 16 2019" generator to CMake or should I do something different? How do I use the files that were built? Do I need to modify the CMakeLists.txt files included in the arrow download? Do I need to write a script for the build or is it preferable to run from the command line?

Regarding the Optional Components of the build; I'm pretty sure I should have -DARROW_PARQUET=ON but what about -DARROW_PLASMA=ON? It's related to Shared Memory Object Store and in order to save as a parquet file I'll need to load my data into an arrow Table in the memory, so is this applicable? What about the other 50 or so options?

I apologize in advance for my naiveté on this subject and appreciate any help or advice. Thank you.

1liis
  • 13
  • 1
  • 5
  • Update: I've copied the cmake call from this SO question (https://stackoverflow.com/questions/70082247/how-to-use-apache-arrow-to-write-files-in-parquet-format-on-windows-using-c) and have found the arrow_static.lib and parquet_static.lib (in arrow/cpp/build/release/Release). – 1liis Feb 27 '22 at 23:42
  • I know those reading this will not like my solution, but I decided to install Linux. It's actually faster to pick up Ubuntu than it is to get this working in Windows. I mean, I'm still running into constant errors, but at least the libraries are linked. – 1liis Mar 16 '22 at 16:57

0 Answers0