support target-driven cross-compilation