6 if [[ ! "${CROSS}" =~ ^(aarch64|x86_64) ]]; then
7 echo "Platform ${CROSS} is not supported"
8 echo "Expected either aarch64 or x86_64."
12 if [[ ! $(which ${CROSS}-w64-mingw32-clang) ]]; then
13 echo "llvm-mingw is not installed, please download it from https://github.com/mstorsjo/llvm-mingw/releases"
17 # Make build directories
18 mkdir ${ROOT}/${CROSS}-w64-mingw32-build
21 mkdir ${ROOT}/${CROSS}-w64-mingw32
25 cd ${ROOT}/${CROSS}-w64-mingw32-build
26 #CC=${CROSS}-w64-mingw32-gcc CXX=${CROSS}-w64-mingw32-g++
27 ${ROOT}/openssl/Configure --cross-compile-prefix=${CROSS}-w64-mingw32- --prefix=${ROOT}/${CROSS}-w64-mingw32 no-shared no-asm mingw64 --api=1.1.1
31 # Create symlink for compatibility
32 cd ${ROOT}/${CROSS}-w64-mingw32
35 # Remove build directore
37 rm -rf ${ROOT}/${CROSS}-w64-mingw32-build