Chinaunix首页 | 论坛 | 博客
  • 博客访问: 278043
  • 博文数量: 95
  • 博客积分: 2047
  • 博客等级: 大尉
  • 技术积分: 1022
  • 用 户 组: 普通用户
  • 注册时间: 2011-03-14 16:18
文章分类

全部博文(95)

文章存档

2013年(1)

2011年(94)

我的朋友

分类: 嵌入式

2011-08-14 19:51:27

(1)在android跟目录下执行(为何每次都要执行?)
. build/envsetup.sh

(2)建立自己的board
copy build/target/board/generic to build/target/board/idea6410

修改build/target/product/AndroidProduct.mk,添加
    $(LOCAL_DIR)/idea6410.mk \

copy build/target/product/generic.mk to build/target/product/idea6410.mk

修改
# Overrides
PRODUCT_BRAND := idea6410
PRODUCT_DEVICE := idea6410
PRODUCT_NAME := idea6410

(3)tapas
[kyon@SEP4020 android2.0]$ tapas
Build for the simulator or the device?
     1. Device
     2. Simulator
Which would you like? [1] 

Build type choices are:
     1. release
     2. debug
Which would you like? [1] 1

Which product would you like? [generic] idea6410

Variant choices are:
     1. user
     2. userdebug
     3. eng
Which would you like? [eng] 

============================================
PLATFORM_VERSION_CODENAME=Eclair
PLATFORM_VERSION=Eclair
TARGET_PRODUCT=idea6410
TARGET_BUILD_VARIANT=eng
TARGET_SIMULATOR=false
TARGET_BUILD_TYPE=release
TARGET_ARCH=arm
HOST_ARCH=x86
HOST_OS=linux
HOST_BUILD_TYPE=release
BUILD_ID=ECLAIR
============================================

[kyon@SEP4020 android2.0]$ 

以上只是基于generic简单的复制,需要更详细的定制开发板设备

附录:
1)build/target/product/idea6410.mk内容
# This is a generic product that isn't specialized for a specific device.
# It includes the base Android platform. If you need Google-specific features,
# you should derive from generic_with_google.mk

PRODUCT_PACKAGES := \
    AccountAndSyncSettings \
    AlarmClock \
    AlarmProvider \
    Bluetooth \
    Calculator \
    Calendar \
    Camera \
    CertInstaller \
    DrmProvider \
    Email \
    Gallery \
    LatinIME \
    Mms \
    Music \
    Settings \
    Sync \
    Updater \
    CalendarProvider \
    SyncProvider

$(call inherit-product, $(SRC_TARGET_DIR)/product/core.mk)

# Overrides
PRODUCT_BRAND := idea6410
PRODUCT_DEVICE := idea6410
PRODUCT_NAME := idea6410

产品名称及包含的应用程序

2)build/target/board/idea6410/BoardConfig.mk
# config.mk
#
# Product-specific compile-time definitions.
#

# The generic product target doesn't have any hardware-specific pieces.
TARGET_NO_BOOTLOADER := true
TARGET_NO_KERNEL := true
TARGET_CPU_ABI := armeabi
HAVE_HTC_AUDIO_DRIVER := true
BOARD_USES_GENERIC_AUDIO := true

不编译bootloader及内核
使用arm eabi编译器
使用HTC和通用音频(没有使用ALSA)

如果需要添加HAL层驱动,需要修改此文件

3)build/target/board/idea6410/AndroidBoard.mk
LOCAL_PATH := $(call my-dir)

file := $(TARGET_OUT_KEYLAYOUT)/tuttle2.kl
ALL_PREBUILT += $(file)
$(file) : $(LOCAL_PATH)/tuttle2.kl | $(ACP)
$(transform-prebuilt-to-target)

include $(CLEAR_VARS)
LOCAL_SRC_FILES := tuttle2.kcm
include $(BUILD_KEY_CHAR_MAP)

目前看来加入了一些键盘映射文件
阅读(578) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~