build with 2.9 Also fix test script bug when the target dir does not exist. Change-Id: Ic7f74c8b98f90d14c25ef5fe692898ace272429d