移植一个C ++应用程序到Android [英] Porting a C++ application to android

查看:194
本文介绍了移植一个C ++应用程序到Android的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有可能端口,它使用STL广泛到Android C ++应用程序?据我所知,目前NDK并不支持这一点,但没有任何工作(开源或其他方式)正在为实现这一目标?

Is it possible to port a C++ application which uses the STL extensively to Android? I understand that currently the NDK does not support this, but is there any effort (open source or otherwise) underway to achieve this?

如果不是有没有办法交叉编译的libstdc ++为Android?

If not is there a way to cross compile libstdc++ for Android?

更新:
NDK版本5的承诺基础上的STLport默认STL实现。
http://android-developers.blogspot.com/2011/01 /gingerbread-ndk-awesomeness.html 阅读本官NDK博客文章和修改说明。

UPDATE: Ndk Revision 5 promises a default STL implementation based on STLport. http://android-developers.blogspot.com/2011/01/gingerbread-ndk-awesomeness.html Read this official NDK blog post, and the revision notes.

推荐答案

您可能要开始的梅德Moskalchuk的NDK的的修改版本(包括对异常的支持,RTTI,标准C ++库)。请记住,如果你走这条路你的应用程序的尺寸会更大,因为你将静态链接一个C ++库进去。此外,从安卓-NDK组此线程可能会关于如何把STL更好的方向发展。

You may want to start with Dmitry Moskalchuk's modified version of the NDK (includes support for exceptions, RTTI, and the standard c++ library). Keep in mind that if you go down this path your application's size will be larger as you will be statically linking a c++ library into it. Also, this thread from the andriod-ndk group may give better direction on how to incorporate the STL.

这篇关于移植一个C ++应用程序到Android的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