aboutsummaryrefslogtreecommitdiffstats
path: root/.travis.yml
blob: fcf79c52ea430d9da41588f1c74ffd6674c8407b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
dist: xenial
language: minimal

env:
  - DOCKER=centos8
  - DOCKER=centos7
  - DOCKER=xenial
  - DOCKER=bionic
  - DOCKER=focal

matrix:
  include:
  - language: cpp
    env:
    before_install:
    - sudo apt-get install -y libgnutls-dev libfltk1.3-dev fluid
    - sudo apt-get install -y libxtst-dev libxdamage-dev libxfixes-dev libxrandr-dev
    script:
    - cmake -DCMAKE_BUILD_TYPE=Debug . && make && make tarball

  - language: cpp
    os: windows
    env:
    # From https://docs.travis-ci.com/user/reference/windows/
    before_install:
    - |-
      choco install --no-progress -y innosetup
      [[ ! -f C:/tools/msys64/msys2_shell.cmd ]] && rm -rf C:/tools/msys64
      choco uninstall -y mingw
      choco upgrade --no-progress -y msys2
      export msys2='cmd //C RefreshEnv.cmd '
      export msys2+='& set MSYS=winsymlinks:nativestrict '
      export msys2+='& C:\\tools\\msys64\\msys2_shell.cmd -defterm -no-start'
      export mingw64="$msys2 -mingw64 -full-path -here -c "\"\$@"\" --"
      export msys2+=" -msys2 -c "\"\$@"\" --"
      $msys2 pacman --sync --noconfirm --needed mingw-w64-x86_64-toolchain
      $msys2 pacman --sync --noconfirm --needed mingw-w64-x86_64-fltk mingw-w64-x86_64-libjpeg-turbo mingw-w64-x86_64-gnutls mingw-w64-x86_64-pixman
      taskkill //IM gpg-agent.exe //F  # https://travis-ci.community/t/4967
      export PATH=/C/tools/msys64/mingw64/bin:$PATH
      export MAKE=mingw32-make  # so that Autotools can find it
    script:
    - cmake -G "MSYS Makefiles" -DCMAKE_BUILD_TYPE=Debug -DCMAKE_MAKE_PROGRAM=mingw32-make -DCMAKE_C_COMPILER=gcc -DCMAKE=CXX_COMPILER=g++ . && mingw32-make && mingw32-make installer winvnc_installer
    before_cache:
    - |-
      # https://unix.stackexchange.com/a/137322/107554
      $msys2 pacman --sync --clean --noconfirm
    cache:
      directories:
      - $HOME/AppData/Local/Temp/chocolatey
      - /C/tools/msys64

  - language: cpp
    os: osx
    # The default image is buggy ATM, use the latest
    osx_image: xcode11.5
    env:
    addons:
      homebrew:
        packages:
          - gettext
          - fltk
    before_install:
    script:
    - cmake -DCMAKE_BUILD_TYPE=Debug . && make && make dmg

  - language: java
    # compile with java 8 for backwards compatibility
    dist: xenial
    env:
    jdk: openjdk8
    before_install:
    - sudo apt-get -y install openjdk-8-jdk
    addons:
      apt:
        update: true
    script:
    - cd java && cmake . && make

before_install:
  - docker build -t tigervnc/$DOCKER .travis/$DOCKER
script:
  - .travis/$DOCKER/build.sh