Revert "builders.d: remove veryclean safety echo"

This reverts commit 75bbf7d3c1.

Revert "builders.d: compile zrtp and polarssl using cmake too"

This reverts commit e4b9cfc1de.
This commit is contained in:
Gautier Pelloux-Prayer 2015-05-19 17:13:42 +02:00
parent 75bbf7d3c1
commit 115f998898
4 changed files with 74 additions and 109 deletions

View file

@ -21,7 +21,7 @@ if grep -q ' ' <<< $PWD; then
echo_err "Invalid location: your location should not contain spaces"
fi
for prog in autoconf automake pkg-config doxygen java nasm gettext wget yasm optipng cmake; do
for prog in autoconf automake pkg-config doxygen java nasm gettext wget yasm optipng; do
check_installed "$prog" "it"
done

View file

@ -1,51 +1,24 @@
############################################################################
# Copyright (C) 2014 Belledonne Communications,Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
cunit_dir?=cunit
SRC_CUNIT=$(BUILDER_SRC_DIR)/${cunit_dir}
BUILD_CUNIT=$(BUILDER_BUILD_DIR)/${cunit_dir}
cunit_project:=cunit
cunit_project_dir:=.
cunit_cmake_specific_options:=-DENABLE_STATIC=YES
${BUILD_CUNIT}/CMakeCache.txt:
mkdir -p ${BUILD_CUNIT} && \
cd ${BUILD_CUNIT} && \
cmake -DENABLE_STATIC=YES -DCMAKE_TOOLCHAIN_FILE=$(BUILDER_SRC_DIR)/build/toolchain.cmake \
-DIOS_ARCH=${ARCH} -DCMAKE_INSTALL_PREFIX=$(prefix) ${SRC_CUNIT}
cunit_src_dir=$(BUILDER_SRC_DIR)/${cunit_project_dir}/${cunit_project}
cunit_build_dir=$(BUILDER_BUILD_DIR)/${cunit_project_dir}/${cunit_project}
${cunit_build_dir}/Makefile:
rm -rf ${cunit_build_dir}/CMakeCache.txt ${cunit_build_dir}/CMakeFiles/ && \
mkdir -p ${cunit_build_dir} && \
cd ${cunit_build_dir} && \
cmake -DCMAKE_TOOLCHAIN_FILE=$(BUILDER_SRC_DIR)/build/toolchain.cmake -DIOS_ARCH=${ARCH} \
-DCMAKE_INSTALL_PREFIX=$(prefix) -DCMAKE_PREFIX_PATH=$(prefix) -DCMAKE_MODULE_PATH=$(prefix)/share/cmake/Modules/ \
${cunit_cmake_specific_options} ${cunit_src_dir}
build-${cunit_project}: ${cunit_build_dir}/Makefile
cd ${cunit_build_dir} && \
build-cunit: ${BUILD_CUNIT}/CMakeCache.txt
cd ${BUILD_CUNIT} && \
make && \
make install
clean-${cunit_project}:
cd $(cunit_build_dir) && \
clean-cunit:
cd $(BUILD_CUNIT)/$(cunit_dir) && \
make clean
veryclean-${cunit_project}:
if [ -d $(cunit_build_dir) ]; then grep -v $(prefix) $(cunit_build_dir)/install_manifest.txt | xargs rm; fi && \
rm -rf $(cunit_build_dir)
veryclean-cunit:
rm -rf $(BUILD_CUNIT)/$(cunit_dir)
clean-makefile-${cunit_project}: veryclean-${cunit_project}
clean-makefile-cunit: veryclean-cunit

View file

@ -1,51 +1,28 @@
############################################################################
# Copyright (C) 2014 Belledonne Communications,Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
polarssl_dir?=externals/polarssl
polarssl_project:=polarssl
polarssl_project_dir:=externals
polarssl_cmake_specific_options:=-DUSE_STATIC_POLARSSL_LIBRARY=YES -DENABLE_TESTING=OFF -DENABLE_PROGRAMS=OFF -DENABLE_APIDOC=OFF
SRC_DIR=$(BUILDER_SRC_DIR)
BUILD_DIR=$(BUILDER_BUILD_DIR)
polarssl_src_dir=$(BUILDER_SRC_DIR)/${polarssl_project_dir}/${polarssl_project}
polarssl_build_dir=$(BUILDER_BUILD_DIR)/${polarssl_project_dir}/${polarssl_project}
${polarssl_build_dir}/Makefile:
rm -rf ${polarssl_build_dir}/CMakeCache.txt ${polarssl_build_dir}/CMakeFiles/ && \
mkdir -p ${polarssl_build_dir} && \
cd ${polarssl_build_dir} && \
cmake -DCMAKE_TOOLCHAIN_FILE=$(BUILDER_SRC_DIR)/build/toolchain.cmake -DIOS_ARCH=${ARCH} \
-DCMAKE_INSTALL_PREFIX=$(prefix) -DCMAKE_PREFIX_PATH=$(prefix) -DCMAKE_MODULE_PATH=$(prefix)/share/cmake/Modules/ \
${polarssl_cmake_specific_options} ${polarssl_src_dir}
$(SRC_DIR)/$(polarssl_dir)/configure:
cd $(SRC_DIR)/$(polarssl_dir) && ./autogen.sh
build-${polarssl_project}: ${polarssl_build_dir}/Makefile
cd ${polarssl_build_dir} && \
make && \
make install
$(BUILD_DIR)/$(polarssl_dir)/Makefile: $(SRC_DIR)/$(polarssl_dir)/configure
mkdir -p $(BUILD_DIR)/$(polarssl_dir)
cd $(BUILD_DIR)/$(polarssl_dir) \
&& PKG_CONFIG_LIBDIR=$(prefix)/lib/pkgconfig CONFIG_SITE=$(SRC_DIR)/build/$(config_site) \
$(SRC_DIR)/$(polarssl_dir)/configure --prefix=$(prefix) --host=$(host) ${library_mode}
clean-${polarssl_project}:
cd $(polarssl_build_dir) && \
make clean
build-polarssl: $(BUILD_DIR)/$(polarssl_dir)/Makefile
cd $(BUILD_DIR)/${polarssl_dir} && \
host_alias=$(host) PKG_CONFIG_LIBDIR=$(prefix)/lib/pkgconfig CONFIG_SITE=$(SRC_DIR)/build/$(config_site) make && make install
veryclean-${polarssl_project}:
if [ -d $(polarssl_build_dir) ]; then grep -v $(prefix) $(polarssl_build_dir)/install_manifest.txt | xargs rm; fi && \
rm -rf $(polarssl_build_dir)
clean-polarssl:
-cd $(BUILD_DIR)/$(polarssl_dir) && make clean
clean-makefile-${polarssl_project}: veryclean-${polarssl_project}
veryclean-polarssl:
-rm -rf $(BUILD_DIR)/$(polarssl_dir)
-rm -f $(SRC_DIR)/$(polarssl_dir)/configure
clean-makefile-polarssl: veryclean-polarssl

