2010年8月27日 星期五

Android 心得感想

還記的一年前Android大張旗鼓出現,偶當時也具有高度的興趣,因為base on linux而且open source.
而且google也在Android上導入open source所缺乏的重要軟體,例如Web Browser, 穩定的Java VM等.
這一年來偶接觸過兩個Android platform分別是TI OMAP 3530 & Samsung S3C6410, 軟體的部份有修改一些driver以符合Android的要求,簡單的JNI及Android application.偶嘗試以技術的角度將這些與Android的經歷紀錄下來.

1.Linux kernel

Linux kernel必須加上一些Android fix & driver才能跑Android.
例如,比較奇特的像是pmem driver,用來保留memory給Android使用.
坦白說為了特定application保留memory這件事偶個人覺得非常不妥,
一般都是保留給其他hardware使用像是DSP而且也不需要額外的driver來處理,
只要在kernel param設定mem=XXX就能保留剩下的memory,甚至是保留特定memory region也可透過類似方式達到.是效率或著是security issue非得用如此的作法不可嗎 ?

這只是冰山一角,還有其他特異的程式碼在系統中運作著.
事實上Linux Kernel的維護者已經在年初宣佈移除所有Android相關的程式碼.

2.Where is linux ?

第一次順利booting kernel啟動Android進入console之後偶發現一切都很陌生.
是的,的確有個shell,很難用的shell... OK,Android自己搞的shell.

每個指令的功能都陽春到不行,backspace & tab key都不能用.進入/etc目錄之後更是大吃一驚,在UNIX系統沿用多年的許多系統檔案都不見了,全部被Android一手包辦.

在Android 中init.rc這個檔案負責系統初始化的設定,如mount file system, init network 及週邊初始化.其中的script語法並非shell script而是Android自訂的key word所組成.

嗯,這真的不是Linux更不是UNIX like system.
Android是以linux kernel為核心基礎也僅只於此了.

3.Porting Android

Android 具有跨平台在不同CPU上工作的能力,但porting的工作則是各憑本事.
目前Embedded ARM CPU往往有許多特殊硬體的功能,例如2D, 3D graphic engine, video coder及camera interface等.

這些功能在linux kernel driver端常常就有許多新增的ioctl及操作流程,porting的困難是需要對driver及Android都有相當程度的了解才能進行的下去.

在開發環境上以往熟悉的Makefile已經被Android.mk取代,完全不同於傳統Embedded System.

Android對自身系統設計的文件並不多,但光從source code的量來看要能有詳細的文件確實是很難.
所以想要porting Android到產品等級絕對不是幾個有經驗的工程師就能作到其中的know how真的非常多.

4.Java VM

Android提供一個Java VM Engine - dalvik,我相當喜歡這樣的設計.dalvik提供一個可以達到同一個application java binary在不同平台執行,而且其效能不見得比native binary來的差.不過這不是絕對的,例如Android允許使用JNI的方式撰寫直接控制硬體或是連結close source binary.許多商業軟體就會透過這種方式達到保護自身利益.java binary跨平台的特性也因此弱化了.但不可否認的是使用Java 單一語言來開發application的確是很大的好處,尤其是Graphic Interface.如果是c/c++因為語言開放特性的關係就算有完整library也不是一件容易的事(例如QT, gtk).


2010年8月18日 星期三

Maemo 5 DBus 初探

DBus 在Maemo 5系統中是很重要的 IPC 功能,透過DBus可以控制許多硬體如LED, Keypad,甚至是撥電話及發簡訊.現在我想要在程式執行時LCD panel不要進入power saving而關閉也需要透過DBus.

1.Reference

http://wiki.maemo.org/Documentation/Maemo_5_Developer_Guide/DBus/DBus_Basics

http://maemo.org/api_refs/5.0/5.0-final/mce-dev/dbus-names_8h.html#c9f233f336f9be78f223a31866455b80

http://www.mail-archive.com/maemo-developers@maemo.org/msg01889.html


2.以下的程式碼片段就是我想要的囉

    DBusConnection *conn;
