In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article will explain in detail how to compile Android source code in Ubuntu9.10, the content of the article is of high quality, so the editor will share it with you for reference. I hope you will have some understanding of the relevant knowledge after reading this article.
Under Ubuntu8.04, everything should go well, but I installed version 9.10, so there will be some problems.
Install jdk1.5 first, there is a slight problem with 1.6 on the Internet, so I didn't install 1.6, I chose 1.5. Then install some necessary programs, apt-get install * a lot of messy, can be found on the Internet, and then download the android source code.
Downloading the source code requires git,curl and repo,git and curl can be directly used with apt-get install git-core curl
Then download repo
Curl http://android.git.kernel.org/repo > ~ / bin/repo
Add executable permissions
Sudo chmod + x repo
Initialize repo
Repo init-u git://android.git.kernel.org/platform/manifest.git
If you only need a certain version, for example, I just want cupcake
Repo init-u git://android.git.kernel.org/platform/manifest.git-b cupcake
And then set up a directory.
Mkdir android
Enter
Cd android
download
Repo sync
Then just wait, about two gigabytes of content is the slowest when getting 39% and 95%, because 39% has more than 100 MPIs and 95% has almost 400m.
After downloading, do not make first, because there are a few more questions:
1. If you make directly, you will see frameworks/policies/base/PolicyConfig.mk:22: * No module defined for the given PRODUCT_POLICY (android.policy_phone). Stop. Mistake.
Solution:
Line 89 in build/tools/findleaves.sh
This sentence find "${@: 0:$nargs}" $findargs-type f-name "$filename"-print |
Change to find "${@: 1:$nargs-1}" $findargs-type f-name "$filename"-print |
Error of 2.frameworks/base/tools/aidl/AST.cpp:10: error: 'fprintf' was not declared in this scope
Solution:
Download gcc-4.3 and glossy music 4.3
Apt-get install gcc-4.3 gathers music 4.3
About ten trillion, and then
Enter / usr/bin
Cd / usr/bin
Build a soft connection
Ln-s gcc-4.3 gcc
Ln-s glossy music music 4.3 gags +
Then go to the android directory, execute make, and that's fine.
I make in the virtual machine and gave him 1G of memory and 50% of the processor, which took a total of two hours to compile. After the compilation is completed, there are about two gigabytes in the out folder under the android directory.
In the out/target/product/generic directory, there are three img files, system.img,ramdisk.img,userdata.img, which are the required android system image files. Just put them in the simulator and run them.
On how to compile Android source code in Ubuntu9.10 to share here, I hope the above content can be of some help to you, you can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.