Commit d4bf38fc authored by jehan's avatar jehan

add docker file to build rpm for centos7

parent a609be6b
[Belledonne]
name=Belledonne
baseurl=https://linphone.org/snapshots/centos7
enabled=1
gpgcheck=0
FROM centos
MAINTAINER Jehan Monnier <jehan.monnier@linphone.org>
# Prepare dependencies
COPY Belledonne.repo /etc/yum.repos.d/Belledonne.repo
RUN yum -y install epel-release gdb
RUN yum update -y
RUN yum -y install git gcc gcc-c++ make cmake3 mbedtls-devel rpm-build soci-devel soci-sqlite3-devel
RUN mkdir -p /etc/opt/belledonne-communications/lime
RUN git clone https://gitlab.linphone.org/BC/public/external/decaf.git -b bc --depth 1
RUN cd decaf && mkdir WORK && cd WORK && cmake3 ../ -DENABLE_STATIC=yes -DCMAKE_POSITION_INDEPENDENT_CODE=yes -DENABLE_SHARED=no -DCMAKE_PREFIX_PATH=/opt/belledonne-communications/lime \
-DCMAKE_INSTALL_PREFIX=/opt/belledonne-communications/lime && make install
RUN git clone https://gitlab.linphone.org/BC/public/bctoolbox.git --depth 1
RUN cd bctoolbox && mkdir WORK && cd WORK && cmake3 ../ -DENABLE_DECAF=yes -DENABLE_TESTS_COMPONENT=no -DENABLE_TESTS=no -DCPACK_GENERATOR="RPM" -DCMAKE_PREFIX_PATH=/opt/belledonne-communications/lime \
-DCMAKE_INSTALL_PREFIX=/opt/belledonne-communications/lime && make package && rpm -Uhv *.rpm --replacefiles --replacepkgs
RUN git clone https://gitlab+deploy-token-2:MFL_8xCj7i7FBjQidymD@gitlab.linphone.org/BC/private/lime.git --depth 1
RUN cd lime && mkdir WORK && cd WORK && cmake3 ../ -DBC_PACKAGE_NAME_PREFIX=bc -DCPACK_PACKAGE_NAME=bc-lime -DENABLE_UNIT_TESTS=no -DCMAKE_PREFIX_PATH=/opt/belledonne-communications/lime \
-DCMAKE_INSTALL_PREFIX=/opt/belledonne-communications/lime && make package_source && rpmbuild -ta *.tar.gz && rpm -Uhv *.rpm --replacefiles --replacepkgs
#cleanup
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