bc9/bc9-oe-sdk setup
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
単語検索
|
最終更新
]
開始行:
[[bc9/bc9-oe-sdk]]
bc9-oe-sdk setup
-version
--bc9-oe-sdk--release20090801
#contents
* Vmware [#p80852e6]
bc9-oe-sdk での Vmware イメージの設定を記述します。~
-Version:6.5互換
-Disk 容量:仮想ディスク20G(2Gごとに分割の設定)
-CPU数:cpu 1
-memory:512M
--VMイメージの memory、cpu を増やしたい場合は、bc9-androi...
-Network:bridge network
-OS
--Ubuntu 8.04.3 LTS(8.04.2LTSでインストール後 update)
--アプリケーションは以下の変更以外はインストール後の defa...
--gnome-games ほか game 関連は削除します。(容量削減のた...
---sudo apt-get remove gnome-cards-data gnome-games gnome...
--ssh、ntp、vim、lv、nautilus-open-terminal、adobe falsh ...
--vmware-tools インストール済みです。
--default 解像度 1280x768に設定しています。
--network は dhcp でアドレスを取得する設定です。
--作業用に作成してある user は beat、beat の password は ...
* gumstix-oe [#t72a21c2]
-/bin/sh のシンボリックリンクが dash になっているので bas...
$ sudo dpkg-reconfigure dash
-必須アプリケーション・ツール類をインストールします。~
$ sudo apt-get update
$ sudo apt-get install build-essential help2man diffstat...
$ sudo apt-get install python-dev python-pysqlite2 pytho...
** gumstix-oeの取得 [#p108bd7a]
-gumstix-oe を svn checkout~
以下の手順で gumstix-oe を取得します。~
$ mkdir ~/gumstix
$ cd ~/gumstix
$ svn co https://gumstix.svn.sourceforge.net/svnroot/gum...
** 環境設定 [#h3cb48dd]
-ソースコードキャッシュ保存場所を設定~
以下のコマンドで bitbake 実行時にダウンロードされるソース...
$ sudo groupadd oe
$ sudo usermod -a -G oe beat
$ sudo mkdir /usr/share/sources
$ sudo chgrp oe /usr/share/sources
$ sudo chmod 0775 /usr/share/sources
$ sudo chmod ug+s /usr/share/sources
管理用のグループ設定をしているので、これが終わったら一度 ...
-環境設定~
以下のコマンドで bitbake 実行時に必要な環境変数を設定しま...
$ cat ~/gumstix/gumstix-oe/extras/profile >> ~/.bashrc
一度これを実行したら .bashrc に書き込まれるので、以降いつ...
** ソースファイル調整 [#r6d74ae9]
build 内容の調整をします。~
-iwmmxt に最適化し、FEED_ARCH も iwmmxt に変更します。~
beat@bc9-oe-sdk:~/gumstix/gumstix-oe$ svn diff com.gumst...
Index: com.gumstix.collection/conf/machine/include/tune-...
========================================================...
--- com.gumstix.collection/conf/machine/include/tune-iwm...
+++ com.gumstix.collection/conf/machine/include/tune-iwm...
@@ -1,6 +1,9 @@
# Configurations for the Intel PXA27x Appications Proce...
# Please use tune-xscale for PXA255/PXA26x based proces...
-TARGET_CC_ARCH = "-march=iwmmxt -mcpu=iwmmxt -mtune=iwm...
+FEED_ARCH = "iwmmxt"
+
+TARGET_CC_ARCH = "-march=iwmmxt -mtune=iwmmxt"
+TARGET_CC_KERNEL_ARCH = "-march=iwmmxt -mtune=iwmmxt"
PACKAGE_ARCH = "iwmmxt"
PACKAGE_EXTRA_ARCHS += "iwmmxt"
-kernel size を拡大(後ですぐ 2.6.29 kernel に更新するた...
beat@bc9-oe-sdk:~/gumstix/gumstix-oe$ svn diff com.gumst...
Index: com.gumstix.collection/conf/machine/include/gumst...
========================================================...
--- com.gumstix.collection/conf/machine/include/gumstix....
+++ com.gumstix.collection/conf/machine/include/gumstix....
@@ -10,7 +10,7 @@
PREFERRED_PROVIDER_virtual/kernel = "gumstix-kernel"
KERNEL_IMAGETYPE = "uImage"
RDEPENDS_kernel-base = ""
-KERNEL_IMAGE_MAXSIZE = "1048577"
+KERNEL_IMAGE_MAXSIZE = "2097154"
UBOOT_ENTRYPOINT = "a0008000"
-microSD 起動のため mmcboot に変更し、bc9 では使用しない ...
beat@bc9-oe-sdk:~/gumstix/gumstix-oe$ svn diff com.gumst...
Index: com.gumstix.collection/conf/machine/gumstix-custo...
========================================================...
--- com.gumstix.collection/conf/machine/gumstix-custom-v...
+++ com.gumstix.collection/conf/machine/gumstix-custom-v...
@@ -5,12 +5,12 @@
MACHINE_FEATURES += "verdex"
MACHINE_FEATURES += "iwmmxt"
require conf/machine/include/gumstix.inc
-require conf/machine/include/tune-xscale.inc
+require conf/machine/include/tune-iwmmxt.inc
#
# Your flash size = Total flash (in MB) - 1 (for linux ...
-ROOT_FLASH_SIZE = "15"
-#ROOT_FLASH_SIZE = "31"
+#ROOT_FLASH_SIZE = "15"
+ROOT_FLASH_SIZE = "30"
#
# Enable use of virtual terminal for LCD on tty1 if USE...
@@ -28,7 +28,7 @@
#MACHINE_FEATURES += "spi"
MACHINE_FEATURES += "serial"
-MACHINE_FEATURES += "bluetooth"
+#MACHINE_FEATURES += "bluetooth"
MACHINE_FEATURES += "sound"
# if you enable robostix you will need to disable both ...
@@ -51,7 +51,7 @@
MACHINE_FEATURES += "fat"
# enable one of the following if you want to target bui...
-#MACHINE_FEATURES += "mmcroot"
+MACHINE_FEATURES += "mmcroot"
#MACHINE_FEATURES += "cfroot"
#
** build [#o2d59418]
2010/06/11 追記~
注:bitbake gumstix-basic-image 実行時に zlib-native-1.2....
zlib-1.2.3 を取得する場合 bb ファイルを以下のように編集し...
#zlib の最新版は2010年6月10日時点で zlib-1.2.5 になって...
$ vi gumstix/gumstix-oe/org.openembedded.snapshot/packag...
LICENSE = "zlib"
PR="r2"
#SRC_URI = "http://www.zlib.net/zlib-1.2.3.tar.bz2 \
SRC_URI = "http://sourceforge.net/projects/libpng/files/...
file://visibility.patch;patch=1 \
file://autotools.patch;patch=1 "
S = "${WORKDIR}/zlib-${PV}"
以下のコマンドで microSD 起動用の kernel と userland を b...
$ bitbake gumstix-basic-image
build が終了すると以下のファイルが生成されます。~
beat@bc9-oe-sdk:~/gumstix/gumstix-oe/tmp/deploy/glibc/im...
合計 18152
-rw-r--r-- 1 beat beat 8576116 2009-07-24 18:57 Angstrom...
-rw-rw-r-- 1 beat beat 7081015 2009-07-24 18:57 Angstrom...
lrwxrwxrwx 1 beat beat 94 2009-07-24 18:57 gumstix-...
lrwxrwxrwx 1 beat beat 95 2009-07-24 18:57 gumstix-...
-rw-rw-r-- 1 beat beat 1881391 2009-07-24 18:24 modules-...
-rw-r--r-- 1 beat beat 998520 2009-07-24 18:24 uImage-2...
ここで生成される kernel は 2.6.21 ですが、起動用 microSD ...
以下の手順で生成される 2.6.29 に入れ替えてしまいますので...
Angstrom-gumstix-basic-image-glibc-ipk-2007.9-test-20090...
だけです。
** 2.6.29 kernel & modules [#o0348413]
bc9-android-sdk で取得した linux-android-2.6.29 kernel を...
patch-kernel-2.6.29.4-bc9-r3 を当て、bc9_android_defconfi...
patch 後 linux-android-2.6.29 を linux-android-2.6.29-bc9...
以下の内容で kernel だけを cross compile するための環境設...
#!/bin/sh
export PATH=/home/beat/gumstix/gumstix-oe/tmp/cross/bin:...
export ARCH=arm
export CROSS_COMPILE=arm-angstrom-linux-gnueabi-
このファイルを source し linux-android-2.6.29-bc9-r3 で m...
bc9 用の microSD 起動用ファイルを得るにはさらに以下の作業...
以下の内容で make-bc9-kernel.sh を作成し linux-android-2....
#!/bin/sh
export LANG=C
GUMSTIX_HOME="/home/beat/gumstix/gumstix-oe"
SYSMAP="./System.map"
TOOL_PREFIX="${GUMSTIX_HOME}/tmp/cross/bin/arm-angstrom-...
DEPMOD="${TOOL_PREFIX}depmod-2.6"
OBJCOPY=${TOOL_PREFIX}objcopy
MKIMG=${GUMSTIX_HOME}/tmp/staging/i686-linux/bin/uboot-m...
UBOOT_ENTRYPOINT="a0008000"
MOD_WORKDIR="./mod_work"
make ARCH=arm CROSS_COMPILE=${TOOL_PREFIX} prepare
KERNREL=`make kernelrelease`
KERNVER=`make kernelversion`
KERNIMG="uImage-${KERNREL}.bin"
MODTGZ="modules-${KERNREL}.tgz"
KERNIMGLN="uImage-${KERNVER}-bc9.bin"
MODTGZLN="modules-${KERNVER}-bc9.tgz"
echo "### Cleanup"
rm -rf ${MOD_WORKDIR}
rm -f ${KERNIMG} ${MODTGZ} ${KERNIMGLN} ${MODTGZLN}
echo "### Build kernel"
make ARCH=arm CROSS_COMPILE=${TOOL_PREFIX}
if [ $? != 0 ]; then
echo "*** Failed to build kernel"
exit 1
fi
echo "### Make kernel image"
${OBJCOPY} -O binary -R .note -R .comment \
-S ./arch/arm/boot/compressed/vmlinux linux.bin
if [ $? != 0 ]; then
echo "*** Failed to make kernel image"
exit 1
fi
${MKIMG} -A arm -O linux -T kernel -C none -a ${UBOOT_EN...
-e ${UBOOT_ENTRYPOINT} -n "oe/verdex/arm" -d linux.bin $...
if [ $? != 0 ]; then
echo "*** Failed to make kernel image"
exit 1
fi
ln -s ${KERNIMG} ${KERNIMGLN}
echo "### Install modules"
make ARCH=arm DEPMOD=echo INSTALL_MOD_PATH=${MOD_WORKDIR...
if [ $? != 0 ]; then
echo "*** Failed to modules_install"
exit 1
fi
${DEPMOD} -A -b ${MOD_WORKDIR} -F ${SYSMAP} ${KERNREL}
if [ $? != 0 ]; then
echo "*** Failed to depmod modules"
exit 1
fi
echo "### Make modules tar ball"
tar czvf ${MODTGZ} -C ${MOD_WORKDIR} lib
if [ $? != 0 ]; then
echo "*** Failed to make modules tarball"
exit 1
fi
ln -s ${MODTGZ} ${MODTGZLN}
echo "### Finished"
ls -l ${KERNIMG} ${MODTGZ}
make が終了すると、vmlinux など標準の make を実行したとき...
bc9 用に必要な以下のファイルが生成されます。
-rw-rw-r-- 1 beat beat 1.4M 2009-07-28 20:39 modules-2....
lrwxrwxrwx 1 beat beat 25 2009-07-28 20:39 modules-2....
-rw-rw-r-- 1 beat beat 1.5M 2009-07-28 20:38 uImage-2.6...
lrwxrwxrwx 1 beat beat 24 2009-07-28 20:38 uImage-2.6...
終了行:
[[bc9/bc9-oe-sdk]]
bc9-oe-sdk setup
-version
--bc9-oe-sdk--release20090801
#contents
* Vmware [#p80852e6]
bc9-oe-sdk での Vmware イメージの設定を記述します。~
-Version:6.5互換
-Disk 容量:仮想ディスク20G(2Gごとに分割の設定)
-CPU数:cpu 1
-memory:512M
--VMイメージの memory、cpu を増やしたい場合は、bc9-androi...
-Network:bridge network
-OS
--Ubuntu 8.04.3 LTS(8.04.2LTSでインストール後 update)
--アプリケーションは以下の変更以外はインストール後の defa...
--gnome-games ほか game 関連は削除します。(容量削減のた...
---sudo apt-get remove gnome-cards-data gnome-games gnome...
--ssh、ntp、vim、lv、nautilus-open-terminal、adobe falsh ...
--vmware-tools インストール済みです。
--default 解像度 1280x768に設定しています。
--network は dhcp でアドレスを取得する設定です。
--作業用に作成してある user は beat、beat の password は ...
* gumstix-oe [#t72a21c2]
-/bin/sh のシンボリックリンクが dash になっているので bas...
$ sudo dpkg-reconfigure dash
-必須アプリケーション・ツール類をインストールします。~
$ sudo apt-get update
$ sudo apt-get install build-essential help2man diffstat...
$ sudo apt-get install python-dev python-pysqlite2 pytho...
** gumstix-oeの取得 [#p108bd7a]
-gumstix-oe を svn checkout~
以下の手順で gumstix-oe を取得します。~
$ mkdir ~/gumstix
$ cd ~/gumstix
$ svn co https://gumstix.svn.sourceforge.net/svnroot/gum...
** 環境設定 [#h3cb48dd]
-ソースコードキャッシュ保存場所を設定~
以下のコマンドで bitbake 実行時にダウンロードされるソース...
$ sudo groupadd oe
$ sudo usermod -a -G oe beat
$ sudo mkdir /usr/share/sources
$ sudo chgrp oe /usr/share/sources
$ sudo chmod 0775 /usr/share/sources
$ sudo chmod ug+s /usr/share/sources
管理用のグループ設定をしているので、これが終わったら一度 ...
-環境設定~
以下のコマンドで bitbake 実行時に必要な環境変数を設定しま...
$ cat ~/gumstix/gumstix-oe/extras/profile >> ~/.bashrc
一度これを実行したら .bashrc に書き込まれるので、以降いつ...
** ソースファイル調整 [#r6d74ae9]
build 内容の調整をします。~
-iwmmxt に最適化し、FEED_ARCH も iwmmxt に変更します。~
beat@bc9-oe-sdk:~/gumstix/gumstix-oe$ svn diff com.gumst...
Index: com.gumstix.collection/conf/machine/include/tune-...
========================================================...
--- com.gumstix.collection/conf/machine/include/tune-iwm...
+++ com.gumstix.collection/conf/machine/include/tune-iwm...
@@ -1,6 +1,9 @@
# Configurations for the Intel PXA27x Appications Proce...
# Please use tune-xscale for PXA255/PXA26x based proces...
-TARGET_CC_ARCH = "-march=iwmmxt -mcpu=iwmmxt -mtune=iwm...
+FEED_ARCH = "iwmmxt"
+
+TARGET_CC_ARCH = "-march=iwmmxt -mtune=iwmmxt"
+TARGET_CC_KERNEL_ARCH = "-march=iwmmxt -mtune=iwmmxt"
PACKAGE_ARCH = "iwmmxt"
PACKAGE_EXTRA_ARCHS += "iwmmxt"
-kernel size を拡大(後ですぐ 2.6.29 kernel に更新するた...
beat@bc9-oe-sdk:~/gumstix/gumstix-oe$ svn diff com.gumst...
Index: com.gumstix.collection/conf/machine/include/gumst...
========================================================...
--- com.gumstix.collection/conf/machine/include/gumstix....
+++ com.gumstix.collection/conf/machine/include/gumstix....
@@ -10,7 +10,7 @@
PREFERRED_PROVIDER_virtual/kernel = "gumstix-kernel"
KERNEL_IMAGETYPE = "uImage"
RDEPENDS_kernel-base = ""
-KERNEL_IMAGE_MAXSIZE = "1048577"
+KERNEL_IMAGE_MAXSIZE = "2097154"
UBOOT_ENTRYPOINT = "a0008000"
-microSD 起動のため mmcboot に変更し、bc9 では使用しない ...
beat@bc9-oe-sdk:~/gumstix/gumstix-oe$ svn diff com.gumst...
Index: com.gumstix.collection/conf/machine/gumstix-custo...
========================================================...
--- com.gumstix.collection/conf/machine/gumstix-custom-v...
+++ com.gumstix.collection/conf/machine/gumstix-custom-v...
@@ -5,12 +5,12 @@
MACHINE_FEATURES += "verdex"
MACHINE_FEATURES += "iwmmxt"
require conf/machine/include/gumstix.inc
-require conf/machine/include/tune-xscale.inc
+require conf/machine/include/tune-iwmmxt.inc
#
# Your flash size = Total flash (in MB) - 1 (for linux ...
-ROOT_FLASH_SIZE = "15"
-#ROOT_FLASH_SIZE = "31"
+#ROOT_FLASH_SIZE = "15"
+ROOT_FLASH_SIZE = "30"
#
# Enable use of virtual terminal for LCD on tty1 if USE...
@@ -28,7 +28,7 @@
#MACHINE_FEATURES += "spi"
MACHINE_FEATURES += "serial"
-MACHINE_FEATURES += "bluetooth"
+#MACHINE_FEATURES += "bluetooth"
MACHINE_FEATURES += "sound"
# if you enable robostix you will need to disable both ...
@@ -51,7 +51,7 @@
MACHINE_FEATURES += "fat"
# enable one of the following if you want to target bui...
-#MACHINE_FEATURES += "mmcroot"
+MACHINE_FEATURES += "mmcroot"
#MACHINE_FEATURES += "cfroot"
#
** build [#o2d59418]
2010/06/11 追記~
注:bitbake gumstix-basic-image 実行時に zlib-native-1.2....
zlib-1.2.3 を取得する場合 bb ファイルを以下のように編集し...
#zlib の最新版は2010年6月10日時点で zlib-1.2.5 になって...
$ vi gumstix/gumstix-oe/org.openembedded.snapshot/packag...
LICENSE = "zlib"
PR="r2"
#SRC_URI = "http://www.zlib.net/zlib-1.2.3.tar.bz2 \
SRC_URI = "http://sourceforge.net/projects/libpng/files/...
file://visibility.patch;patch=1 \
file://autotools.patch;patch=1 "
S = "${WORKDIR}/zlib-${PV}"
以下のコマンドで microSD 起動用の kernel と userland を b...
$ bitbake gumstix-basic-image
build が終了すると以下のファイルが生成されます。~
beat@bc9-oe-sdk:~/gumstix/gumstix-oe/tmp/deploy/glibc/im...
合計 18152
-rw-r--r-- 1 beat beat 8576116 2009-07-24 18:57 Angstrom...
-rw-rw-r-- 1 beat beat 7081015 2009-07-24 18:57 Angstrom...
lrwxrwxrwx 1 beat beat 94 2009-07-24 18:57 gumstix-...
lrwxrwxrwx 1 beat beat 95 2009-07-24 18:57 gumstix-...
-rw-rw-r-- 1 beat beat 1881391 2009-07-24 18:24 modules-...
-rw-r--r-- 1 beat beat 998520 2009-07-24 18:24 uImage-2...
ここで生成される kernel は 2.6.21 ですが、起動用 microSD ...
以下の手順で生成される 2.6.29 に入れ替えてしまいますので...
Angstrom-gumstix-basic-image-glibc-ipk-2007.9-test-20090...
だけです。
** 2.6.29 kernel & modules [#o0348413]
bc9-android-sdk で取得した linux-android-2.6.29 kernel を...
patch-kernel-2.6.29.4-bc9-r3 を当て、bc9_android_defconfi...
patch 後 linux-android-2.6.29 を linux-android-2.6.29-bc9...
以下の内容で kernel だけを cross compile するための環境設...
#!/bin/sh
export PATH=/home/beat/gumstix/gumstix-oe/tmp/cross/bin:...
export ARCH=arm
export CROSS_COMPILE=arm-angstrom-linux-gnueabi-
このファイルを source し linux-android-2.6.29-bc9-r3 で m...
bc9 用の microSD 起動用ファイルを得るにはさらに以下の作業...
以下の内容で make-bc9-kernel.sh を作成し linux-android-2....
#!/bin/sh
export LANG=C
GUMSTIX_HOME="/home/beat/gumstix/gumstix-oe"
SYSMAP="./System.map"
TOOL_PREFIX="${GUMSTIX_HOME}/tmp/cross/bin/arm-angstrom-...
DEPMOD="${TOOL_PREFIX}depmod-2.6"
OBJCOPY=${TOOL_PREFIX}objcopy
MKIMG=${GUMSTIX_HOME}/tmp/staging/i686-linux/bin/uboot-m...
UBOOT_ENTRYPOINT="a0008000"
MOD_WORKDIR="./mod_work"
make ARCH=arm CROSS_COMPILE=${TOOL_PREFIX} prepare
KERNREL=`make kernelrelease`
KERNVER=`make kernelversion`
KERNIMG="uImage-${KERNREL}.bin"
MODTGZ="modules-${KERNREL}.tgz"
KERNIMGLN="uImage-${KERNVER}-bc9.bin"
MODTGZLN="modules-${KERNVER}-bc9.tgz"
echo "### Cleanup"
rm -rf ${MOD_WORKDIR}
rm -f ${KERNIMG} ${MODTGZ} ${KERNIMGLN} ${MODTGZLN}
echo "### Build kernel"
make ARCH=arm CROSS_COMPILE=${TOOL_PREFIX}
if [ $? != 0 ]; then
echo "*** Failed to build kernel"
exit 1
fi
echo "### Make kernel image"
${OBJCOPY} -O binary -R .note -R .comment \
-S ./arch/arm/boot/compressed/vmlinux linux.bin
if [ $? != 0 ]; then
echo "*** Failed to make kernel image"
exit 1
fi
${MKIMG} -A arm -O linux -T kernel -C none -a ${UBOOT_EN...
-e ${UBOOT_ENTRYPOINT} -n "oe/verdex/arm" -d linux.bin $...
if [ $? != 0 ]; then
echo "*** Failed to make kernel image"
exit 1
fi
ln -s ${KERNIMG} ${KERNIMGLN}
echo "### Install modules"
make ARCH=arm DEPMOD=echo INSTALL_MOD_PATH=${MOD_WORKDIR...
if [ $? != 0 ]; then
echo "*** Failed to modules_install"
exit 1
fi
${DEPMOD} -A -b ${MOD_WORKDIR} -F ${SYSMAP} ${KERNREL}
if [ $? != 0 ]; then
echo "*** Failed to depmod modules"
exit 1
fi
echo "### Make modules tar ball"
tar czvf ${MODTGZ} -C ${MOD_WORKDIR} lib
if [ $? != 0 ]; then
echo "*** Failed to make modules tarball"
exit 1
fi
ln -s ${MODTGZ} ${MODTGZLN}
echo "### Finished"
ls -l ${KERNIMG} ${MODTGZ}
make が終了すると、vmlinux など標準の make を実行したとき...
bc9 用に必要な以下のファイルが生成されます。
-rw-rw-r-- 1 beat beat 1.4M 2009-07-28 20:39 modules-2....
lrwxrwxrwx 1 beat beat 25 2009-07-28 20:39 modules-2....
-rw-rw-r-- 1 beat beat 1.5M 2009-07-28 20:38 uImage-2.6...
lrwxrwxrwx 1 beat beat 24 2009-07-28 20:38 uImage-2.6...
ページ名:
BC::labsへの質問は、bc9-dev @ googlegroups.com までお願い致します。