Skip to content

Instantly share code, notes, and snippets.

@zhujunsan
Created April 9, 2021 06:37
Show Gist options
  • Save zhujunsan/9bd2f60c33306d158ff52fcbbb709dec to your computer and use it in GitHub Desktop.
Save zhujunsan/9bd2f60c33306d158ff52fcbbb709dec to your computer and use it in GitHub Desktop.
CuraEngine Dokcer build
FROM ubuntu:20.04
RUN export DEBIAN_FRONTEND=noninteractive && \
apt-get update && \
apt-get install -y \
build-essential \
cmake \
python3-dev \
python3-sip-dev \
protobuf-compiler \
libprotoc-dev \
libprotobuf-dev \
git-core && \
ln -fs /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \
dpkg-reconfigure --frontend noninteractive tzdata && \
# Installing libArcus
cd /root && \
git clone --depth=1 https://github.com/Ultimaker/libArcus.git && \
cd libArcus/ && \
mkdir build && cd build && \
cmake .. && \
make && \
make install && \
cd ../.. && \
rm -rf libArcus && \
# Installing Protobuf
## already installed by `protobuf-compiler`
# Installing CuraEngine
cd /root && \
git clone --depth=1 https://github.com/Ultimaker/CuraEngine.git && \
cd CuraEngine && \
mkdir build && cd build && \
cmake .. && \
make && \
make install && \
cd ../.. && \
rm -rf CuraEngine && \
# Clean up
apt-get remove -y --purge \
build-essential \
cmake \
python3-dev \
python3-sip-dev \
protobuf-compiler \
libprotoc-dev \
libprotobuf-dev && \
apt-get install libprotobuf17 libgomp1 && \
apt-get autoremove -y --purge && \
echo "OK!"
VOLUME ["/root"]
WORKDIR /root
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment