Update ap_build.sh