Follow the steps in the official ZMK document to setup build environment.
Add the extra kscan module:
west build -b nice_nano_v2 -- \
-DSHIELD=hhkb -DZEPHYR_EXTRA_MODULES=$WORKSPACE_PATH/config/drivers/ \
-DZMK_CONFIG=$WORKSPACE_PATH/config