Igalia / acacia

Library for inspecting accessibility APIs
https://igalia.github.io/acacia
GNU Lesser General Public License v2.1
8 stars 1 forks source link

AT-SPI Python module fails to build on CI runner #195

Open elima opened 7 months ago

elima commented 7 months ago

Acacia fails to build on a github runner when -DACACIA_PYTHON=ON is passed.

SWIG complains that it can't find std_unique_ptr.i. Same version of SWIG (4.1.0) builds fine on my Debian laptop. Actually, we are building SWIG 4.1.0 from source in the CI runner precisely because the shipped version (4.0.1) doesn't have support for unique pointers.

Oddly enough, NodeJS does build fine on the CI runner, pointing at an issue specific to SWIG and the Python environment.

 [  5%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_node.cc.o
[ 10%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_action_interface.cc.o
[ 15%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_component_interface.cc.o
[ 20%] Swig compile acacia_atspi.i for python
[ 25%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_document_interface.cc.o
[ 30%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_hyperlink_interface.cc.o
[ 35%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_table_interface.cc.o
[ 40%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_table_cell_interface.cc.o
[ 45%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_text_interface.cc.o
[ 50%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/atspi_value_interface.cc.o
[ 55%] Building CXX object lib/atspi/CMakeFiles/acacia_atspi.dir/linux_utils.cc.o
/home/runner/work/acacia/acacia/lib/atspi/acacia_atspi.i:18: Error: Unable to find 'std_unique_ptr.i'
make[2]: *** [lib/atspi/CMakeFiles/acacia_atspi_python_swig_compilation.dir/build.make:76: lib/atspi/CMakeFiles/acacia_atspi_python.dir/acacia_atspiPYTHON.stamp] Error 1
make[2]: *** Deleting file 'lib/atspi/CMakeFiles/acacia_atspi_python.dir/acacia_atspiPYTHON.stamp'
make[1]: *** [CMakeFiles/Makefile2:1021: lib/atspi/CMakeFiles/acacia_atspi_python_swig_compilation.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 60%] Linking CXX shared library libacacia_atspi.so
[ 60%] Built target acacia_atspi
make: *** [Makefile:146: all] Error 2
Error: Process completed with exit code 2.
elima commented 7 months ago

BTW, to test this, change the cmake line in any workflow that builds acacia, and add -DACACIA_PYTHON=on.

spectranaut commented 6 months ago

Wow this is confusing... I had this same error on my build machine (running pop!os), but the reason for that was that SWIG was too old, so ultimately I had to get and install swig from source. But after I did that, I could build just fine.