`
zengxx1989
  • 浏览: 294969 次
  • 性别: Icon_minigender_1
  • 来自: 湖南
社区版块
存档分类
最新评论

android sdk linux 1.5 安装与配置

阅读更多
1.下载android sdk
下载地址如下:
http://dl.google.com/android/android-sdk-windows-1.5_r2.zip
http://dl.google.com/android/android-sdk-linux_x86-1.5_r2.zip
2.下载eclipse 3.4.2
按官方文档说,android sdk 可以运行在eclipse 3.3以上的IDE中,ubuntu源中的eclipse版本过低,建议使用eclipse 3.4.2,其下载地址为:
http://download.actuatechina.com/eclipse/eclipse/downloads/drops/R-3.4.2-200902111700/eclipse-SDK-3.4.2-linux-gtk.tar.gz
3.安装eclipse 3.4.2
先将eclipse解压:
$tar xzvf eclipse-SDK-3.4.2-linux-gtk.tar.gz
将解压出的eclipse文件夹移动到目标目录中去,在这里我设定的安装目标为:/usr/local下。
$sudo mv eclipse /usr/local/
4.安装android sdk
解压android sdk包:
$unzip android-sdk-linux_x86-1.5_r2.zip
移动到目标目录:<在这里我将解压出的sdk文件夹目录改成了android-sdk>
$mv android-sdk-linux_x86-1.5_r2 android-sdk
$sudo mv android-sdk /usr/local/
5.配置环境变量:
修改~/.bashrc文件,加入android sdk与eclipse的环境变量。
$vi ~/.bashrc
在文件的最后加入
export PATH=/usr/local/android-sdk/tools:/usr/local/eclipse:$PATH
保存并退出vi
使配置信息生效
$source ~/.bashrc
6.android avd配置信息的生成
android avd的创建格式为:android create avd -n your-avd-name -t your-targets
其中:-n的参数为我们要创建的avd的名字;-t的参数为Available Android targets的id,我们可以使用命令:android list查寻其具体信息。
$android list

Available Android targets:
id: 1
     Name: Android 1.1
     Type: Platform
     API level: 2
     Skins: HVGA-P, HVGA (default), QVGA-P, HVGA-L, QVGA-L
id: 2
     Name: Android 1.5
     Type: Platform
     API level: 3
     Skins: HVGA-P, HVGA (default), QVGA-P, HVGA-L, QVGA-L
id: 3
     Name: Google APIs
     Type: Add-On
     Vendor: Google Inc.
     Description: Android + Google APIs
     Based on Android 1.5 (API level 3)
     Libraries:
      * com.google.android.maps (maps.jar)
          API for Google Maps
     Skins: QVGA-P, HVGA-L, HVGA (default), QVGA-L, HVGA-P
Available Android Virtual Devices:

下面我们就以创建一个android 1.5的avd为例:

$android create avd -n android-sdk-15 -t 2

Android 1.5 is a basic Android platform.
Do you wish to create a custom hardware profile [no]yes

Device ram size: The amount of physical RAM on the device, in megabytes.
hw.ramSize [96]:128

Touch-screen support: Whether there is a touch screen or not on the device.
hw.touchScreen [yes]:yes

Track-ball support: Whether there is a trackball on the device.
hw.trackBall [yes]:yes

Keyboard support: Whether the device has a QWERTY keyboard.
hw.keyboard [yes]:yes

DPad support: Whether the device has DPad keys
hw.dPad [yes]:yes

GSM modem support: Whether there is a GSM modem in the device.
hw.gsmModem [yes]:yes

Camera support: Whether the device has a camera.
hw.camera [no]:

Camera support: Whether the device has a camera.
hw.camera [no]:yes

Maximum horizontal camera pixels
hw.camera.maxHorizontalPixels [640]:854

Maximum vertical camera pixels
hw.camera.maxVerticalPixels [480]:480

GPS support: Whether there is a GPS in the device.
hw.gps [yes]:yes

Battery support: Whether the device can run on a battery.
hw.battery [yes]:yes

Accelerometer: Whether there is an accelerometer in the device.
hw.accelerometer [yes]:yes

Audio recording support: Whether the device can record audio
hw.audioInput [yes]:yes

Audio playback support: Whether the device can play audio
hw.audioOutput [yes]:yes

SD Card support: Whether the device supports insertion/removal of virtual SD Cards.
hw.sdCard [yes]:yes

Cache partition support: Whether we use a /cache partition on the device.
disk.cachePartition [yes]:yes

Cache partition size
disk.cachePartition.size [66MB]:100MB

Created AVD ''android-sdk-15'' based on Android 1.5

这样我们就创建了一个基于1.5的avd,上面的具体意思我想大家都能看懂,就不多说了。下在我们就可以测试一下android emulator了:

$emulator @android-sdk-15 -show-kernel

这样就可以启动android emulator了:

加入参数-show-kernel是为了在终端上打印android kernel的信息。
分享到:
评论
1 楼 wshxx998 2010-10-06  
请问你的在配置SDK路径的时候使用的是root帐号还是普通帐号,配置的是全局的路径还是个人用户的路径,我是用的Myeclipse 8.6来集成的,配了路径之后我的Fedora 13就跨了!

相关推荐

    pro_android_cpp_with_the_ndk.pdf

    1.3.6 在Linux平台上下载并安装AndroidSDK 1.3.7 在Linux平台上下载并安装AndroidNDK 1.3.8 在Linux平台上下载并安装Eclipse 1.4 下载并安装ADT 1.4.1 安装Android平台包 1.4.2 配置模拟器 1.5 小结 第2章 深入了解...

    新版Android开发教程.rar

    Android SDK tools included in Android 1.1 SDK, Release 1. Supported Supported Supported Supported Operating Operating Operating Operating Systems Systems Systems Systems • Windows XP (32-bit) or ...

    中文版Android程序员入门

    中文版Android程序员入门 目 录 I 关于本博客的主题 IV 第一章 什么是Android 1 什么是Android - 嵌入式设备编程的历史-第一章(1) 1 开放手机联盟和Android-(2) 2 ...Android SDK 1.5 - 包装索引 191

    Android程序员入门(中文版).doc

    目 录 I 关于本博客的主题 IV 第一章 什么是Android 1 什么是Android - 嵌入式设备编程的历史-第一章(1) 1 开放手机联盟和Android-(2) 2 介绍Android 第一章(3) 3 ...Android SDK 1.5 - 包装索引 191

    android开发指南

    目 录 I 关于本博客的主题 III 第一章 什么是Android 1 什么是Android - 嵌入式设备编程的历史-第一章(1) 1 开放手机联盟和Android-(2) 2 介绍Android 第一章(3) 2 ...Android SDK 1.5 - 包装索引 169

    《Android高级编程》

    作为使用AndroidSDK构建这些应用程序的实用指南书籍,《Android高级编程》从始至终穿插了一系列示例项目,每个项目都引入Android的新功能和新技术,以助您达到最圆满的学习效果。书中介绍Android的所有基本功能,并...

    Android高级编程--源代码

    作为使用androidsdk构建这些应用程序的实用指南书籍,《android高级编程》从始至终穿插了一系列示例项目,每个项目都引入android的新功能和新技术,以助您达到最圆满的学习效果。书中介绍android的所有基本功能,并...

    模拟器专用android kernel2.6 (支持netfilter,ko文件加载与卸载)

    首先进入eclipse,点avd manager,新建个模拟器(android1.5~android2.3.3都行) 假设新建模拟器名叫avd22 然后用下列命令(在命令行下输入): $ANDROID_SDK/tools/emulator -avd avd2.1 -kernel ~/android-kernel/...

    Android C++高级编程:使用NDK_Onur Cinar, 于红PDF电子书下载 带书签目录 完整版

    1.3.6 在Linux平台上下载并安装Android SDK 23 1.3.7 在Linux平台上下载并安装Android NDK 24 1.3.8 在Linux平台上下载并安装Eclipse 25 1.4 下载并安装ADT 26 1.4.1 安装Android平台包 29 1.4.2 配置模拟器 30...

    Android高级编程.pdf

    1.5 Android SDK功能 1.5.1 对包括摄像头、GPS和加速计在内的硬件的访问 1.5.2 自带的Google地图、地理编码和基于位置的服务 1.5.3 后台服务 1.5.4 SQLite数据存储和检索数据库 1.5.5 共享数据和应用程序间通信 ...

    工作报告之基于android开题报告.docx

    操作系统:android手机基于linux操作系统 支持环境:android1.5-4.0.1版本 开发环境:eclipse 8.5版本 实现功能:(1)文件浏览:实现对用户存储空间内歌曲的浏览和查询。(2)播放器管理:对歌曲进行添加、删除、...

    Android 3D游戏开发技术宝典-OpenGL ES 2.0 (吴亚峰) 源代码

    1.3.1 sdk的安装及环境配置 5 1.3.2 eclipse集成开发环境的搭建 7 1.3.3 创建并启动模拟器 9 1.4 hello android应用程序的开发 11 1.4.1 第一个android应用程序 12 1.4.2 android应用程序的项目结构...

    ap6181调通SSH和SCP+ap6212a0_r16_tinav2.1.7z

    RX bytes:1572 (1.5 KiB) TX bytes:1572 (1.5 KiB) wlan0 Link encap:Ethernet HWaddr 94:A1:A2:C4:E3:12 UP BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX ...

Global site tag (gtag.js) - Google Analytics