Commit 272f5214 authored by Ghislain MARY's avatar Ghislain MARY

Include flexisip dependencies in docker images.

parent 38fdd8d2
BASE_NAME=gitlab.linphone.org:4567/bc/public/linphone-sdk
centos7:
docker build -f bc-dev-centos7 -t $(BASE_NAME)/bc-dev-centos:7 --rm .
debian8:
docker build -f bc-dev-debian8 -t $(BASE_NAME)/bc-dev-debian:8 --rm .
debian9:
docker build -f bc-dev-debian9 -t $(BASE_NAME)/bc-dev-debian:9 --rm .
.PHONY: centos7 debian8 debian9
......@@ -12,20 +12,16 @@ RUN yum install -y epel-release && \
yum clean all
# Install development tools
RUN yum install -y ccache clang cmake doxygen gcc-c++ gdb gettext-devel git graphviz libtool make nasm ninja-build patch pystache python-six python2-pip rpm-build yasm && \
curl -o cmake.tar.gz https://cmake.org/files/v3.2/cmake-3.2.3.tar.gz && \
tar xvzf cmake.tar.gz && rm cmake.tar.gz && cd cmake-3.2.3 && cmake . && make -j5 install && cd .. && rm -rf cmake-3.2.3 && \
yum erase -y cmake && \
RUN yum install -y at bison ccache clang cmake3 doxygen gcc-c++ gdb gettext-devel git graphviz libtool make nasm ninja-build patch pystache python-six python2-pip redhat-lsb-core rpm-build yasm && \
yum clean all && \
pip install sphinx javasphinx sphinx_csharp
# Install jenkins dependencies
#RUN yum install -y java-1.8.0-openjdk openssh-server && \
# yum clean all && \
# mkdir -p /var/run/sshd
# Install linphone dependencies development packages
RUN yum install -y alsa-lib-devel ffmpeg-devel glew-devel gsm-devel libbsd-devel libsrtp-devel libv4l-devel libvpx-devel libXv-devel libxml2-devel mbedtls-devel mesa-libEGL-devel openssl-devel opus-devel pulseaudio-libs-devel speex-devel sqlite-devel xerces-c-devel && \
pip install sphinx javasphinx sphinx_csharp && \
ln -s /usr/bin/ccmake3 /usr/bin/ccmake && \
ln -s /usr/bin/cmake3 /usr/bin/cmake && \
ln -s /usr/bin/cpack3 /usr/bin/cpack && \
ln -s /usr/bin/ctest3 /usr/bin/ctest
# Install linphone & flexisp dependencies development packages
RUN yum install -y alsa-lib-devel ffmpeg-devel glew-devel gsm-devel jansson-devel libbsd-devel libsrtp-devel libv4l-devel libvpx-devel libXv-devel libxml2-devel mariadb-devel mbedtls-devel mesa-libEGL-devel net-snmp-devel openssl-devel opus-devel postgresql-devel protobuf-devel pulseaudio-libs-devel speex-devel sqlite-devel xerces-c-devel xsd && \
yum clean all
# Install linphone runtime dependencies
......@@ -41,13 +37,6 @@ RUN useradd -ms /bin/bash bc && \
echo 'bc:cotcot' | chpasswd && \
echo 'bc ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
#EXPOSE 22
EXPOSE 5060/udp
EXPOSE 5060/tcp
EXPOSE 5061
#CMD ["/usr/sbin/sshd", "-D"]
USER bc
WORKDIR /home/bc
ENV PS1='\[\e[34m\]\u@bc-dev-centos7>\[\e[0m\] '
......
......@@ -12,22 +12,16 @@ RUN apt-get update && \
# Install development tools
RUN apt-get update && \
apt-get install -y autoconf ccache clang cmake doxygen g++ gdb git graphviz intltool libtool make nasm ninja-build patch python-lxml python-pip python-pystache python-six yasm && \
apt-get install -y alien at autoconf bison ccache clang cmake doxygen elfutils g++ gdb git graphviz intltool libtool lsb-release make nasm ninja-build patch python-lxml python-pip python-pystache python-six yasm && \
curl -o cmake.tar.gz https://cmake.org/files/v3.2/cmake-3.2.3.tar.gz && \
tar xvzf cmake.tar.gz && rm cmake.tar.gz && cd cmake-3.2.3 && cmake . && make -j5 install && cd .. && rm -rf cmake-3.2.3 && \
apt-get purge -y cmake && \
apt-get clean && \
pip install sphinx javasphinx sphinx_csharp
# Install jenkins dependencies
#RUN apt-get update && \
# apt-get install -y default-jre-headless openssh-server && \
# apt-get clean && \
# mkdir -p /var/run/sshd
# Install linphone dependencies development packages
# Install linphone & flexisip dependencies development packages
RUN apt-get update && \
apt-get install -y libasound2-dev libavcodec-dev libavutil-dev libbsd-dev libegl1-mesa-dev libglew-dev libgsm1-dev libopus-dev libpolarssl-dev libpulse-dev libspeex-dev libspeexdsp-dev libsqlite3-dev libsrtp0-dev libssl-dev libswscale-dev libv4l-dev libvpx-dev libxerces-c-dev libxml2-dev libxv-dev && \
apt-get install -y libasound2-dev libavcodec-dev libavutil-dev libbsd-dev libegl1-mesa-dev libglew-dev libgsm1-dev libjansson-dev libmysqlclient-dev libopus-dev libpolarssl-dev libpq-dev libprotobuf-dev libpulse-dev libsnmp-dev libspeex-dev libspeexdsp-dev libsqlite3-dev libsrtp0-dev libssl-dev libswscale-dev libv4l-dev libvpx-dev libxerces-c-dev libxml2-dev libxv-dev protobuf-compiler xsdcxx && \
apt-get clean
# Configure user bc
......@@ -35,13 +29,8 @@ RUN useradd -ms /bin/bash bc && \
echo 'bc:cotcot' | chpasswd && \
echo 'bc ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
#EXPOSE 22
EXPOSE 5060/udp
EXPOSE 5060/tcp
EXPOSE 5061
#CMD ["/usr/sbin/sshd", "-D"]
USER bc
WORKDIR /home/bc
COPY --chown=bc rpmmacros /home/bc/.rpmmacros
CMD bash
......@@ -12,19 +12,13 @@ RUN apt-get update && \
# Install development tools
RUN apt-get update && \
apt-get install -y autoconf ccache clang cmake doxygen g++ gdb git graphviz intltool libtool make nasm ninja-build patch python-pip python-pystache python-six yasm && \
apt-get install -y alien at autoconf bison ccache clang cmake doxygen elfutils g++ gdb git graphviz intltool libtool lsb-release make nasm ninja-build patch python-pip python-pystache python-six yasm && \
apt-get clean && \
pip install sphinx javasphinx sphinx_csharp
# Install jenkins dependencies
#RUN apt-get update && \
# apt-get install -y default-jre-headless openssh-server && \
# apt-get clean && \
# mkdir -p /var/run/sshd
# Install linphone dependencies development packages
# Install linphone & flexisip dependencies development packages
RUN apt-get update && \
apt-get install -y libasound2-dev libavcodec-dev libavutil-dev libbsd-dev libegl1-mesa-dev libglew-dev libgsm1-dev libmbedtls-dev libopus-dev libpulse-dev libspeex-dev libspeexdsp-dev libsqlite3-dev libsrtp2-dev libssl-dev libswscale-dev libturbojpeg0-dev libv4l-dev libvpx-dev libxerces-c-dev libxml2-dev libxv-dev && \
apt-get install -y libasound2-dev libavcodec-dev libavutil-dev libbsd-dev libegl1-mesa-dev libglew-dev libgsm1-dev libjansson-dev libmariadb-dev-compat libmbedtls-dev libopus-dev libpq-dev libprotobuf-dev libpulse-dev libsnmp-dev libspeex-dev libspeexdsp-dev libsqlite3-dev libsrtp2-dev libssl-dev libswscale-dev libturbojpeg0-dev libv4l-dev libvpx-dev libxerces-c-dev libxml2-dev libxv-dev protobuf-compiler xsdcxx && \
apt-get clean
# Install qt5
......@@ -43,13 +37,8 @@ RUN useradd -ms /bin/bash bc && \
ENV Qt5_DIR=/opt/Qt/5.11.0/gcc_64/lib/cmake
ENV PATH=$PATH:/opt/Qt/5.11.0/gcc_64/bin
#EXPOSE 22
EXPOSE 5060/udp
EXPOSE 5060/tcp
EXPOSE 5061
#CMD ["/usr/sbin/sshd", "-D"]
USER bc
WORKDIR /home/bc
COPY --chown=bc rpmmacros /home/bc/.rpmmacros
CMD bash
#
# Macros for cmake
#
%_cmake_lib_suffix64 -DLIB_SUFFIX=64
%_cmake_skip_rpath -DCMAKE_SKIP_RPATH:BOOL=ON
%_cmake_version 3.2.3
%__cmake cmake
# - Set default compile flags
# - CMAKE_*_FLAGS_RELEASE are added *after* the *FLAGS environment variables
# and default to -O3 -DNDEBUG. Strip the -O3 so we can override with *FLAGS
# - Turn on verbose makefiles so we can see and verify compile flags
# - Set default install prefixes and library install directories
# - Turn on shared libraries by default
%cmake \
CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; \
CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; \
FFLAGS="${FFLAGS:-%optflags%{?_fmoddir: -I%_fmoddir}}" ; export FFLAGS ; \
FCFLAGS="${FCFLAGS:-%optflags%{?_fmoddir: -I%_fmoddir}}" ; export FCFLAGS ; \
%{?__global_ldflags:LDFLAGS="${LDFLAGS:-%__global_ldflags}" ; export LDFLAGS ;} \
%__cmake \\\
-DCMAKE_C_FLAGS_RELEASE:STRING="-DNDEBUG" \\\
-DCMAKE_CXX_FLAGS_RELEASE:STRING="-DNDEBUG" \\\
-DCMAKE_Fortran_FLAGS_RELEASE:STRING="-DNDEBUG" \\\
-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \\\
-DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \\\
-DINCLUDE_INSTALL_DIR:PATH=%{_includedir} \\\
-DLIB_INSTALL_DIR:PATH=%{_libdir} \\\
-DSYSCONF_INSTALL_DIR:PATH=%{_sysconfdir} \\\
-DSHARE_INSTALL_PREFIX:PATH=%{_datadir} \\\
%if "%{?_lib}" == "lib64" \
%{?_cmake_lib_suffix64} \\\
%endif \
-DBUILD_SHARED_LIBS:BOOL=ON
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment