If you want to compile OpenNI2 from github.com/orbbec/OpenNI2.git, you need to use the orbbec_dev branch, which adds the orbbec driver. You also need to use the orbbec.ini provided. The pre-compiled OpenNI2 binaries include an additional filter (not found in the github source) that is necessary for correct depth data results. If OpenNI2 compiled from source (of the correct branch) works fine for you, you can use it too.
For compiling Astra SDK, update the .gitmodules per https://github.com/orbbec/astra/pull/4/files and then make sure you do:
git submodule update --init --recursive
The vendor/shinyprofiler and some other things will then work.