Add MinGW 64-bit

This commit is contained in:
Jean Pierre Cimalando 2020-02-02 21:25:08 +01:00
parent d3b0cef35f
commit e975b35a93
5 changed files with 12 additions and 3 deletions

View file

@ -10,6 +10,11 @@ jobs:
- CROSS_COMPILE=mingw32
- CONTAINER=cross
- os: linux
env:
- CROSS_COMPILE=mingw64
- CONTAINER=cross
- os: linux
arch: amd64
dist: bionic

View file

@ -7,7 +7,7 @@ cmake_dir="cmake-3.13.0-${TRAVIS_OS_NAME}-${TRAVIS_CPU_ARCH}"
cmake_arc="${cmake_dir}.tar.gz"
cmake_url="https://github.com/sfztools/cmake/releases/download/${TRAVIS_OS_NAME}/${cmake_arc}"
if [[ ${CROSS_COMPILE} == "mingw32" ]]; then
if [[ ${CROSS_COMPILE} == "mingw32" || ${CROSS_COMPILE} == "mingw64" ]]; then
buildenv bash -c "echo Hello from container" # ensure to start the container
docker cp "$container":/etc/pacman.conf pacman.conf
cat >>pacman.conf <<EOF

View file

@ -8,7 +8,7 @@ if [[ ${TRAVIS_OS_NAME} == "linux" || ${TRAVIS_OS_NAME} == "osx" ]]; then
fi
# buildenv runs a command in host machine or container, depending on build
if [[ ${CROSS_COMPILE} == "mingw32" ]]; then
if [[ ${CROSS_COMPILE} == "mingw32" || ${CROSS_COMPILE} == "mingw64" ]]; then
buildenv() {
setup_container archlinux
docker exec -w "$(pwd)" -i -t "$container" "$@"

View file

@ -3,7 +3,7 @@
set -ex
. .travis/environment.sh
if [[ ${CROSS_COMPILE} == "mingw32" ]]; then
if [[ ${CROSS_COMPILE} == "mingw32" || ${CROSS_COMPILE} == "mingw64" ]]; then
buildenv pacman -Sqy --noconfirm
buildenv pacman -Sq --noconfirm base-devel wget mingw-w64-cmake mingw-w64-gcc mingw-w64-pkg-config mingw-w64-libsndfile
buildenv i686-w64-mingw32-gcc -v && buildenv i686-w64-mingw32-g++ -v && buildenv i686-w64-mingw32-cmake --version

View file

@ -9,6 +9,10 @@ if [[ ${CROSS_COMPILE} == "mingw32" ]]; then
buildenv i686-w64-mingw32-cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=${PWD}/${INSTALL_DIR} -DSFIZZ_JACK=OFF ..
buildenv make -j
elif [[ ${CROSS_COMPILE} == "mingw64" ]]; then
buildenv x86_64-w64-mingw32-cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=${PWD}/${INSTALL_DIR} -DSFIZZ_JACK=OFF ..
buildenv make -j
elif [[ ${TRAVIS_OS_NAME} == "linux" ]]; then
buildenv cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=${PWD}/${INSTALL_DIR} ..