Skip to content

Commit 664381f

Browse files
authored
Merge pull request #9 from PDAL/gh-actions
Github Action
2 parents ab02488 + b4a5248 commit 664381f

File tree

2 files changed

+68
-18
lines changed

2 files changed

+68
-18
lines changed

.github/workflows/build.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: Build
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- '*'
7+
push:
8+
branches:
9+
- '*'
10+
release:
11+
types:
12+
- published
13+
jobs:
14+
docker:
15+
name: Docker
16+
17+
runs-on: ubuntu-latest
18+
strategy:
19+
fail-fast: true
20+
timeout-minutes: 240
21+
22+
steps:
23+
- uses: actions/checkout@v2
24+
- name: Build and push Docker images
25+
uses: docker/build-push-action@v1
26+
with:
27+
username: ${{ secrets.DOCKER_USERNAME }}
28+
password: ${{ secrets.DOCKER_PASSWORD }}
29+
repository: pdal/lambda
30+
tag_with_ref: true
31+
tag_with_sha: true
32+
push: ${{ startsWith(github.ref, 'refs/tags/') }}
33+
34+
# if: ${{ startsWith(github.ref, 'refs/tags/') }}
35+
36+
37+
layer:
38+
name: Layer
39+
needs: [docker]
40+
container: pdal/lambda
41+
42+
runs-on: ubuntu-latest
43+
strategy:
44+
fail-fast: true
45+
timeout-minutes: 60
46+
47+
steps:
48+
- uses: actions/checkout@v2
49+
- name: Package
50+
shell: bash -l {0}
51+
run: |
52+
/package-pdal.sh

Dockerfile

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
11
FROM lambci/lambda:build-python3.7 as builder
22

33
ARG http_proxy
4-
ARG CURL_VERSION=7.70.0
5-
ARG GDAL_VERSION=3.1.0
4+
ARG CURL_VERSION=7.70.1
5+
ARG GDAL_VERSION=3.1.2
66
ARG GEOS_VERSION=3.8.1
7-
ARG PROJ_VERSION=7.0.1
7+
ARG PROJ_VERSION=7.1.0
88
ARG LASZIP_VERSION=3.4.3
99
ARG GEOTIFF_VERSION=1.6.0
1010
ARG PDAL_VERSION=2.1.0
1111
ARG ENTWINE_VERSION=2.1.0
1212
ARG DESTDIR="/build"
1313
ARG PREFIX="/usr"
1414
ARG PARALLEL=8
15-
ARG CMAKE_VERSION=3.17.2
15+
ARG CMAKE_VERSION=3.18.1
16+
1617

1718

1819
RUN \
@@ -43,12 +44,9 @@ RUN gcc --version
4344

4445

4546
RUN \
46-
wget https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}.tar.gz \
47-
&& tar -zxvf cmake-${CMAKE_VERSION}.tar.gz \
48-
&& cd cmake-${CMAKE_VERSION} \
49-
&& ./bootstrap --parallel=${PARALLEL} --prefix=/usr \
50-
&& make -j ${PARALLEL} \
51-
&& make install DESTDIR=/ \
47+
wget https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-Linux-x86_64.sh \
48+
&& chmod +x cmake-${CMAKE_VERSION}-Linux-x86_64.sh \
49+
&& ./cmake-${CMAKE_VERSION}-Linux-x86_64.sh --skip-license --prefix=/usr \
5250
&& cd /var/task \
5351
&& rm -rf cmake*
5452

@@ -139,6 +137,7 @@ RUN git clone --branch release/ https://github.com/OSGeo/gdal.git --branch v${GD
139137
--mandir=/usr/share/man \
140138
--includedir=/usr/include/gdal \
141139
--with-threads \
140+
--without-libtool \
142141
--with-grass=no \
143142
--with-hide-internal-symbols=yes \
144143
--with-rename-internal-libtiff-symbols=yes \
@@ -177,8 +176,6 @@ RUN \
177176
ADD https://api.github.com/repos/PDAL/PDAL/commits?sha=${PDAL_VERSION} \
178177
/tmp/bust-cache
179178

180-
ENV \
181-
PACKAGE_PREFIX=${DESTDIR}/python
182179

183180
RUN \
184181
git clone https://github.com/PDAL/PDAL.git --branch ${PDAL_VERSION} \
@@ -188,8 +185,8 @@ RUN \
188185
&& cd _build \
189186
&& cmake .. \
190187
-G "Unix Makefiles" \
191-
-DCMAKE_BUILD_TYPE=Release \
192-
-DCMAKE_CXX_FLAGS="-std=c++11" \
188+
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
189+
-DCMAKE_CXX_FLAGS="-std=c++11 -pg" \
193190
-DCMAKE_MAKE_PROGRAM=make \
194191
-DBUILD_PLUGIN_I3S=ON \
195192
-DBUILD_PLUGIN_E57=ON \
@@ -210,10 +207,11 @@ RUN \
210207
#RUN \
211208
# git clone https://github.com/PDAL/python.git pdal-python \
212209
# && cd pdal-python \
213-
# && pip install numpy Cython packaging \
214-
# && ls /usr/bin/pd* \
215-
# && PDAL_CONFIG=/usr/bin/pdal-config pip install . --no-binary numpy -t $PACKAGE_PREFIX \
216-
# && ls $PACKAGE_PREFIX
210+
# && python -m pip install --upgrade pip \
211+
# && pip install numpy scikit-build packaging ninja cmake cython \
212+
# && bash -c 'python setup.py build' \
213+
# && bash -c 'python setup.py bdist_wheel' \
214+
# && ls dist
217215

218216
RUN \
219217
git clone https://github.com/connormanning/entwine.git --branch ${ENTWINE_VERSION} \

0 commit comments

Comments
 (0)