libchewing
libchewing copied to clipboard
build: cmake: support cross compiling with qemu
From version 3.6, CMake supports cross compiling to other architectures with an emulator. In order to do that, the command must be starts with a target built by CMake.
Let move the creation of data directory to configure phase, change the command to exactly what CMake need, and use WORKING_DIRECTORY in add_custom_command instead of using chdir. All of those commands are available at CMake 2.8.8 (the oldest version that is supported).