Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/186.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
我可以在Mac上的Android Studio中构建Linphone吗?_Android_Android Ndk_Linphone - Fatal编程技术网

我可以在Mac上的Android Studio中构建Linphone吗?

我可以在Mac上的Android Studio中构建Linphone吗?,android,android-ndk,linphone,Android,Android Ndk,Linphone,我认为我们可以建造它。但我在Android Studio上构建它时出错了。首先,我下载了Android Studio和NDK。然后将androidstudio和NDK的路径添加到PATH变量中。当我跑的时候 ./check_tools.sh 我得到输出 Could not find automake. Please install it. Could not find autoconf. Please install it. Could not find pkg-config. Please

我认为我们可以建造它。但我在Android Studio上构建它时出错了。首先,我下载了Android Studio和NDK。然后将androidstudio和NDK的路径添加到PATH变量中。当我跑的时候

./check_tools.sh
我得到输出

Could not find automake. Please install it.
Could not find autoconf. Please install it.
Could not find pkg-config. Please install it.
Could not find ant. Please install it.
Could not find yasm. Please install it.
Could not find wget. Please install it.
Could not find libtoolize. Please install libtool.
Invalid version of nasm: your version does not support elf32 output format. If you have installed nasm, please check that your PATH env variable is set correctly.
Failed to detect required tools, aborting.
但我怀疑在Android Studio上是否需要这些工具。当我运行这个项目时,我得到了一个错误

java.lang.UnsatisfiedLinkError: Couldn't load linphone-armeabi-v7a: findLibrary returned null.

谁能告诉我解决这个问题的办法吗

我可以通过以下步骤在mac上构建limphone:-


构建linphone肯定需要这些工具。 关于纳斯姆,我也有同样的问题。您可以使用此网站指导您如何升级到较新的nasm:

关于其他有用的工具,您可以使用此命令安装以下工具:

$sudo port install coreutils automake autoconf libtool intltool wget pkgconfig cmake gmake yasm grep doxygen ImageMagick optipng antlr3
所有这些都可以在linphone build instructions README.md文件中找到。

是的,您可以这样做 请遵循本博客中的《分步指南》

这是一个分步指南。 在Mac OS X上安装Linphone Sdk 如何在Mac上的Android Studio中构建Linphone? 分步指南:-

所需知识:- Android工具 安卓工作室 关于mac终端(外壳)的一点信息

S/W要求:- 使用这些工具的Mac OS-X(您确实需要这些工具来构建linphone):-

coreutils、automake、autoconf、libtool、intltool、wget、pkgconfig、cmake、, gmake、yasm、grep、doxygen、ImageMagick、optipng、antlr3

第1步:- 关于这些有用的工具,您可以使用此命令安装这些工具

第2步:-
看看这些

第3步:- 然后键入
安装ant

brew update     #update if already installed
brew install ant
如果尚未安装brew,请键入下面的命令

这是一个中等大小的下载,需要5分钟下载

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
只需遵循安装各种组件的过程即可。如果已安装brew,请执行以下操作以确保它是最新的:

brew update
安装后,您只需键入:

brew install ant  
第4步:- 现在是安装libtool的时候了。要安装libtool,请运行下面给出的命令

 curl -OL http://ftpmirror.gnu.org/libtool/libtool-2.4.2.tar.gz
 tar -xzf libtool-2.4.2.tar.gz
 cd libtool-2.4.2
 ./configure && make && sudo make install
第5步:- 如果尚未安装这些程序,请下载并安装 下载 下载

第6步:- 通过运行命令下载LInphone Android的git存储库

$ sudo git clone git://git.linphone.org/linphone-android.git –recursive
现在一切都配置得很完美

第7步:-
终端
cd打开到linphone android中

现在,当您进入终端上的目录时,请检查您在Mac上运行的SDK&NDK的
路径

$ echo $PATH
如果您看到带有SDK和NDK位置的路径,则可以继续跳过下面的部分,如果没有,则需要在中执行make和make安装脚本之前设置路径

要设置路径,请使用:-

$export PATH=/Users/<yourusername>/android-sdks/platform-tools/:/Users//android-sdks/tools/:/Users//Documents/ndk/:/nobackup/local/prog/nasm/bin/:$PATH
现在,如果路径已经设置好,您只需运行

$ make
现在将您的设备连接到Mac上,看看eclipse是否检测到了它。连接设备后,运行:

$ make install
现在,如果一切正常:-

完成构建后,现在可以将其导入Android Studio

开放安卓工作室


导入项目(Eclipse、ADT、Gradle等)>选择linphone android>OK

您对这个过程不熟悉,这让经典的交叉编译器头疼不已。您最好的实际选择是查看是否有其他人已经了解了端口进程。否则,您可能希望在linux虚拟机中构建(并瞄准)它,以熟悉正在发生的事情,在您尝试为无法运行这些自动配置步骤的目标进行交叉构建之前,我找到了一些Eclipse教程,但没有找到Android Studio的教程。这不是Mac的问题,而是Android Studio的问题。Eclipse和Android Studio都没有有意义的参与;这是项目和ndk工具链的一个问题。您发布的实际错误消息是因为您的mac没有配置为将此项目构建为在mac上运行,但您不希望这样做。您需要安装缺少的工具,并说服项目为android而不是您正在构建的mac进行构建。@ChrisStratton谢谢您的评论。你能告诉我如何下载丢失的工具吗?
$ make
$ make install