forked from OSGeo/PROJ
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
139 lines (125 loc) · 3.73 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
# This is the config file for building proj.4 and running its test suite
# with Travis-ci.org
language: c
services:
docker
compiler:
- gcc
# - clang
os:
- linux
# - osx
matrix:
exclude:
- os: osx
compiler: gcc
before_install: ./travis/before_install.sh
install:
# prepare build files
- ./autogen.sh
# cmake build
- mkdir build_cmake
- cd build_cmake
- cmake .. -DCMAKE_INSTALL_PREFIX=/tmp/proj_cmake_install
- make -j3
- make install
- find /tmp/proj_cmake_install
- cd ..
# autoconf build
- mkdir build_autoconf
- cd build_autoconf
- ../configure --prefix=/tmp/proj_autoconf_install
- make -j3
- make install
- make dist-all
- find /tmp/proj_autoconf_install
- make check
# Check consistency of generated tarball
- TAR_FILENAME=`ls *.tar.gz`
- TAR_DIRECTORY=`basename $TAR_FILENAME .tar.gz`
- tar xvzf $TAR_FILENAME
- cd $TAR_DIRECTORY
- ./configure --prefix=/tmp/proj_autoconf_install_from_dist_all
- make -j3
- make install
- make dist-all
- make check
- CURRENT_PWD=`pwd`
- cd /tmp/proj_autoconf_install
- find | sort > /tmp/list_proj_autoconf_install.txt
- cd /tmp/proj_autoconf_install_from_dist_all
- find | sort > /tmp/list_proj_autoconf_install_from_dist_all.txt
- cd $CURRENT_PWD
# The list of file is not identical. See http://lists.maptools.org/pipermail/proj/2015-September/007231.html
# - diff -u /tmp/list_proj_autoconf_install.txt /tmp/list_proj_autoconf_install_from_dist_all.txt
- cd ..
#
- cd ..
# Now with grids
- wget http://download.osgeo.org/proj/proj-datumgrid-1.5.zip
- cd nad
- unzip -o ../proj-datumgrid-1.5.zip
- cd ..
# cmake build with grids
- mkdir build_cmake_nad
- cd build_cmake_nad
- cmake .. -DCMAKE_INSTALL_PREFIX=/tmp/proj_cmake_install_nad
- make -j3
- make install
- find /tmp/proj_cmake_install_nad
- cd ..
# autoconf build with grids
- mkdir build_autoconf_nad
- cd build_autoconf_nad
- ../configure --prefix=/tmp/proj_autoconf_install_nad
- make -j3
- make install
- find /tmp/proj_autoconf_install_nad
- make check
- cd src
- make multistresstest
- make test228
- cd ..
- PROJ_LIB=../nad src/multistresstest
- cd ..
# autoconf build with grids and coverage
- if [ $TRAVIS_OS_NAME == "osx" ]; then
CFLAGS="-DPJ_SELFTEST --coverage" ./configure;
else
CFLAGS="-DPJ_SELFTEST --coverage" LDFLAGS="-lgcov" ./configure;
fi
- make -j3
- make check
- ./src/proj -VC
# install & run the working GIGS test
# create locations that pyproj understands
- python3 --version
- ln -s src include
- ln -s src/.libs lib
- mkdir share
- ln -s nad share/proj
- pwd
# install pyproj
- PROJ_DIR=`pwd` pip3 install -v --user pyproj
- cd test/gigs
# run test_json.py
- PROJ_LIB=../../nad python3 test_json.py --test conversion 5101.1-jhs.json 5101.4-jhs-etmerc.json 5105.2.json 5106.json 5108.json 5110.json 5111.1.json
- PROJ_LIB=../../nad python3 test_json.py 5101.2-jhs.json 5101.3-jhs.json 5102.1.json 5103.1.json 5103.2.json 5103.3.json 5107.json 5109.json 5112.json 5113.json 5201.json 5208.json
- cd ../..
- mv src/.libs/*.gc* src
script:
- echo "done"
after_success:
# coveralls falsely reports .c-files in the build directories as having 100% coverage so we exclude them
- coveralls --extension .c --exclude build_autoconf --exclude build_cmake
- echo "$TRAVIS_SECURE_ENV_VARS"
- sh -c "./travis/build_docs.sh"
- sh -c 'if test "$TRAVIS_SECURE_ENV_VARS" = "true" -a "$TRAVIS_BRANCH" = "master"; then echo "publish website"; ./travis/add_deploy_key.sh; ./travis/deploy_website.sh $TRAVIS_BUILD_DIR/docs/build /tmp; fi'
notifications:
#email:
# recipients:
# - gdal-commits@lists.osgeo.org
irc:
channels:
- "irc.freenode.org#gdal"
use_notice: true