AOSP Build Instructions fail

The following AOSP Build Guide does not successfully build. Here is the failure output:

1 warning generated.
[ 3% 2996/79043] Yacc: ss <= external/iproute2/misc/ssfilter.y
external/iproute2/misc/ssfilter.y: conflicts: 31 shift/reduce
[ 7% 5723/79043] build out/target/product/db410c/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_opcodes.h
FAILED: out/target/product/db410c/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_opcodes.h
/bin/bash -c “python external/mesa3d/src/compiler/nir/nir_opcodes_h.py external/mesa3d/src/compiler/nir/nir_opcodes.py > out/target/product/db410c/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_opcodes.h”
Traceback (most recent call last):
File “external/mesa3d/src/compiler/nir/nir_opcodes_h.py”, line 44, in
from mako.template import Template
ImportError: No module named mako.template
[ 7% 5724/79043] build out/target/product/db410c/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_builder_opcodes.h
FAILED: out/target/product/db410c/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_builder_opcodes.h
/bin/bash -c “python external/mesa3d/src/compiler/nir/nir_builder_opcodes_h.py external/mesa3d/src/compiler/nir/nir_opcodes.py > out/target/product/db410c/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_builder_opcodes.h”
Traceback (most recent call last):
File “external/mesa3d/src/compiler/nir/nir_builder_opcodes_h.py”, line 47, in
from mako.template import Template
ImportError: No module named mako.template

failed to build some targets (09:15 (mm:ss))

Update: Seems that python-mako was not installed and is now a dependency

hi Mark,

thanks for your message. We’ve just restarted some engineering work on AOSP for DB410c, and I hope these issues will be fixed soon. This wiki was made before the Android O hit the master branch, and there is a bit of rework to do.

I tried to sync the manifest to the nougat-mr2-release tag and build but I get the following error:

In file included from external/mesa3d/src/egl/drivers/dri2/platform_android.c:38:
external/mesa3d/src/egl/drivers/dri2/egl_dri2.h:62:10: fatal error: 'system/window.h' file not found
#include <system/window.h>
         ^~~~~~~~~~~~~~~~~
1 error generated.

The manifest didn’t seem to provide an EGL binding for the window system.

Update:

cd .repo/manifests
git checkout nougat-mr2-release
cd ../../
repo sync -j24
source build/envsetup.sh
lunch db410c
make -j24

That didn’t seem to update all the repos to nougat-mr2-release.

Retrying with
repo init using -b nougat-mr2-release

Would it be possible to create labelled snapshots that are known to build with manifest files that use specific git hashes or tags for the various repos?

I’m trying to move to this as a base for a robotics project vs the downstream kernel and a marshmellow BSP for 410C.

there was never really a serious engineering work to bring AOSP and DB410c until recently… once we get things in place and working, we can think about doing something like that, but right now the focus is to get basic enablement with master branch, and this is right that master branch moves quickly…

I know you are working on this, but I’ll provide a status of how far I was able to get:

Attempted to build but there is some selinux issue:

source build/envsetup.sh
lunch db410c
make

...
FAILED: out/target/product/db410c/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests 
/bin/bash -c "(out/host/linux-x86/bin/sepolicy_tests -l out/host/linux-x86/lib64/libsepolwrap.so -f out/target/product/db410c/obj/ETC/plat_file_contexts_intermediates/plat_file_contexts -f out/target/product/db410c/obj/ETC/nonplat_file_contexts_intermediates/nonplat_file_contexts -p out/target/product/db410c/obj/ETC/sepolicy_intermediates/sepolicy ) && (touch out/target/product/db410c/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests )"
The following types on /sys/kernel/debug/ /sys/kernel/tracing must be associated with the "debugfs_type" attribute: device