Comments (4)
I'm having the same error. I read that it could be something to do with c++17, as I can see in the build commands, the flag -std=c++14
is passed to the C compiler. I think changing to c++17 might fix this?
My Dockerfile is this:
FROM debian
RUN apt-get update
RUN apt-get install -y \
ca-certificates \
gnupg \
lsb-release \
curl \
git \
curl \
libcurl4 \
libcurl4-gnutls-dev \
patch \
clang \
make \
zlib1g \
zlib1g-dev \
libffi-dev \
openssl \
bzip2 \
readline-common \
libreadline8 \
sqlite3 \
libsqlite3-dev \
bash \
libicu-dev \
libfreetype-dev \
libharfbuzz-dev \
postgresql-15 \
postgresql-server-dev-15 \
postgresql-client-15 \
libpq5 \
libpq-dev \
cmake \
make \
libtiff-dev \
libcli11-dev \
libexpat1-dev \
npm \
python3-dev \
ruby
ENV CC clang
ENV CXX clang++
# Boost
RUN curl -L https://github.com/boostorg/boost/releases/download/boost-1.84.0/boost-1.84.0.tar.xz -o boost.tar.xz
RUN tar -xvf boost.tar.xz
RUN cd boost-1.84.0 && ./bootstrap.sh --prefix=/usr --with-python=python3 --with-toolset=clang
RUN cd boost-1.84.0 && ./b2 install -j$(nproc) threading=multi link=shared toolset=clang
# Postgis
RUN curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | gpg --dearmor | tee /etc/apt/trusted.gpg.d/apt.postgresql.org.gpg >/dev/null
RUN sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
RUN echo "Package: *\nPin: release o=apt.postgresql.org\nPin-Priority: 500" >> /etc/apt/preferences.d/pgdg.pref
RUN apt-get update
RUN apt-get upgrade -y
RUN apt-get install -y postgresql-15-postgis-3
# Python
ENV PYENV_ROOT /root/.pyenv
ENV PATH $PYENV_ROOT/shims:$PYENV_ROOT/bin:$PATH
RUN curl curl https://pyenv.run | bash
RUN pyenv update
RUN pyenv install 3.10
RUN pyenv global 3.10
RUN pyenv rehash
RUN python --version
# Libproj
RUN curl -L https://download.osgeo.org/proj/proj-9.3.1.tar.gz -o proj.tar.gz
RUN tar -xvf proj.tar.gz
RUN cd proj-* && mkdir build && cd build && CC=clang CXX=clang++ cmake -DBUILD_TESTING=OFF .. && cmake --build . && cmake --build . --target install
# Mapnik
RUN git clone https://github.com/mapnik/mapnik.git
RUN cd mapnik && git submodule update --init
RUN cd mapnik && echo "PROJ_INCLUDES = '/usr/local/include:/usr/local/include/proj'" >> config.py && echo "PROJ_LIBS = '/usr/local/lib'" >> config.py && echo "PROJ='yes'" >> config.py
RUN cd mapnik && ruby -e "f = File.read('SConstruct'); i = f.index(\" if env['PROJ']:\"); es = \" else:\n env['SKIPPED_DEPS'].append('proj')\"; e = f.index(es); File.write('SConstruct', f[..i-1] + f[e+1+es.length..])"
RUN cd mapnik && ./configure -Q VERBOSE=1 CC=clang CXX=clang++ && make && make install
from mapnik.
adding CXX_STD=17 might resolve the issue.
from mapnik.
If you are going to use a clone of https://github.com/mapnik/mapnik.git, I might suggest using CMake
to build Mapnik
. As far as I understand, it will be the recommended method (and potentially the only supported one) to build the upcoming 4.x.x
releases.
from mapnik.
May I suggest updating the build instructions for modern systems. They are very out of date.
from mapnik.
Related Issues (20)
- Misoriented altitude labels on contour lines HOT 4
- make failed in ubuntu 23.04 (with quick and dirty fix) HOT 1
- compile fails under ubuntu noble if you include proj.h HOT 2
- mapnik On Window10
- Support percentage values with a fractional component HOT 1
- 4.0.0-rc1 pollutes /usr/include toplevel directory HOT 1
- Github actions - Linux and MacOS runners are faliing HOT 8
- Cannot read context in shapefile with mapnik HOT 5
- Text not rendered correctly in visual-tests HOT 4
- GCC 14 build errors HOT 4
- Proposal: new logging and formatting HOT 2
- Using of `simplify_prefilter` parameter in PostGis datasource HOT 3
- Windows build is broken on github HOT 3
- FR: allow loading of styles with missing layer data files HOT 1
- bad rendering of specific Arabic text HOT 2
- Fails to build with GCC 14 HOT 4
- The 4.0.1 release archive contains a lot of Apple specific noise HOT 5
- Brew not including mapnik-config in 4.0.0 install HOT 2
- make test: 5 SVG errors on 8/29/2024 version HOT 4
- Compilation without proj enabled fails HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mapnik.