ubuntu14.04 android develop environment setup for android and linux driver

來源:互聯網
上載者:User

標籤:

//For android and linux driver//

1,install ubuntu14.04

  usb boot, CD boot, vmware workstation install, etc

  take usb boot for an example, download Universal-USB-Installer-1.9.5.6.exe and ubuntu-14.04.2-desktop-amd64.iso at windows xp platform.

  

   i take my disk for 4 partition to install ubuntu:

  /boot     500M    ubuntu startup program

  swap    8G     like pagefile at windows

  /home    500G          my work space, it will not be broken even though the ubuntu system was broken

  /      100G           system

 

2,remove openjdk

  sudo apt-get purge openjdk*

 

  the different betwent openjdk and sunjdk:  

著作權歸作者所有。商業轉載請聯絡作者獲得授權,非商業轉載請註明出處。Aloys寒風連結:http://www.zhihu.com/question/19646618/answer/40621705來源:知乎曆史上的原因是,OpenJDK是JDK的開放原始碼版本,以GPL(General Public License)協議的形式放出(題主提到的open就是指的開源)。在JDK7的時候,OpenJDK已經作為JDK7的主幹開發,SUN JDK7是在OpenJDK7的基礎上發布的,其大部分原始碼都相同,只有少部分原始碼被替換掉。使用JRL(JavaResearch License,Java研究授權協議)發布。至於OpenJDK6則更是有其複雜的一面,首先是OpenJDK6是JDK7的一個分支,並且盡量去除Java SE7的新特性,使其盡量的符合Java6的標準。關於JDK和OpenJDK的區別,可以歸納為以下幾點:授權協議的不同:OpenJDK採用GPL V2協議放出,而SUN JDK則採用JRL放出。兩者協議雖然都是開放原始碼的,但是在使用上的不同在於GPL V2允許在商業上使用,而JRL只允許個人研究使用。OpenJDK不包含Deployment(部署)功能:部署的功能包括:Browser Plugin、Java Web Start、以及Java控制台,這些功能在OpenJDK中是找不到的。OpenJDK原始碼不完整:這個很容易想到,在採用GPL協議的OpenJDK中,SUN JDK的一部分原始碼因為產權的問題無法開放給OpenJDK使用,其中最主要的部份就是JMX中的可選元件SNMP部份的代碼。因此這些不能開放的原始碼 將它作成plug,以供OpenJDK編譯時間使用,你也可以選擇不要使用plug。而Icedtea則為這些不完整的部分開發了相同功能的原始碼 (OpenJDK6),促使OpenJDK更加完整。部分原始碼用開原始碼替換:由於產權的問題,很多產權不是SUN的原始碼被替換成一些功能相同的開原始碼,比如說字型柵格化引擎,使用Free Type代替。OpenIDK只包含最精簡的JDK:OpenJDK不包含其他的軟體包,比如Rhino Java DB JAXP……,並且可以分離的軟體包也都是盡量的分離,但是這大多數都是自由軟體,你可以自己下載加入。不能使用Java商標:這個很容易理解,在安裝OpenJDK的機器上,輸入“java-version”顯示的是OpenJDK,但是如果是使用Icedtea補丁的OpenJDK,顯示的是java。
View Code

 

 

3,install Oracle Java JDK

  download address: http://www.oracle.com/technetwork/java/javasebusiness/downloads/java-archive-downloads-javase6-419409.html

  choose:jdk-6u38-linux-x64.bin

  $ sudo mkdir /usr/local/java

  $ sudo cp $HOME/Download/jdk-6u38-linux-x64.bin /usr/local/java

  $ cd /usr/local/java

  $ chmod +x jdk-6u38-linux-x64.bin

  $ ./jdk-6u38-linux-x64.bin

  

  configure JAVA_HOME and PATH in system environment:  

