@Samuel-Lehman , Not sure what is going on but i was able to build your example with the following command on VOXL2. I had to comment out #include "hello_cross.h" because i did not have it.
voxl2:~$ gcc -O2 -Wall voxl_io_uart_test.c -o voxl_io_uart_test -lmodal_pipe -lvoxl_io -L/usr/lib64 voxl_io_uart_test.c:14:12: warning: 'opt' defined but not used [-Wunused-variable] static int opt = 0; ^~~ voxl2:~$I am not sure what's going on, you can enable verbose CMake file to see what compile command CMake is generating and compare that to the above.
Alex