在 Eclipse 中构建 Android 源应用程序
我在这里下载了备件的源代码
https://android.googlesource .com/platform/development/+/gingerbread-release/apps/SpareParts
它包括 Android.mk
、AndroidManifest.xml
、 Notice
、res
和 src
文件夹。
我的问题是如何在 Eclipse 中编译这个源代码?我看到有一个 make 文件 (Android.mk
),我猜我需要使用它,但我不知道该怎么做才能将这个东西导入到 Eclipse 中而不出现 500 多个错误。
I downloaded the source to spareparts here
https://android.googlesource.com/platform/development/+/gingerbread-release/apps/SpareParts
It includes Android.mk
, AndroidManifest.xml
, Notice
, res
and src
folders.
My question is how can I compile this source code in Eclipse? I see there is a make file (Android.mk
) which I'm guessing I need to use but I can't figure out what to do to get this thing imported into Eclipse without having 500+ errors.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
这篇文章似乎有答案。不过,根据它,您需要下载所有源代码才能构建其中一个应用程序。
This article seems to have the answer. According to it you would need to download all of the source just to build one of the apps, though.
蛮力总是有效:)
我查看了文件,它似乎没有使用任何外部库。
如果你尝试自己构建它,你仍然会遇到问题,因为这三个类不在 android.jar 中:
Brute force always works :)
I looked into the files and it does not seem that it uses any external library.
If you try to build it by itself, you will still have problems due to these three classes that are not in android.jar:
在 Eclipse 中尝试“文件”->“导入...”和“常规”->“现有项目到工作区”,添加项目文件夹,然后尝试编译它。希望有帮助。
In Eclipse try File->Import... and General->Existing Projects into Workspace, add the project folder and then try to compile it. Hope it helps.