Skip to content

Commit 6ad36f1

Browse files
author
Hank Brekke
committed
Split from Skyway git repo: broader OSMTools naming (from OSRM)
1 parent c17a034 commit 6ad36f1

File tree

8 files changed

+48
-18
lines changed

8 files changed

+48
-18
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.idea/

AmazonLinuxLibraries.dockerfile

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
FROM --platform=linux/amd64 amazonlinux:2023
22

3-
# todo- remove rapidjson
3+
ARG NODE_VERSION="22.15.0"
4+
ARG OSRM_VERSION="6.0.0"
5+
ARG TILEMAKER_VERSION="3.0.0"
6+
ARG MAPNIK_VERSION="4.1.3"
7+
48
RUN yum -y install libxml2-devel bzip2-devel boost-devel libzip-devel \
59
lua.x86_64 lua-devel.x86_64 luajit.x86_64 luajit-devel.x86_64 \
6-
expat expat-devel sqlite-devel rapidjson-devel libatomic \
7-
bzip2 diffutils binutils gcc14 gcc14-c++ cmake unzip wget tar xz gzip
10+
expat expat-devel sqlite-devel libatomic bzip2 diffutils binutils \
11+
gcc14 gcc14-c++ cmake unzip wget tar xz gzip
812

913
WORKDIR /home
1014

@@ -13,19 +17,19 @@ RUN tar -xf onetbb.tgz && \
1317
cp -a oneapi-tbb-2022.1.0/lib/intel64/gcc4.8/. /usr/local/lib/ && \
1418
cp -a oneapi-tbb-2022.1.0/include/. /usr/local/include/
1519

16-
RUN wget "https://nodejs.org/dist/v22.15.0/node-v22.15.0-linux-x64.tar.xz" -O node.tgz
20+
RUN wget "https://nodejs.org/dist/v${NODE_VERSION}/node-v${NODE_VERSION}-linux-x64.tar.xz" -O node.tgz
1721
RUN tar -xf node.tgz && \
18-
ls node-v22.15.0-linux-x64 && \
19-
cp -a node-v22.15.0-linux-x64/bin/. /usr/local/bin && \
20-
cp -a node-v22.15.0-linux-x64/include/. /usr/local/include && \
21-
cp -a node-v22.15.0-linux-x64/lib/. /usr/local/lib && \
22-
cp -a node-v22.15.0-linux-x64/share/. /usr/local/share && \
22+
ls node-v${NODE_VERSION}-linux-x64 && \
23+
cp -a node-v${NODE_VERSION}-linux-x64/bin/. /usr/local/bin && \
24+
cp -a node-v${NODE_VERSION}-linux-x64/include/. /usr/local/include && \
25+
cp -a node-v${NODE_VERSION}-linux-x64/lib/. /usr/local/lib && \
26+
cp -a node-v${NODE_VERSION}-linux-x64/share/. /usr/local/share && \
2327
export PATH="$PATH:/usr/local/bin" && \
2428
node -v
2529

26-
RUN wget "https://github.com/Project-OSRM/osrm-backend/archive/refs/tags/v6.0.0.tar.gz" -O osrm.tgz
30+
RUN wget "https://github.com/Project-OSRM/osrm-backend/archive/refs/tags/v${OSRM_VERSION}.tar.gz" -O osrm.tgz
2731
RUN tar -xf osrm.tgz && \
28-
cd osrm-backend-6.0.0 && \
32+
cd osrm-backend-${OSRM_VERSION} && \
2933
npm install --ignore-scripts && \
3034
sed -i -e 's/LUA_COMPAT_5_2/LUA_COMPAT_5_2 1/g' /usr/include/luaconf-x86_64.h && \
3135
sed -i '1s/^/#include <utility>\n/' /usr/include/boost/asio/awaitable.hpp && \
@@ -69,7 +73,7 @@ RUN tar -xf osmium.tgz && \
6973
cmake --build .
7074

7175
RUN wget "https://github.com/OSGeo/shapelib/releases/download/v1.6.1/shapelib-1.6.1.tar.gz" -O shapelib.tgz
72-
RUN wget "https://github.com/systemed/tilemaker/archive/refs/tags/v3.0.0.tar.gz" -O tilemaker.tgz
76+
RUN wget "https://github.com/systemed/tilemaker/archive/refs/tags/v${TILEMAKER_VERSION}.tar.gz" -O tilemaker.tgz
7377
RUN tar -xf shapelib.tgz && \
7478
cd shapelib-1.6.1 && \
7579
CXX=gcc14-g++ ./configure && \
@@ -84,13 +88,13 @@ RUN unzip rapidjson.zip && \
8488
cmake --build . && \
8589
cmake --install .
8690
RUN tar -xf tilemaker.tgz && \
87-
cd tilemaker-3.0.0 && \
91+
cd tilemaker-${TILEMAKER_VERSION} && \
8892
mkdir build && \
8993
cd build && \
9094
CXX=gcc14-g++ CC=gcc14-cc cmake .. && \
9195
cmake --build .
9296

93-
RUN cd osrm-backend-6.0.0 && \
97+
RUN cd osrm-backend-${OSRM_VERSION} && \
9498
mkdir -p /home/export/node_modules/@project-osrm/osrm/lib && \
9599
cp package.json /home/export/node_modules/@project-osrm/osrm/ && \
96100
cp package-lock.json /home/export/node_modules/@project-osrm/osrm/ && \
@@ -113,7 +117,7 @@ RUN cd osrm-backend-6.0.0 && \
113117
mkdir /home/export/bin && \
114118
cp build/src/osmium /home/export/bin/osmium && \
115119
cp /usr/lib64/libexpat.so.1 /home/export/lib/ && \
116-
cd ../tilemaker-3.0.0 && \
120+
cd ../tilemaker-${TILEMAKER_VERSION} && \
117121
cp /usr/local/lib/libshp.so.4 /home/export/lib/ && \
118122
cp /usr/lib64/libatomic.so.1 /home/export/lib/ && \
119123
cp build/tilemaker /home/export/bin/tilemaker && \

LICENSE.txt

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025 Hank Brekke-Peer
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

PoppinsFontPBF.zip

-301 KB
Binary file not shown.

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# aws-lambda-layer-osmtools
2+
3+
OpenStreetMap C++ tools available as an AWS Lambda Layer!
4+
5+
More details coming soon.

build-libraries.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#/usr/bin/env bash
22
set -e
33

4-
docker build -f ./AmazonLinuxLibraries.dockerfile -t skyway-amz-libraries:latest .
5-
docker run --rm --platform linux/amd64 -v .:/home/host skyway-amz-libraries:latest cp osrm-prebuilt-amazonlinux2023.zip host/
4+
docker build -f ./AmazonLinuxLibraries.dockerfile -t amz-built-osmtools:latest .
5+
docker run --rm --platform linux/amd64 -v .:/home/host amz-built-osmtools:latest cp aws-lambda-layer-osmtools.zip host/

demotiles

Lines changed: 0 additions & 1 deletion
This file was deleted.

osrm-prebuilt-amazonlinux2023.zip

-52 MB
Binary file not shown.

0 commit comments

Comments
 (0)