Reputation: 2694
I am getting a error: no include path in which to search for stdint.h
error message when building a docker image from alpine:edge, that leads to other errors like unknown type name 'uint32_t'
and failure when compiling a program.
As far as I understand, stdint.h
is part of the C++ standard library and should be present, unless there is something broken within alpine:edge
, which I don't think will be the case.
My docker image is the following:
FROM alpine:edge
RUN apk update && apk add \
git \
make \
gcc \
python3 \
ldc \
&& git clone --recursive https://github.com/lomereiter/sambamba.git \
&& cd sambamba \
&& make \
&& mv sambamba /usr/local/bin/ \
&& cd ../.. \
&& rm -r sambamba
WORKDIR /wd
ENTRYPOINT ["/usr/local/bin/sambamba"]
Note that the image alpine:edge
is necessary, because the ldc
package is only available on it. How to fix this? Why isn't stdint.h
found?
Upvotes: 3
Views: 2493
Reputation: 30815
To successfully compile Sambamba, you need some additional packages:
Overall, this modified Dockerfile should do the trick:
FROM alpine:edge
RUN apk update && apk add \
git \
make \
gcc \
g++ \
zlib \
zlib-dev \
python3 \
ldc \
&& git clone --recursive https://github.com/lomereiter/sambamba.git \
&& cd sambamba \
&& make \
&& mv sambamba /usr/local/bin/ \
&& cd ../.. \
&& rm -r sambamba
WORKDIR /wd
ENTRYPOINT ["/usr/local/bin/sambamba"]
Upvotes: 4