[SOLVED] Error building Blender as a Python module on Ubuntu 20.04, missing a header file

Hello,

I have trouble building Blender as a Python module on Ubuntu 20.04, according to the documentation on Building Blender/Other/BlenderAsPyModule - Blender Developer Wiki.

After following the manual, that is, cloning from GitHub to blender-git/blender and using svn to blender-git/lib, and installing gcc-11 as I had just gcc-9, and running make update in blender-git/blender, the command make bpy -j 1 produces this output:


-- Generating done
-- Build files have been written to: /home/tomtom/git/blender-git/build_linux_bpy

Building Blender ...
make -s -C "/home/tomtom/git/blender-git/build_linux_bpy" -j 12 install
Consolidate compiler generated dependencies of target bf_intern_clog
Consolidate compiler generated dependencies of target bf_intern_guardedalloc
[  0%] Generating libwayland/xdg-activation-v1-client-protocol.h
Consolidate compiler generated dependencies of target bf_intern_memutil
Consolidate compiler generated dependencies of target datatoc
Consolidate compiler generated dependencies of target bf_intern_opencolorio
Consolidate compiler generated dependencies of target bf_intern_sky
Consolidate compiler generated dependencies of target bf_intern_dualcon
Could not open input file: No such file or directory
make[3]: *** [intern/ghost/CMakeFiles/bf_intern_ghost.dir/build.make:110: intern/ghost/libwayland/xdg-activation-v1-client-protocol.h] Error 1
[  0%] Built target bf_intern_clog
make[2]: *** [CMakeFiles/Makefile2:3048: intern/ghost/CMakeFiles/bf_intern_ghost.dir/all] Error 2
make[2]: *** Waiting for unfinished jobs....
Consolidate compiler generated dependencies of target bf_intern_eigen
[  0%] Built target bf_intern_memutil
[  0%] Built target bf_intern_mikktspace
[  0%] Built target datatoc
[  0%] Built target bf_intern_guardedalloc
Consolidate compiler generated dependencies of target bf_intern_iksolver
[  1%] Built target bf_intern_sky
[  1%] Built target bf_intern_opencolorio
[  1%] Built target bf_intern_dualcon
[  1%] Built target bf_intern_eigen
[  1%] Built target bf_intern_iksolver
Consolidate compiler generated dependencies of target bf_intern_libmv
[  2%] Built target bf_intern_libmv
make[1]: *** [Makefile:166: all] Error 2
make: *** [GNUmakefile:368: all] Error 2

Any clues?

I have also tried running the script blender-git/blender/build_files/build_environment/install_deps.sh, but this one gives me another error:

Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libfontconfig1-dev' instead of 'libfontconfig-dev'
E: Unable to locate package libdecor-0-dev
E: Unable to locate package libshaderc-dev
E: Unable to locate package libpystring-dev
ERROR! apt-get failed to install requested packages, exiting.

I don’t know if install_deps.sh is supposed to run on older versions of Ubuntu, but I assume it is not important as the first error mentions a file simply missing in the git repository.

There was an issue introduced yesterday, it should be fixed after this:

2 Likes

Works fine now, thank you!