$ sudo vi /etc/profile add below code in /etc/profile :    JAVA_HOME=/usr/local/java/jdk1.6.0_45    PATH=$PATH:$HOME/bin:$JAVA_HOME/bin    export JAVA_HOME    export PATH  

 

sudo update-alternatives --install "/usr/bin/java" "java" "/usr/local/java/jdk1.6.0_38/bin/java" 1sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/local/java/jdk1.6.0_38/bin/javac" 1sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/local/java/jdk1.6.0_38/bin/javaws" 1sudo update-alternatives --set java /usr/local/java/jdk1.6.0_38/bin/javasudo update-alternatives --set javac /usr/local/java/jdk1.6.0_38/bin/javacsudo update-alternatives --set javaws /usr/local/java/jdk1.6.0_38/bin/javaws

 

$ . /etc/profile$ java -version    java version "1.6.0_38"    Java(TM) SE Runtime Environment (build 1.6.0_38-b05)    Java HotSpot(TM) 64-Bit Server VM (build 20.13-b02, mixed mode)

 

4,install some to support 32bit lib and software

  sudo apt-get install ia32-libs

  as no source for ia32-libs installtion,it can be replaced for 3 package:

  sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0

5,install development tool, lib, and etc for ubuntu14.04

  sudo apt-get install build-essential  sudo apt-get install make  sudo apt-get install gcc  sudo apt-get install g++  sudo apt-get install libc6-dev  sudo apt-get install patch  sudo apt-get install texinfo  sudo apt-get install libncurses-dev  sudo apt-get install git-core gnupg  sudo apt-get install flex  sudo apt-get install bison  sudo apt-get install gperf  sudo apt-get install libsdl-dev  sudo apt-get install libesd0-dev  sudo apt-get install libwxgtk2.6-dev (failed)(install 2.8)  sudo apt-get install build-essential  sudo apt-get install zip  sudo apt-get install curl  sudo apt-get install ncurses-dev  sudo apt-get install zlib1g-dev  sudo apt-get install valgrind  sudo apt-get install python2.5(failed to install, can ignore)  sudo apt-get install libgtk2.0-0:i386  sudo apt-get install libpangox-1.0-0:i386  sudo apt-get install libpangoxft-1.0-0:i386  sudo apt-get install libidn11:i386  sudo apt-get install gstreamer0.10-pulseaudio:i386  sudo apt-get install gstreamer0.10-plugins-base:i386  sudo apt-get install gstreamer0.10-plugins-good:i386  sudo apt-get install gstreamer0.10-ffmpeg:i386(failed to install can ignore)

 

6. down A20 source code to build in ubuntu14.04

  this source code is contain cross-tool, it can save my time to build an another cross-tool.

 

7. "mkimage" command not found - U-Boot images will not be built

  sudo apt-get install u-boot-tools

 

8./bin/bash: jar: command not found

  $ cd /usr/bin

  $ sudo ln -s -f /usr/local/java/jdk1.6.0_38/bin/jar

9. /usr/include/stdlib.h:760:34: fatal error: bits/stdlib-bsearch.h: No such file or directory

  sudo apt-get install libc6-dev:i386      [it will remove install for os 64 bit and reinstall for i386]

  sudo apt-get install build-essential

  sudo apt-get install gcc-multilib

  sudo apt-get install ubuntu-desktop     [because uninstall ibus, make ubuntu14.04 lose systemsetting item, reinstall ubuntu-desktop could solve this problem]

 

10. BEGIN failed--compilation aborted at external/webkit/Source/WebCore/make-hash-tools.pl line 23.  

  sudo apt-get install libswitch-perl

  sudo apt-get install libxml2-utils

 

11./bin/bash: line 2: javadoc: command not found
  $ cd /usr/bin  

  $ sudo ln -s -f /usr/local/java/jdk1.6.0_38/bin/jar

   

12.finally, A20‘s develop environment was setup successfully

 

ubuntu14.04 android develop environment setup for android and linux driver

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.