improve native lib support