Following the instructions in the Aosp-Node-Prebuilts README, I cloned the repository in the external directory of the Orange Pi 4 LTS RK3399-Android8.1 tree (which I have successfully built), and successfully ran make arm64. But because I build using the build.sh included in the Orange Pi 4 LTS Android sources, my shell is not "initialised with the buildenv and lunch combo".
The README states:
If you want the Android.mk to be executed automatically, add it as a dependency of another project.
How do I add Aosp-Node-Prebuilts as a dependency of another project?
I tried adding "Aosp-Node-Prebuilts" to PRODUCT_PACKAGES in build/make/target/product/base.mk, but that didn't work.
I tried searching for how other packages in the external directory with Android.mk files are added as a dependency, but didn't find anything. (I searched for strace and tcpdump--both of which I confirmed are in /system/xbin on the target.)
I did the equivalent of "adding Aosp-Node-Prebuilts as a dependency of another project" by adding
nodetoPRODUCT_PACKAGESinbuild/make/target/product/base.mk:I believe the package name is "node" because
LOCAL_MODULEis set tonodein the Aosp-Node-Prebuilts Android.mk file. I confirmed this worked by adding this toAndroid.mk:...and I confirmed this was echoed when I ran the build:
I also confirmed that
target/nodein theexternal/Aosp-Node-Prebuiltsdirectory was copied toout/target/product/rk3399/system/bin. And I mounted thesystem.imgon Linux and confirmed it is in/system/bin.