ubuntu18.04编译 tiny4412 Android-5.0.2 源码
一、原因
????????一直在学习韦老师的Android系列课程,该课程基于ubuntu12.04系统开发,可最近ubuntu12.04系统在“sudo apt-get update”时更新源出了问题,导致很多库、应用无法下载与使用。不得已ubuntu18.04搭建一个tiny4412 Android-5.0.2开发环境。
二、操作流程
2.1适配JDK
JDK版本为:openjdk-1.7.0_121。
下载地址:
https://download.csdn.net/download/tenyearsafterg/10462952
适配参考网址:
https://askubuntu.com/questions/1034387/how-can-i-install-jdk7-on-ubuntu-18-04-lts-64bit
????????安装开发包时install-devel-packages.sh时会出现有些无法安装,可手动“apt-get install”下载其他版本。
三、编译问题
问题1
解决:
https://blog.csdn.net/lincyang/article/details/73302225
?解决:
1、输入"make update-api"再重新编译。
2、参考网址https://blog.csdn.net/dianshanglian/article/details/45092195
将其中加入
sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/local/java/openjdk-1.7.0_121/bin/javadoc" 1
sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/local/java/openjdk-1.7.0_121/bin/javah" 1
sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/local/java/openjdk-1.7.0_121/bin/jar" 1
sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/local/java/openjdk-1.7.0_121/bin/javap" 1
sudo update-alternatives --set javaws /usr/local/java/openjdk-1.7.0_121/bin/javadoc
sudo update-alternatives --set javaws /usr/local/java/openjdk-1.7.0_121/bin/javah
sudo update-alternatives --set javaws /usr/local/java/openjdk-1.7.0_121/bin/jar
sudo update-alternatives --set javaws /usr/local/java/openjdk-1.7.0_121/bin/javap
|