Browse Source

Add travis config and scripts

pull/72/head
falkTX 4 years ago
parent
commit
03f0b3b8b8
7 changed files with 114 additions and 0 deletions
  1. +18
    -0
      .travis.yml
  2. +10
    -0
      .travis/before_install.sh
  3. +15
    -0
      .travis/install.sh
  4. +14
    -0
      .travis/script-linux.sh
  5. +17
    -0
      .travis/script-macos.sh
  6. +20
    -0
      .travis/script-win32.sh
  7. +20
    -0
      .travis/script-win64.sh

+ 18
- 0
.travis.yml View File

@@ -0,0 +1,18 @@
os:
- linux

sudo: required
dist: trusty

languages: c++
compiler: gcc

before_install:
- sh ${TRAVIS_BUILD_DIR}/.travis/before_install.sh
install:
- sh ${TRAVIS_BUILD_DIR}/.travis/install.sh
script:
- sh ${TRAVIS_BUILD_DIR}/.travis/script-linux.sh
- sh ${TRAVIS_BUILD_DIR}/.travis/script-macos.sh
- sh ${TRAVIS_BUILD_DIR}/.travis/script-win32.sh
- sh ${TRAVIS_BUILD_DIR}/.travis/script-win64.sh

+ 10
- 0
.travis/before_install.sh View File

@@ -0,0 +1,10 @@
#!/bin/bash

set -e

sudo add-apt-repository ppa:kxstudio-debian/kxstudio -y
sudo add-apt-repository ppa:kxstudio-debian/mingw -y
sudo add-apt-repository ppa:kxstudio-debian/toolchain -y
sudo apt-get update -qq
sudo apt-get install kxstudio-repos
sudo apt-get update -qq

+ 15
- 0
.travis/install.sh View File

@@ -0,0 +1,15 @@
#!/bin/bash

set -e

sudo apt-get install -y \
g++ \
pkg-config \
libjack-jackd2-dev \
libgl1-mesa-dev \
libx11-dev \
apple-x86-setup \
mingw32-x-gcc \
mingw32-x-pkgconfig \
mingw64-x-gcc \
mingw64-x-pkgconfig

+ 14
- 0
.travis/script-linux.sh View File

@@ -0,0 +1,14 @@
#!/bin/bash

set -e

# Preparation
_FLAGS="-Werror"
export CFLAGS="${_FLAGS}"
export CXXFLAGS="${_FLAGS}"

# Start clean
make clean >/dev/null

# Build now
make

+ 17
- 0
.travis/script-macos.sh View File

@@ -0,0 +1,17 @@
#!/bin/bash

set -e

# Preparation
_FLAGS="-Werror"
export CFLAGS="${_FLAGS}"
export CXXFLAGS="${_FLAGS}"
export MACOS_OLD=true
export CROSS_COMPILING=true
. /usr/bin/apple-cross-setup.env

# Start clean
make clean >/dev/null

# Build now
make

+ 20
- 0
.travis/script-win32.sh View File

@@ -0,0 +1,20 @@
#!/bin/bash

set -e

# Preparation
_FLAGS="-DPTW32_STATIC_LIB -Werror"
_PREFIX=i686-w64-mingw32
export AR=${_PREFIX}-ar
export CC=${_PREFIX}-gcc
export CXX=${_PREFIX}-g++
export CFLAGS="${_FLAGS}"
export CXXFLAGS="${_FLAGS}"
export PATH=/opt/mingw32/${_PREFIX}/bin:/opt/mingw32/bin:${PATH}
export CROSS_COMPILING=true

# Start clean
make clean >/dev/null

# Build now
make

+ 20
- 0
.travis/script-win64.sh View File

@@ -0,0 +1,20 @@
#!/bin/bash

set -e

# Preparation
_FLAGS="-DPTW32_STATIC_LIB -Werror"
_PREFIX=x86_64-w64-mingw32
export AR=${_PREFIX}-ar
export CC=${_PREFIX}-gcc
export CXX=${_PREFIX}-g++
export CFLAGS="${_FLAGS}"
export CXXFLAGS="${_FLAGS}"
export PATH=/opt/mingw64/${_PREFIX}/bin:/opt/mingw64/bin:${PATH}
export CROSS_COMPILING=true

# Start clean
make clean >/dev/null

# Build now
make

Loading…
Cancel
Save