Skip to content

Commit b696c7a

Browse files
committed
update for GDAL 3 / PPROJ 6
1 parent a3e7594 commit b696c7a

File tree

4 files changed

+34
-14
lines changed

4 files changed

+34
-14
lines changed

Dockerfile

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
FROM lambci/lambda:build-python3.6 as builder
1+
FROM lambci/lambda:build-python3.7 as builder
22

33
ARG http_proxy
44
ARG CURL_VERSION=7.63.0
5-
ARG GDAL_VERSION=2.4.0
6-
ARG GEOS_VERSION=3.7.1
7-
ARG PROJ_VERSION=5.1.0
8-
ARG LASZIP_VERSION=3.2.9
9-
ARG GEOTIFF_VERSION=1.4.3
10-
ARG PDAL_VERSION=1.8.0
5+
ARG GDAL_VERSION=3.0.0
6+
ARG GEOS_VERSION=3.7.2
7+
ARG PROJ_VERSION=6.0.0
8+
ARG LASZIP_VERSION=3.4.1
9+
ARG GEOTIFF_VERSION=1.5.1
10+
ARG PDAL_VERSION=1.9.1
1111
ARG DESTDIR="/build"
1212
ARG PREFIX="/usr"
1313

@@ -17,13 +17,30 @@ RUN \
1717
yum install -y \
1818
automake16 \
1919
libpng-devel \
20-
nasm wget tar gcc zlib-devel gcc-c++ curl-devel zip libjpeg-devel rsync git ssh bzip2 automake \
20+
nasm wget tar zlib-devel curl-devel zip libjpeg-devel rsync git ssh bzip2 automake \
2121
glib2-devel libtiff-devel pkg-config libcurl-devel; # required for pkg-config
2222

23+
24+
25+
RUN \
26+
yum install -y iso-codes && \
27+
curl -O http://vault.centos.org/6.5/SCL/x86_64/scl-utils/scl-utils-20120927-11.el6.centos.alt.x86_64.rpm && \
28+
curl -O http://vault.centos.org/6.5/SCL/x86_64/scl-utils/scl-utils-build-20120927-11.el6.centos.alt.x86_64.rpm && \
29+
curl -O http://mirror.centos.org/centos/6/extras/x86_64/Packages/centos-release-scl-rh-2-3.el6.centos.noarch.rpm && \
30+
curl -O http://mirror.centos.org/centos/6/extras/x86_64/Packages/centos-release-scl-7-3.el6.centos.noarch.rpm && \
31+
rpm -Uvh *.rpm && \
32+
rm *.rpm && \
33+
yum install -y devtoolset-7-gcc-c++ devtoolset-7-make devtoolset-7-build ;
34+
35+
SHELL [ "/usr/bin/scl", "enable", "devtoolset-7"]
36+
37+
RUN gcc --version
38+
39+
2340
RUN \
24-
wget https://github.com/Kitware/CMake/releases/download/v3.13.2/cmake-3.13.2.tar.gz; \
25-
tar -zxvf cmake-3.13.2.tar.gz; \
26-
cd cmake-3.13.2; \
41+
wget https://github.com/Kitware/CMake/releases/download/v3.14.3/cmake-3.14.3.tar.gz; \
42+
tar -zxvf cmake-3.14.3.tar.gz; \
43+
cd cmake-3.14.3; \
2744
./bootstrap --prefix=/usr ;\
2845
make ;\
2946
make install DESTDIR=/
@@ -60,7 +77,7 @@ RUN \
6077
rm -rf proj-$PROJ_VERSION proj-$PROJ_VERSION.tar.gz
6178

6279
RUN \
63-
wget https://download.osgeo.org/geotiff/libgeotiff/libgeotiff-$GEOTIFF_VERSION.tar.gz; \
80+
wget https://github.com/OSGeo/libgeotiff/releases/download/$GEOTIFF_VERSION/libgeotiff-$GEOTIFF_VERSION.tar.gz; \
6481
tar -xzvf libgeotiff-$GEOTIFF_VERSION.tar.gz; \
6582
cd libgeotiff-$GEOTIFF_VERSION; \
6683
./configure \

build.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
CONTAINER="pdal-lambda"
44
docker build -t $CONTAINER -f Dockerfile .
55
rm -rf lambda
6+
rm lambda-deploy.zip
67
mkdir -p lambda
78

89
docker run -v `pwd`:/output $CONTAINER /package-pdal.sh

create-lambda-layer.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
LAYERNAME="pdal"
33
LAYER=$(aws lambda publish-layer-version \
44
--layer-name $LAYERNAME \
5-
--description "PDAL 1.8.0 softare" \
5+
--description "PDAL 1.9.1 softare" \
66
--zip-file fileb://./lambda-deploy.zip \
77
--compatible-runtimes "provided" \
88
--license-info BSD \

package-pdal.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,16 @@ cp /usr/lib64/libtiff.so.5.2.0 $DEPLOY_DIR/lib/
1414
cp /usr/lib64/libpng.so.3.49.0 $DEPLOY_DIR/lib/
1515
cp /usr/lib64/libsqlite3.so.0.8.6 $DEPLOY_DIR/lib/
1616
rm -rf $DEPLOY_DIR/lib/*.a
17+
rm -rf $DEPLOY_DIR/bin/projinfo
18+
rm -rf $DEPLOY_DIR/bin/gie
1719
rm -rf $DEPLOY_DIR/lib/libpdal_plugin*
1820
rm -rf $DEPLOY_DIR/lib/python3.6
1921

2022
rsync -ax /build/usr/share/gdal $DEPLOY_DIR/share/
2123
rsync -ax /build/usr/share/proj $DEPLOY_DIR/share/
2224

2325
cd $DEPLOY_DIR
24-
zip --symlinks -ruq ../$PACKAGE_NAME ./
26+
zip --symlinks -9 -ruq ../$PACKAGE_NAME ./
2527
rm -rf $DEPLOY_DIR
2628

2729

0 commit comments

Comments
 (0)