[Switch submodule branch] Update cmake-builder submodule.
This commit is contained in:
parent
c5306f3cdd
commit
03e848d0e8
3 changed files with 57 additions and 4 deletions
25
cmake_builder/CMakeLists.txt
Normal file
25
cmake_builder/CMakeLists.txt
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
############################################################################
|
||||||
|
# CMakeLists.txt
|
||||||
|
# Copyright (C) 2018 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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||||
|
#
|
||||||
|
############################################################################
|
||||||
|
|
||||||
|
# Blacklist these dependencies because they are useless for now
|
||||||
|
lcb_blacklist_dependencies("libxsd" "xerces-c" "soci")
|
||||||
|
|
34
prepare.py
34
prepare.py
|
@ -50,6 +50,10 @@ class AndroidTarget(prepare.Target):
|
||||||
self.toolchain_file = 'toolchains/toolchain-android-' + arch + '.cmake'
|
self.toolchain_file = 'toolchains/toolchain-android-' + arch + '.cmake'
|
||||||
self.output = 'liblinphone-sdk/android-' + arch
|
self.output = 'liblinphone-sdk/android-' + arch
|
||||||
self.external_source_path = os.path.join(current_path, 'submodules')
|
self.external_source_path = os.path.join(current_path, 'submodules')
|
||||||
|
external_builders_path = os.path.join(current_path, 'cmake_builder')
|
||||||
|
self.additional_args = [
|
||||||
|
"-DLINPHONE_BUILDER_EXTERNAL_BUILDERS_PATH=" + external_builders_path
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
class AndroidArmTarget(AndroidTarget):
|
class AndroidArmTarget(AndroidTarget):
|
||||||
|
@ -140,7 +144,7 @@ class AndroidPreparator(prepare.Preparator):
|
||||||
retval = True
|
retval = True
|
||||||
ndk_build = find_executable('ndk-build')
|
ndk_build = find_executable('ndk-build')
|
||||||
ndk_path = os.path.dirname(ndk_build)
|
ndk_path = os.path.dirname(ndk_build)
|
||||||
# NDK prior to r11 had a RELEASE.TXT file holding the version number
|
# NDK prior to r11 had a RELEASE.TXT file holding the version number
|
||||||
release_file = os.path.join(ndk_path, 'RELEASE.TXT')
|
release_file = os.path.join(ndk_path, 'RELEASE.TXT')
|
||||||
if os.path.isfile(release_file):
|
if os.path.isfile(release_file):
|
||||||
version = open(release_file).read().strip()
|
version = open(release_file).read().strip()
|
||||||
|
@ -156,8 +160,19 @@ class AndroidPreparator(prepare.Preparator):
|
||||||
if len(python_config_files) > 0:
|
if len(python_config_files) > 0:
|
||||||
version = open(python_config_files[0]).readlines()[0]
|
version = open(python_config_files[0]).readlines()[0]
|
||||||
res = re.match('^.*/(aosp-)?ndk-r(\d+).*$', version)
|
res = re.match('^.*/(aosp-)?ndk-r(\d+).*$', version)
|
||||||
version = int(res.group(2))
|
if res is not None: # Will be if NDK < 16
|
||||||
retval = False
|
version = int(res.group(2))
|
||||||
|
retval = False
|
||||||
|
else:
|
||||||
|
release_file = os.path.join(ndk_path, 'source.properties') # Since NDK 16
|
||||||
|
if os.path.isfile(release_file):
|
||||||
|
version = open(release_file).read().strip()
|
||||||
|
res = re.findall(r'(?:(\d+))', version)
|
||||||
|
version = int(res[0])
|
||||||
|
retval = False
|
||||||
|
else:
|
||||||
|
error("Could not get Android NDK version!")
|
||||||
|
sys.exit(-1)
|
||||||
else:
|
else:
|
||||||
error("Could not get Android NDK version!")
|
error("Could not get Android NDK version!")
|
||||||
sys.exit(-1)
|
sys.exit(-1)
|
||||||
|
@ -238,6 +253,7 @@ $(TOPDIR)/res/raw/rootca.pem:
|
||||||
copy-libs:
|
copy-libs:
|
||||||
\trm -rf libs-debug/armeabi
|
\trm -rf libs-debug/armeabi
|
||||||
\trm -rf libs/armeabi
|
\trm -rf libs/armeabi
|
||||||
|
\trm -rf src/linphone-wrapper && mkdir -p src/linphone-wrapper/
|
||||||
\tif test -d "liblinphone-sdk/android-arm"; then \\
|
\tif test -d "liblinphone-sdk/android-arm"; then \\
|
||||||
\t\tmkdir -p libs-debug/armeabi && \\
|
\t\tmkdir -p libs-debug/armeabi && \\
|
||||||
\t\tcp -f liblinphone-sdk/android-arm/lib/lib*.so libs-debug/armeabi && \\
|
\t\tcp -f liblinphone-sdk/android-arm/lib/lib*.so libs-debug/armeabi && \\
|
||||||
|
@ -304,6 +320,18 @@ copy-libs:
|
||||||
\t\tcp -f liblinphone-sdk/android-x86/bin/gdbserver libs/x86 && \\
|
\t\tcp -f liblinphone-sdk/android-x86/bin/gdbserver libs/x86 && \\
|
||||||
\t\tcp -f liblinphone-sdk/android-x86/bin/gdb.setup libs/x86; \\
|
\t\tcp -f liblinphone-sdk/android-x86/bin/gdb.setup libs/x86; \\
|
||||||
\tfi
|
\tfi
|
||||||
|
\tif test -d "liblinphone-sdk/android-arm/share/linphonej"; then \\
|
||||||
|
\t\tcp -R liblinphone-sdk/android-arm/share/linphonej/java/* src/linphone-wrapper; \\
|
||||||
|
\tfi
|
||||||
|
\tif test -d "liblinphone-sdk/android-armv7/share/linphonej"; then \\
|
||||||
|
\t\tcp -R liblinphone-sdk/android-armv7/share/linphonej/java/* src/linphone-wrapper; \\
|
||||||
|
\tfi
|
||||||
|
\tif test -d "liblinphone-sdk/android-arm64/share/linphonej"; then \\
|
||||||
|
\t\tcp -R liblinphone-sdk/android-arm64/share/linphonej/java/* src/linphone-wrapper; \\
|
||||||
|
\tfi
|
||||||
|
\tif test -d "liblinphone-sdk/android-x86/share/linphonej"; then \\
|
||||||
|
\t\tcp -R liblinphone-sdk/android-x86/share/linphonej/java/* src/linphone-wrapper; \\
|
||||||
|
\tfi
|
||||||
|
|
||||||
copy-libs-mediastreamer:
|
copy-libs-mediastreamer:
|
||||||
\trm -rf submodules/mediastreamer2/java/libs/armeabi
|
\trm -rf submodules/mediastreamer2/java/libs/armeabi
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit a6dff67cc8e5bb1e930cf1629dec835f94d6d626
|
Subproject commit bd973554739e1e991a8726e6a9b80ba0e78950fa
|
Loading…
Reference in a new issue