forked from NREL/ssc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
69 lines (56 loc) · 4.78 KB
/
.travis.yml
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
dist: Xenial
sudo: required
language: c++
#cache: ccache
os:
- linux
- osx
compiler:
- gcc
settings:
- maximum_number_of_builds --set 1
before_script:
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then wget -q https://github.com/wxWidgets/wxWidgets/releases/download/v3.1.1/wxWidgets-3.1.1.tar.bz2; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then tar jxf wxWidgets-3.1.1.tar.bz2; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then cd wxWidgets-3.1.1; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then (./configure --prefix=$HOME/wx-3.1.1 --enable-shared=no --enable-stl=yes --enable-debug=no --with-gtk=2 --with-libjpeg=builtin --with-libpng=builtin --with-regex=builtin --with-libtiff=builtin --with-zlib=builtin --with-expat=builtin --without-libjbig --without-liblzma --without-gtkprint --with-libnotify=no --with-libmspack=no --with-gnomevfs=no --with-opengl=yes --with-sdl=no --with-cxx=11); fi
# - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then (./configure --prefix=$HOME/wx-3.1.1 --enable-stl=yes --enable-debug=no --enable-shared=no --with-cocoa --enable-macosx_arch=x86_64 --enable-unicode --enable-webview --with-cxx=11 --with-macosx-version-min=10.9 --with-libjpeg=builtin --with-libpng=builtin --with-regex=builtin --with-libtiff=builtin --with-zlib=builtin --with-expat=builtin --disable-qtkit --disable-mediactrl); fi
# - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then (./configure --prefix=$HOME/wx-3.1.1 --enable-stl=yes --enable-debug=no --enable-shared=no --enable-macosx_arch=x86_64 --with-cxx=11 --with-macosx-version-min=10.9 --with-libjpeg=builtin --with-libpng=builtin --with-regex=builtin --with-libtiff=builtin --with-zlib=builtin --with-expat=builtin --without-libjbig --without-liblzma --without-gtkprint --with-libnotify=no --with-libmspack=no --with-gnomevfs=no --with-opengl=yes --with-sdl=no --with-cxx=11 --disable-qtkit --disable-mediactrl); fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then make -j4 all install; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then ln -s $HOME/wx-3.1.1/bin/wx-config $HOME/wx-3.1.1/bin/wx-config-3; fi
- user=$(echo $TRAVIS_REPO_SLUG | sed 's,/.*$,,')
- (cd ../ && pwd)
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then git clone --depth=1 https://github.com/google/googletest /home/travis/build/$user/googletest; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export GTEST=/home/travis/build/$user/googletest; mkdir ${GTEST}/build; cd ${GTEST}/build; cmake -DCMAKE_CXX_FLAGS=-std=c++11 ..; make;fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export LKDIR=/home/travis/build/$user/lk; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export WEXDIR=/home/travis/build/$user/wex; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export SSCDIR=/home/travis/build/$user/ssc; fi
# - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export GTEST=/Users/travis/build/$user/googletest/googletest; fi
# - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export LKDIR=/Users/travis/build/$user/lk; fi
# - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export WEXDIR=/Users/travis/build/$user/wex; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then git clone --depth=1 https://github.com/google/googletest /Users/travis/build/$user/googletest; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export GTEST=/Users/travis/build/$user/googletest; mkdir ${GTEST}/build; cd ${GTEST}/build; cmake -DCMAKE_CXX_FLAGS=-std=c++11 ..; make;fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export SSCDIR=/Users/travis/build/$user/ssc; fi
# - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then git clone https://github.com/google/googletest /Users/travis/build/$user/googletest; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then git clone https://github.com/$user/lk $LKDIR; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then git clone https://github.com/$user/wex $WEXDIR; fi
script:
# - export PATH=$PATH:$HOME/wx-3.1.1/bin
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then make -j4 -C $LKDIR/build_linux; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then make -j4 -C $WEXDIR/build_linux; fi
# - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then make -j4 -C $SSCDIR/build_linux; fi
- mkdir ${SSCDIR}/build && cd ${SSCDIR}/build
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then cmake .. -DCMAKE_BUILD_TYPE=Release -Dskip_tools=1 && make; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cmake .. -DCMAKE_BUILD_TYPE=Release -Dskip_tools=1 && make; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then test/Test; fi
install:
#- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt-get install -y libgtk2.0-dev libgl1-mesa-dev mesa-common-dev freeglut3-dev libcurl4-openssl-dev libc6; fi
#- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install ccache; fi
#- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export PATH="/usr/local/opt/ccache/libexec:$PATH"; fi
branches:
only:
- release
- develop
- patch
- PySAM
- wind_pruf