Skip to content
Permalink
Browse files
Travis / Vagrant: use PROJ 6.1.1 for PROJ.4 API testing as well
  • Loading branch information
rouault committed Oct 1, 2019
1 parent f595e91 commit 84bc541670864c1f2bea657ecdcb881dc0ff5b45
Show file tree
Hide file tree
Showing 41 changed files with 321 additions and 308 deletions.
@@ -4,27 +4,36 @@ set -eu
if [ "$BUILD_NAME" = "PHP_7.2_WITH_ASAN" ]; then
export CC="ccache clang"
export CXX="ccache clang++"
else
export CC="ccache gcc"
export CXX="ccache g++"
fi

curl http://download.osgeo.org/proj/proj-6.1.1.tar.gz > proj-6.1.1.tar.gz
tar xzf proj-6.1.1.tar.gz
mv proj-6.1.1 proj
(cd proj/data && curl http://download.osgeo.org/proj/proj-datumgrid-1.8.tar.gz > proj-datumgrid-1.8.tar.gz && tar xvzf proj-datumgrid-1.8.tar.gz)
(cd proj; CFLAGS='-O2 -DPROJ_RENAME_SYMBOLS' CXXFLAGS='-O2 -DPROJ_RENAME_SYMBOLS' ./configure --disable-static --prefix=/usr/local && CCACHE_CPP2=yes make -j2 && sudo make -j3 install)
sudo rm -f /usr/include/proj_api.h

if [ "$BUILD_NAME" = "PHP_7.2_WITH_ASAN" ]; then
# Force use of PROJ 4 API
sudo rm /usr/local/include/proj.h
# -DNDEBUG to avoid issues with cairo cleanup
make cmakebuild MFLAGS="-j2" CMAKE_C_FLAGS="-g -fsanitize=address -DNDEBUG" CMAKE_CXX_FLAGS="-g -fsanitize=address -DNDEBUG" EXTRA_CMAKEFLAGS="-DCMAKE_BUILD_TYPE=None -DCMAKE_EXE_LINKER_FLAGS=-fsanitize=address"
make cmakebuild MFLAGS="-j2" CMAKE_C_FLAGS="-g -fsanitize=address -DNDEBUG -DPROJ_RENAME_SYMBOLS -DACCEPT_USE_OF_DEPRECATED_PROJ_API_H" CMAKE_CXX_FLAGS="-g -fsanitize=address -DNDEBUG -DPROJ_RENAME_SYMBOLS -DACCEPT_USE_OF_DEPRECATED_PROJ_API_H" EXTRA_CMAKEFLAGS="-DCMAKE_BUILD_TYPE=None -DCMAKE_EXE_LINKER_FLAGS=-fsanitize=address -DPROJ_INCLUDE_DIR=/usr/local/include -DPROJ_LIBRARY=/usr/local/lib/libproj.so.15"
export AUTOTEST_OPTS="-q -strict -run_under_asan"
# Only run tests that only involve mapserv/shp2img binaries. mspython, etc would require LD_PREOLOAD'ing the asan shared object
make -j4 asan_compatible_tests
elif [ "$BUILD_NAME" = "PHP_7.3_WITH_PROJ6" ]; then
curl http://download.osgeo.org/proj/proj-6.1.1.tar.gz > proj-6.1.1.tar.gz
tar xzf proj-6.1.1.tar.gz
mv proj-6.1.1 proj
(cd proj/data && curl http://download.osgeo.org/proj/proj-datumgrid-1.8.tar.gz > proj-datumgrid-1.8.tar.gz && tar xvzf proj-datumgrid-1.8.tar.gz)
(cd proj; CFLAGS='-O2 -DPROJ_RENAME_SYMBOLS' CXXFLAGS='-O2 -DPROJ_RENAME_SYMBOLS' ./configure --disable-static --prefix=/usr/local && CCACHE_CPP2=yes make -j2 && sudo make -j3 install)
# Avoid any use of PROJ 4 API
sudo rm -f /usr/include/proj_api.h
make cmakebuild MFLAGS="-j2" CMAKE_C_FLAGS="-O2 -DPROJ_RENAME_SYMBOLS" CMAKE_CXX_FLAGS="-O2 -DPROJ_RENAME_SYMBOLS" EXTRA_CMAKEFLAGS="-DPROJ_INCLUDE_DIR=/usr/local/include -DPROJ_LIBRARY=/usr/local/lib/libproj.so.15"
export LD_LIBRARY_PATH=/usr/local/lib
./build/mapserv
make mspython-wheel
make -j4 test
else
export CC="ccache gcc"
export CXX="ccache g++"
make cmakebuild MFLAGS="-j2"
# Force use of PROJ 4 API
sudo rm /usr/local/include/proj.h
make cmakebuild MFLAGS="-j2" CMAKE_C_FLAGS="-DPROJ_RENAME_SYMBOLS -DACCEPT_USE_OF_DEPRECATED_PROJ_API_H" CMAKE_CXX_FLAGS="-DPROJ_RENAME_SYMBOLS -DACCEPT_USE_OF_DEPRECATED_PROJ_API_H" EXTRA_CMAKEFLAGS="-DPROJ_INCLUDE_DIR=/usr/local/include -DPROJ_LIBRARY=/usr/local/lib/libproj.so.15"
make mspython-wheel
make -j4 test
fi
@@ -93,8 +93,8 @@ Content-Type: text/xml; charset=UTF-8
<metadataLink metadataType="TC211" xlink:type="simple" xlink:href="http://localhost/ows?request=GetMetadata&amp;layer=toronto"/> <name>toronto</name>
<label>Toronto</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-117.54590357301 44.665615181923</gml:pos>
<gml:pos>-117.38727661816 44.767083018813</gml:pos>
<gml:pos>-117.54590357301 44.665615181929</gml:pos>
<gml:pos>-117.38727661816 44.767083018819</gml:pos>
</lonLatEnvelope>
</CoverageOfferingBrief>
</ContentMetadata>
@@ -142,8 +142,8 @@ Content-Type: text/xml; charset=UTF-8
<ows:Title>Toronto</ows:Title>
<ows:Abstract>Toronto</ows:Abstract>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-117.54590357301 44.665615181923</ows:LowerCorner>
<ows:UpperCorner>-117.38727661816 44.767083018813</ows:UpperCorner>
<ows:LowerCorner>-117.54590357301 44.665615181929</ows:LowerCorner>
<ows:UpperCorner>-117.38727661816 44.767083018819</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedFormat>image/tiff</SupportedFormat>
@@ -79,8 +79,8 @@ Content-Type: text/xml; charset=UTF-8
<name>grey</name>
<label>Test label</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-121.48874388968 0</gml:pos>
<gml:pos>-121.48516027717 0.0027058261133485</gml:pos>
<gml:pos>-121.4887438893 0</gml:pos>
<gml:pos>-121.4851602768 0.0027058261133494</gml:pos>
</lonLatEnvelope>
<keywords>
<keyword>test</keyword>
@@ -14,8 +14,8 @@ Content-Type: text/xml; charset=UTF-8
<name>grey</name>
<label>Test label</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-121.48874388968 0</gml:pos>
<gml:pos>-121.48516027717 0.0027058261133485</gml:pos>
<gml:pos>-121.4887438893 0</gml:pos>
<gml:pos>-121.4851602768 0.0027058261133494</gml:pos>
</lonLatEnvelope>
<keywords>
<keyword>test</keyword>
@@ -24,8 +24,8 @@ Content-Type: text/xml; charset=UTF-8
<domainSet>
<spatialDomain>
<gml:Envelope srsName="EPSG:4326">
<gml:pos>-121.48874388968 0</gml:pos>
<gml:pos>-121.48516027717 0.0027058261133485</gml:pos>
<gml:pos>-121.4887438893 0</gml:pos>
<gml:pos>-121.4851602768 0.0027058261133494</gml:pos>
</gml:Envelope>
<gml:Envelope srsName="EPSG:32611">
<gml:pos>0 0</gml:pos>
@@ -147,8 +147,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.48874388968 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027717 0.0027058261133485</ows:UpperCorner>
<ows:LowerCorner>-121.4887438893 0</ows:LowerCorner>
<ows:UpperCorner>-121.4851602768 0.0027058261133494</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -145,8 +145,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.48874388968 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027717 0.0027058261133485</ows:UpperCorner>
<ows:LowerCorner>-121.4887438893 0</ows:LowerCorner>
<ows:UpperCorner>-121.4851602768 0.0027058261133494</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -105,8 +105,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -145,8 +145,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -145,8 +145,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -21,8 +21,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
<ows:UpperCorner>400 300</ows:UpperCorner>
</ows:BoundingBox>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<GridCRS>
<GridBaseCRS>urn:ogc:def:crs:EPSG::32611</GridBaseCRS>
@@ -145,8 +145,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.48874388968 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027717 0.0027058261133485</ows:UpperCorner>
<ows:LowerCorner>-121.4887438893 0</ows:LowerCorner>
<ows:UpperCorner>-121.4851602768 0.0027058261133494</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -105,8 +105,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -145,8 +145,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -145,8 +145,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
</ows:Keywords>
<ows:Metadata xlink:type="simple" xlink:href="http://www.gdal.org/metadata_test_link.html"/>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<SupportedCRS>urn:ogc:def:crs:EPSG::32611</SupportedCRS>
<SupportedCRS>urn:ogc:def:crs:EPSG::4326</SupportedCRS>
@@ -21,8 +21,8 @@ Acquisition: 1999-10-11 18:47</ows:Abstract>
<ows:UpperCorner>400 300</ows:UpperCorner>
</ows:BoundingBox>
<ows:WGS84BoundingBox dimensions="2">
<ows:LowerCorner>-121.488743889689 0</ows:LowerCorner>
<ows:UpperCorner>-121.485160277178 0.00270582611334856</ows:UpperCorner>
<ows:LowerCorner>-121.48874388937 0</ows:LowerCorner>
<ows:UpperCorner>-121.48516027686 0.00270582611334944</ows:UpperCorner>
</ows:WGS84BoundingBox>
<GridCRS>
<GridBaseCRS>urn:ogc:def:crs:EPSG::32611</GridBaseCRS>
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -91,8 +91,8 @@ Content-Type: text/xml; charset=UTF-8
<name>grey</name>
<label>Test label</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-121.48874388968 0</gml:pos>
<gml:pos>-121.48516027717 0.0027058261133485</gml:pos>
<gml:pos>-121.4887438893 0</gml:pos>
<gml:pos>-121.4851602768 0.0027058261133494</gml:pos>
</lonLatEnvelope>
<keywords>
<keyword>test</keyword>
@@ -89,8 +89,8 @@
<name>grey</name>
<label>Test label</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-121.48874388968 0</gml:pos>
<gml:pos>-121.48516027717 0.0027058261133485</gml:pos>
<gml:pos>-121.4887438893 0</gml:pos>
<gml:pos>-121.4851602768 0.0027058261133494</gml:pos>
</lonLatEnvelope>
<keywords>
<keyword>test</keyword>
@@ -89,8 +89,8 @@
<name>grey</name>
<label>Test label</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-121.488743889689 0</gml:pos>
<gml:pos>-121.485160277178 0.00270582611334856</gml:pos>
<gml:pos>-121.48874388937 0</gml:pos>
<gml:pos>-121.48516027686 0.00270582611334944</gml:pos>
</lonLatEnvelope>
<keywords>
<keyword>test</keyword>
@@ -12,8 +12,8 @@
<name>grey</name>
<label>Test label</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-121.488743889689 0</gml:pos>
<gml:pos>-121.485160277178 0.00270582611334856</gml:pos>
<gml:pos>-121.48874388937 0</gml:pos>
<gml:pos>-121.48516027686 0.00270582611334944</gml:pos>
</lonLatEnvelope>
<keywords>
<keyword>test</keyword>
@@ -22,8 +22,8 @@
<domainSet>
<spatialDomain>
<gml:Envelope srsName="EPSG:4326">
<gml:pos>-121.488743889689 0</gml:pos>
<gml:pos>-121.485160277178 0.00270582611334856</gml:pos>
<gml:pos>-121.48874388937 0</gml:pos>
<gml:pos>-121.48516027686 0.00270582611334944</gml:pos>
</gml:Envelope>
<gml:Envelope srsName="EPSG:32611">
<gml:pos>0 0</gml:pos>
@@ -13,14 +13,14 @@ Content-Type: text/xml; charset=UTF-8
<metadataLink metadataType="TC211" xlink:type="simple" xlink:href="http://localhost/path/to/?request=GetMetadata&amp;layer=grey_26711"/> <name>grey_26711</name>
<label>grey_26711</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-117.64116862079 33.848239887018</gml:pos>
<gml:pos>-117.5759124632 33.902673374966</gml:pos>
<gml:pos>-117.64116862079 33.848239887019</gml:pos>
<gml:pos>-117.5759124632 33.902673374967</gml:pos>
</lonLatEnvelope>
<domainSet>
<spatialDomain>
<gml:Envelope srsName="EPSG:4326">
<gml:pos>-117.64116862079 33.848239887018</gml:pos>
<gml:pos>-117.5759124632 33.902673374966</gml:pos>
<gml:pos>-117.64116862079 33.848239887019</gml:pos>
<gml:pos>-117.5759124632 33.902673374967</gml:pos>
</gml:Envelope>
<gml:Envelope srsName="EPSG:26711">
<gml:pos>440720 3745320</gml:pos>
@@ -65,8 +65,8 @@ Content-Type: text/xml; charset=UTF-8
<metadataLink metadataType="TC211" xlink:type="simple" xlink:href="http://localhost/path/to/?request=GetMetadata&amp;layer=grey_26711"/> <name>grey_26711</name>
<label>grey_26711</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-117.64116862079 33.848239887018</gml:pos>
<gml:pos>-117.5759124632 33.902673374966</gml:pos>
<gml:pos>-117.64116862079 33.848239887019</gml:pos>
<gml:pos>-117.5759124632 33.902673374967</gml:pos>
</lonLatEnvelope>
</CoverageOfferingBrief>
</ContentMetadata>
@@ -104,8 +104,8 @@
<name>toronto</name>
<label>Landsat 5 TM - Toronto</label>
<lonLatEnvelope srsName="urn:ogc:def:crs:OGC:1.3:CRS84">
<gml:pos>-81.545267534394 42.713551218108</gml:pos>
<gml:pos>-78.387425267181 44.767291525848</gml:pos>
<gml:pos>-81.545267534394 42.713551218133</gml:pos>
<gml:pos>-78.38742526718 44.767291525854</gml:pos>
</lonLatEnvelope>
<keywords>
<keyword>landsat</keyword>
Binary file not shown.

0 comments on commit 84bc541

Please sign in to comment.