How to fix GCC fatal error: arrow/api.h: No such file or directory on Ubuntu
Problem:
While compiling your C++ application, you see an error message like
src/main.cpp:3:10: fatal error: arrow/api.h: No such file or directory
3 | #include <arrow/api.h>
Solution
You need to install the Arrow C++ libraries.
On Ubuntu, you can do that using
sudo apt update
sudo apt install -y -V ca-certificates lsb-release wget
wget https://apache.jfrog.io/artifactory/arrow/$(lsb_release --id --short | tr 'A-Z' 'a-z')/apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb
sudo apt install -y -V ./apache-arrow-apt-source-latest-$(lsb_release --codename --short).deb
sudo apt update -y
sudo apt -y install libarrow-dev
For other operating systems, see the official Arrow installation guide,