diff options
Diffstat (limited to 'Dockerfile_test')
-rw-r--r-- | Dockerfile_test | 32 |
1 files changed, 24 insertions, 8 deletions
diff --git a/Dockerfile_test b/Dockerfile_test index 8d4bec0..8b16ae2 100644 --- a/Dockerfile_test +++ b/Dockerfile_test @@ -1,8 +1,21 @@ -FROM debian:stretch +FROM ubuntu:14.04 MAINTAINER Oleg Morozenkov <a@reo7sp.ru> RUN apt-get -qq update && \ - apt-get -qq install -y g++ make binutils cmake libssl-dev libboost-system-dev libboost-test-dev libcurl4-openssl-dev + apt-get -qq install -y g++ make binutils cmake libssl-dev libcurl4-openssl-dev \ + wget build-essential python-dev autotools-dev libicu-dev libbz2-dev + +WORKDIR /usr/src/boost +RUN wget -q -O boost_1_59_0.tar.gz https://sourceforge.net/projects/boost/files/boost/1.59.0/boost_1_59_0.tar.gz/download && \ + tar xzf boost_1_59_0.tar.gz && \ + rm boost_1_59_0.tar.gz && \ + cd boost_1_59_0 && \ + ./bootstrap.sh --prefix=/usr/ --with-libraries=system,test && \ + ./b2 -j $(nproc) -d0 && \ + ./b2 install && \ + cd .. && \ + rm -r boost_1_59_0 + WORKDIR /usr/src/tgbot-cpp COPY include include @@ -11,31 +24,34 @@ COPY test test COPY CMakeLists.txt ./ RUN cmake -DENABLE_TESTS=ON . && \ - make -j4 && \ + make -j$(nproc) && \ make install + COPY samples samples WORKDIR /usr/src/tgbot-cpp/samples/echobot RUN rm -rf CMakeCache.txt CMakeFiles/ && \ - cmake . && make -j4 + cmake . && make -j$(nproc) WORKDIR /usr/src/tgbot-cpp/samples/echobot-curl-client RUN rm -rf CMakeCache.txt CMakeFiles/ && \ - cmake . && make -j4 + cmake . && make -j$(nproc) WORKDIR /usr/src/tgbot-cpp/samples/echobot-webhook-server RUN rm -rf CMakeCache.txt CMakeFiles/ && \ - cmake . && make -j4 + cmake . && make -j$(nproc) WORKDIR /usr/src/tgbot-cpp/samples/inline-keyboard RUN rm -rf CMakeCache.txt CMakeFiles/ && \ - cmake . && make -j4 + cmake . && make -j$(nproc) WORKDIR /usr/src/tgbot-cpp/samples/photo RUN rm -rf CMakeCache.txt CMakeFiles/ && \ - cmake . && make -j4 + cmake . && make -j$(nproc) + WORKDIR /usr/src/tgbot-cpp ENV CTEST_OUTPUT_ON_FAILURE=1 CMD make test + |