Solve cross-compiling issue