DBusMessage *msg = NULL;
DBusError dbus_error;
dbus_bool_t dresult;

#define MCE_SERVICE "com.nokia.mce"
#define MCE_REQUEST_PATH "/com/nokia/mce/request"
#define MCE_REQUEST_IF "com.nokia.mce.request"
#define MCE_PREVENT_BLANK_REQ "req_display_blanking_pause"

dbus_error_init(&dbus_error);

conn = dbus_bus_get (DBUS_BUS_SYSTEM, &dbus_error);

msg = dbus_message_new_method_call(MCE_SERVICE,
MCE_REQUEST_PATH,
MCE_REQUEST_IF,
MCE_PREVENT_BLANK_REQ);
if (msg == NULL)
return;

dresult = dbus_connection_send (conn, msg, NULL);

if (!dresult)
{
dbus_message_unref(msg);
return;
}

dbus_connection_flush(conn);
dbus_message_unref(msg);


2010年8月9日 星期一

Maemo 5 debian packaging

初次嘗試Maemo 5 hello world programing之後,將binary複製到target上就可以執行.
但這樣並不是正規的散布方式,Maemo 5支援Debian dpkg的方式包裝binary,包含icon, desktop設定等...
網路上搜尋Maemo 5 dpkg相關的資料並不多,流程也有些複雜,因此作個紀錄供往後參考用.

以下將延續之前的example_hildonprogram

1.要使用dpkg packaging需要配合autotools (據說也可以不要)
2.建立目錄及環境,之後複製example_hildonprogram.c