View file

@ -1,4 +1,5 @@
############################################################################
# zrtp.mk
# Copyright (C) 2014 Belledonne Communications,Grenoble France
#
############################################################################
@ -18,34 +19,48 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
bzrtp_dir?=bzrtp
enable_zrtp?=yes
bzrtp_project:=bzrtp
bzrtp_project_dir:=.
bzrtp_cmake_specific_options:=-DENABLE_STATIC=YES
configure-options=
ifeq ($(LINPHONE_CCACHE), ccache)
configure-options+= --disable-strict
endif
bzrtp_src_dir=$(BUILDER_SRC_DIR)/${bzrtp_project_dir}/${bzrtp_project}
bzrtp_build_dir=$(BUILDER_BUILD_DIR)/${bzrtp_project_dir}/${bzrtp_project}
$(BUILDER_SRC_DIR)/$(bzrtp_dir)/configure:
@echo -e "\033[01;32m Running autogen for bzrtp in $(BUILDER_SRC_DIR)/$(bzrtp_dir) \033[0m"
cd $(BUILDER_SRC_DIR)/$(bzrtp_dir) && ./autogen.sh
${bzrtp_build_dir}/Makefile:
rm -rf ${bzrtp_build_dir}/CMakeCache.txt ${bzrtp_build_dir}/CMakeFiles/ && \
mkdir -p ${bzrtp_build_dir} && \
cd ${bzrtp_build_dir} && \
cmake -DCMAKE_TOOLCHAIN_FILE=$(BUILDER_SRC_DIR)/build/toolchain.cmake -DIOS_ARCH=${ARCH} \
-DCMAKE_INSTALL_PREFIX=$(prefix) -DCMAKE_PREFIX_PATH=$(prefix) -DCMAKE_MODULE_PATH=$(prefix)/share/cmake/Modules/ \
${bzrtp_cmake_specific_options} ${bzrtp_src_dir}
$(BUILDER_BUILD_DIR)/$(bzrtp_dir)/Makefile: $(BUILDER_SRC_DIR)/$(bzrtp_dir)/configure
@echo -e "\033[01;32m Running configure in $(BUILDER_BUILD_DIR)/$(bzrtp_dir) \033[0m"
mkdir -p $(BUILDER_BUILD_DIR)/$(bzrtp_dir)
cd $(BUILDER_BUILD_DIR)/$(bzrtp_dir)/ \
&& host_alias=${host} . $(BUILDER_SRC_DIR)/build/$(config_site) \
&& PKG_CONFIG_LIBDIR=$(prefix)/lib/pkgconfig CONFIG_SITE=$(BUILDER_SRC_DIR)/build/$(config_site) \
$(BUILDER_SRC_DIR)/$(bzrtp_dir)/configure -prefix=$(prefix) --host=$(host) ${library_mode} \
--enable-static ${configure-options}
build-${bzrtp_project}: ${bzrtp_build_dir}/Makefile
cd ${bzrtp_build_dir} && \
make && \
make install
ifeq ($(enable_zrtp),yes)
clean-${bzrtp_project}:
cd $(bzrtp_build_dir) && \
make clean
build-bzrtp: $(BUILDER_BUILD_DIR)/$(bzrtp_dir)/Makefile
@echo -e "\033[01;32m building bzrtp \033[0m"
cd $(BUILDER_BUILD_DIR)/$(bzrtp_dir) \
&& PKG_CONFIG_LIBDIR=$(prefix)/lib/pkgconfig \
CONFIG_SITE=$(BUILDER_SRC_DIR)/build/$(config_site) \
make -j1 && make install
veryclean-${bzrtp_project}:
if [ -d $(bzrtp_build_dir) ]; then grep -v $(prefix) $(bzrtp_build_dir)/install_manifest.txt | xargs rm; fi && \
rm -rf $(bzrtp_build_dir)
else
build-bzrtp:
@echo "ZRTP is disabled"
clean-makefile-${bzrtp_project}: veryclean-${bzrtp_project}
endif
clean-bzrtp:
-cd $(BUILDER_BUILD_DIR)/$(bzrtp_dir) && make clean
veryclean-bzrtp:
-cd $(BUILDER_BUILD_DIR)/$(bzrtp_dir) && make distclean
rm -f $(BUILDER_SRC_DIR)/$(bzrtp_dir)/configure
clean-makefile-bzrtp:
-cd $(BUILDER_BUILD_DIR)/$(bzrtp_dir) && rm -f Makefile