[sbox-FREMANTLE_ARMEL: ~/] > mkdir example_hildonprogram
[sbox-FREMANTLE_ARMEL: ~/] > cd example_hildonprogram
[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > mkdir src
[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > mkdir data
[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > mkdir data/maemo

複製example_hildonprogram.c 到 example_hildonprogram/src

3.建立autotools所需檔案

File configure.ac

AC_INIT([example_hildonprogram], [0.1])
AM_INIT_AUTOMAKE([foreign])
AC_PROG_CC
PKG_CHECK_MODULES(GTK2,
          [gtk+-2.0]
          [AC_SUBST(GTK2_CFLAGS)
          AC_SUBST(GTK2_LIBS)])

PKG_CHECK_MODULES([HILDON], [hildon-1 >= 2.2])
AC_CONFIG_FILES([Makefile src/Makefile])
AC_OUTPUT

File Makefile.am

SUBDIRS = src
EXTRA_DIST = data/icons/example_hildonprogram.png \
        data/maemo/example_hildonprogram.desktop \
        data/maemo/com.nokia.example_hildonprogram.service

File src/Makefile.am

bin_PROGRAMS = example_hildonprogram

example_hildonprogram_SOURCES = example_hildonprogram.c

example_hildonprogram_CFLAGS = $(GTK2_CFLAGS) \
                  $(HILDON_CFLAGS)

example_hildonprogram_LDADD = $(GTK2_LIBS) \
                 $(HILDON_LIBS)

4.建立Maemo 5所需檔案

File data/maemo/example_hildonprogram.desktop

[Desktop Entry]
Encoding=UTF-8
Version=0.1
Name=example_hildonprogram
Type=Application
Exec=/usr/bin/example_hildonprogram
Icon=example_hildonprogram

File data/maemo/com.nokia.example_hildonprogram.service

[D-BUS Service]
Name=nokia.com.example_hildonprogram
Exec=/usr/bin/example_hildonprogram

5.Run autoreconf to create configure

[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > autoreconf --force --install -v
autoreconf2.50: Entering directory `.'
autoreconf2.50: configure.ac: not using Gettext
autoreconf2.50: running: aclocal --force
autoreconf2.50: configure.ac: tracing
autoreconf2.50: configure.ac: not using Libtool
autoreconf2.50: running: /scratchbox/tools/autotools/autoconf2.61/bin/autoconf --force
autoreconf2.50: configure.ac: not using Autoheader
autoreconf2.50: running: automake --add-missing --copy --force-missing
src/Makefile.am: installing `./compile'
autoreconf2.50: Leaving directory `.'

6.configure

[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > ./configure
checking for a BSD-compatible install... /scratchbox/tools/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for pkg-config... /scratchbox/tools/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for GTK2... yes
checking for HILDON... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: executing depfiles commands

7.make

[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > make
Making all in src
make[1]: Entering directory `/home/gigijoe/example_hildonprogram/src'
if gcc -DPACKAGE_NAME=\"example_hildonprogram\" -DPACKAGE_TARNAME=\"example_hildonprogram\" -DPACKAGE_VERSION=\"0.1\" -DPACKAGE_STRING=\"example_hildonprogram\ 0.1\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"example_hildonprogram\" -DVERSION=\"0.1\" -I. -I.    -DMAEMO_CHANGES -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12   -DMAEMO_CHANGES -DMAEMO_GTK -I/usr/include/hildon-1 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12   -g -O2 -MT example_hildonprogram-example_hildonprogram.o -MD -MP -MF ".deps/example_hildonprogram-example_hildonprogram.Tpo" -c -o example_hildonprogram-example_hildonprogram.o `test -f 'example_hildonprogram.c' || echo './'`example_hildonprogram.c; \
    then mv -f ".deps/example_hildonprogram-example_hildonprogram.Tpo" ".deps/example_hildonprogram-example_hildonprogram.Po"; else rm -f ".deps/example_hildonprogram-example_hildonprogram.Tpo"; exit 1; fi
gcc  -g -O2   -o example_hildonprogram  example_hildonprogram-example_hildonprogram.o -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0   -lhildon-1 -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0  
make[1]: Leaving directory `/home/gigijoe/example_hildonprogram/src'
make[1]: Entering directory `/home/gigijoe/example_hildonprogram'
make[1]: Nothing to be done for `all-am'.
make[1]: Leaving directory `/home/gigijoe/example_hildonprogram'

8.make dist, 此時會產生example_hildonprogram-0.1.tar.gz

[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > make dist
{ test ! -d example_hildonprogram-0.1 || { find example_hildonprogram-0.1 -type d ! -perm -200 -exec chmod u+w {} ';' && rm -fr example_hildonprogram-0.1; }; }
mkdir example_hildonprogram-0.1
mkdir -p -- . example_hildonprogram-0.1/data/icons example_hildonprogram-0.1/data/maemo
list='src'; for subdir in $list; do \
      if test "$subdir" = .; then :; else \
        test -d "example_hildonprogram-0.1/$subdir" \
        || mkdir "example_hildonprogram-0.1/$subdir" \
        || exit 1; \
        (cd $subdir && \
          make  \
            top_distdir="../example_hildonprogram-0.1" \
            distdir="../example_hildonprogram-0.1/$subdir" \
            distdir) \
          || exit 1; \
      fi; \
    done
make[1]: Entering directory `/home/gigijoe/example_hildonprogram/src'
make[1]: Leaving directory `/home/gigijoe/example_hildonprogram/src'
find example_hildonprogram-0.1 -type d ! -perm -777 -exec chmod a+rwx {} \; -o \
      ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
      ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
      ! -type d ! -perm -444 -exec /bin/sh /home/gigijoe/example_hildonprogram/install-sh -c -m a+r {} {} \; \
    || chmod -R a+r example_hildonprogram-0.1
/bin/sh /home/gigijoe/example_hildonprogram/missing --run tar chof - example_hildonprogram-0.1 | GZIP=--best gzip -c >example_hildonprogram-0.1.tar.gz
{ test ! -d example_hildonprogram-0.1 || { find example_hildonprogram-0.1 -type d ! -perm -200 -exec chmod u+w {} ';' && rm -fr example_hildonprogram-0.1; }; }

9.解開壓縮檔準備以此作為packaging source,這樣的作法不會影響到原來的source.

[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > tar -zxvf example_hildonprogram-0.1.tar.gz
example_hildonprogram-0.1/
example_hildonprogram-0.1/compile
example_hildonprogram-0.1/configure
example_hildonprogram-0.1/missing
example_hildonprogram-0.1/install-sh
example_hildonprogram-0.1/depcomp
example_hildonprogram-0.1/configure.ac
example_hildonprogram-0.1/aclocal.m4
example_hildonprogram-0.1/Makefile.am
example_hildonprogram-0.1/Makefile.in
example_hildonprogram-0.1/src/
example_hildonprogram-0.1/src/example_hildonprogram.c
example_hildonprogram-0.1/src/Makefile.am
example_hildonprogram-0.1/src/Makefile.in
example_hildonprogram-0.1/data/
example_hildonprogram-0.1/data/icons/
example_hildonprogram-0.1/data/icons/example_hildonprogram.png
example_hildonprogram-0.1/data/maemo/
example_hildonprogram-0.1/data/maemo/com.nokia.example_hildonprogram.service
example_hildonprogram-0.1/data/maemo/example_hildonprogram.desktop



[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > cd example_hildonprogram-0.1
[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram/example_hildonprogram-0.1] > dh_make -e stevegigijoe@yahoo.com.tw --createorig -c GPL

Type of package: single binary, multiple binary, library, kernel module or cdbs?
 [s/m/l/k/b] s

Maintainer name : unknown
Email-Address   : stevegigijoe@yahoo.com.tw
Date            : Mon,  9 Aug 2010 15:47:56 +0800
Package Name    : example.hildonprogram
Version         : 0.1
License         : gpl
Type of Package : Single
Hit to confirm:
Done. Please edit the files in the debian/ subdirectory now. example.hildonprogram
uses a configure script, so you probably don't have to edit the Makefiles.


11.packaging

首先更動一下 debian/control, 這個檔案很重要.

[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram/example.hildonprogram-0.1] > vi debian/control

-Build-Depends: debhelper (>= 5), autotools-dev
+Build-Depends: debhelper (>= 5), autotools-dev, libhildon1 (>= 2.2)
 
OK,go packaging

以下兩者都可以
dpkg-buildpackage -i -rfakeroot -D
dpkg-buildpackage -sa -rfakeroot -kstevegigijoe@yahoo.com.tw


[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram/example.hildonprogram-0.1] > dpkg-buildpackage -sa -rfakeroot -kstevegigijoe@yahoo.com.tw
dpkg-buildpackage: source package is example.hildonprogram
dpkg-buildpackage: source version is 0.1-1
dpkg-buildpackage: source changed by unknown
dpkg-buildpackage: host architecture armel
dpkg-buildpackage: source version without epoch 0.1-1
: Using Scratchbox tools to satisfy builddeps
: Dependency provided by Scratchbox: autotools-dev
 fakeroot debian/rules clean
dh_testdir
dh_testroot
rm -f build-stamp
# Add here commands to clean up after the build process.
/scratchbox/tools/bin/make distclean
make[1]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make[1]: *** No rule to make target `distclean'.  Stop.
make[1]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make: [clean] Error 2 (ignored)
cp -f /usr/share/misc/config.sub config.sub
cp -f /usr/share/misc/config.guess config.guess
dh_clean
 dpkg-source -b example.hildonprogram-0.1
dpkg-source: building example.hildonprogram using existing example.hildonprogram_0.1.orig.tar.gz
dpkg-source: building example.hildonprogram in example.hildonprogram_0.1-1.diff.gz
dpkg-source: building example.hildonprogram in example.hildonprogram_0.1-1.dsc
 debian/rules build
dh_testdir
# Add here commands to configure the package.
./configure --host=arm-linux-gnueabi --build=arm-linux-gnueabi --prefix=/usr --mandir=\${prefix}/share/man --infodir=\${prefix}/share/info CFLAGS="-Wall -g -O2" LDFLAGS="-Wl,-z,defs"
checking for a BSD-compatible install... /scratchbox/tools/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for arm-linux-gnueabi-gcc... arm-linux-gnueabi-gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether arm-linux-gnueabi-gcc accepts -g... yes
checking for arm-linux-gnueabi-gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of arm-linux-gnueabi-gcc... gcc3
checking for arm-linux-gnueabi-pkg-config... no
checking for pkg-config... /scratchbox/tools/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for GTK2... yes
checking for HILDON... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: executing depfiles commands
dh_testdir
# Add here commands to compile the package.
/scratchbox/tools/bin/make
make[1]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
Making all in src
make[2]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/src'
if arm-linux-gnueabi-gcc -DPACKAGE_NAME=\"example_hildonprogram\" -DPACKAGE_TARNAME=\"example_hildonprogram\" -DPACKAGE_VERSION=\"0.1\" -DPACKAGE_STRING=\"example_hildonprogram\ 0.1\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"example_hildonprogram\" -DVERSION=\"0.1\" -I. -I.    -DMAEMO_CHANGES -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12   -DMAEMO_CHANGES -DMAEMO_GTK -I/usr/include/hildon-1 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12   -Wall -g -O2 -MT example_hildonprogram-example_hildonprogram.o -MD -MP -MF ".deps/example_hildonprogram-example_hildonprogram.Tpo" -c -o example_hildonprogram-example_hildonprogram.o `test -f 'example_hildonprogram.c' || echo './'`example_hildonprogram.c; \
    then mv -f ".deps/example_hildonprogram-example_hildonprogram.Tpo" ".deps/example_hildonprogram-example_hildonprogram.Po"; else rm -f ".deps/example_hildonprogram-example_hildonprogram.Tpo"; exit 1; fi
arm-linux-gnueabi-gcc  -Wall -g -O2  -Wl,-z,defs -o example_hildonprogram  example_hildonprogram-example_hildonprogram.o -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0   -lhildon-1 -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0  
make[2]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/src'
make[2]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make[2]: Nothing to be done for `all-am'.
make[2]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make[1]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
#docbook-to-man debian/example.hildonprogram.sgml > example.hildonprogram.1
touch build-stamp
 fakeroot debian/rules binary
dh_testdir
dh_testroot
dh_clean -k
dh_installdirs
# Add here commands to install the package into debian/example.hildonprogram.
/scratchbox/tools/bin/make DESTDIR=/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/debian/example.hildonprogram install
make[1]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
Making install in src
make[2]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/src'
make[3]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/src'
test -z "/usr/bin" || mkdir -p -- . "/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/debian/example.hildonprogram/usr/bin"
  /scratchbox/tools/bin/install -c 'example_hildonprogram' '/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/debian/example.hildonprogram/usr/bin/example_hildonprogram'
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/src'
make[2]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1/src'
make[2]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make[3]: Entering directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make[3]: Nothing to be done for `install-exec-am'.
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make[2]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
make[1]: Leaving directory `/home/gigijoe/example_hildonprogram/example.hildonprogram-0.1'
dh_testdir
dh_testroot
dh_installchangelogs
dh_installdocs
dh_installexamples
dh_installman
dh_link
dh_strip
dh_compress
dh_fixperms
dh_installdeb
dh_shlibdeps
dh_gencontrol
dpkg-gencontrol: warning: unknown substitution variable ${misc:Depends}
dh_md5sums
dh_builddeb
dpkg-deb: building package `example.hildonprogram' in `../example.hildonprogram_0.1-1_armel.deb'.
 dpkg-genchanges -sa
dpkg-genchanges: including full source code in upload
dpkg-buildpackage: full upload (original source is included)

到這邊就已經完成囉

[sbox-FREMANTLE_ARMEL: ~/example_hildonprogram] > ls
Makefile     autom4te.cache  configure     example.hildonprogram-0.1            example.hildonprogram_0.1-1_armel.changes  missing
Makefile.am  compile         configure.ac  example.hildonprogram-0.1.tar.gz     example.hildonprogram_0.1-1_armel.deb      packaging
Makefile.in  config.log      data          example.hildonprogram_0.1-1.diff.gz  example.hildonprogram_0.1.orig.tar.gz      src
aclocal.m4   config.status   depcomp       example.hildonprogram_0.1-1.dsc      install-sh