这几天在公司试了一下mono for android
在家编译就老报Could not locate Android SDK?最后在Monodroid Subscribers里面找到了答案!先记下,晚上回家试试!
我的android-sdk-windows不是默认安装,安装到D盘了!
I had the same build problem "could not find android sdk" and figured out the problem.
这几天在玩mono
//安装必需的包,以免编译出错
sudo apt-get install build-essential #这将安装gcc/g++/gdb/make 等基本编程工具
sudo apt-get update
下载mono-2.6.3 http://ftp.novell.com/pub/mono/sources/mono/
wget http://ftp.novell.com/pub/mono/sources/mono/mono-2.6.3.tar.bz2
下载完了,解压
tar jvxf mono-2.6.3.tar.bz2
cd mono-2.6.3
./configure --prefix=/usr
如果提示缺少bison
sudo apt-get install bison
如果提示缺少gettext
sudo apt-get install gettext
如果提示缺少glib-2.0
sudo apt-get install libglib2.0-dev
如果成功
make
sudo make install
编译的时候需要花费点时间
安装完了打 mono -V 看看是否显示mono版本
我的是2.6.3
sudo apt-get install pkg-config #用于在编译GTK程序时自动找出头文件及库文件位置
现在开始安装 gtk-sharp
我下的版本是gtk-sharp-2.12.10.tar.bz2
http://ftp.novell.com/pub/mono/sources/gtk-sharp212/gtk-sharp-2.12.10.tar.bz2
编辑一半是提示找不到 pango包
google了以下,输入以下命令
sudo apt-get install build-essential libgtk2.0-dev
安好了
下一步安MonoDevelop http://ftp.novell.com/pub/mono/sources/monodevelop/monodevelop-2.2.2.tar.bz2
跟上面的一样编译
tar jvxf monodevelop-2.2.2.tar.bz2
cd monodevelop-2.2.2
./configure --prefix=/usr
make
sudo make install
好了,安装完了
安monodevelop-2.2.2还比较顺利,主要是安mono有点麻烦,依赖的包太多了
sudo gedit /etc/apt/sources.list
#This is Sources list.
#Next is Sources.#Sources name:Cn99.
deb http://ubuntu.cn99.com/ubuntu/ hardy main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-security main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-updates main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-proposed main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ hardy-backports main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-security main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-updates main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-proposed main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ hardy-backports main restricted universe multiverse
#Sources name:ubuntu cn gov.
deb http://archive.ubuntu.org.cn/ubuntu-cn/ hardy main restricted universe multiverse
#Sources name:ubuntu tw gov.
#This is slowly,so close.
# deb http://tw.archive.ubuntu.com/ubuntu hardy main restricted universe multiverse
# deb http://tw.archive.ubuntu.com/ubuntu hardy-security main restricted universe multiverse
# deb http://tw.archive.ubuntu.com/ubuntu hardy-updates main restricted universe multiverse
# deb http://tw.archive.ubuntu.com/ubuntu hardy-backports main restricted universe multiverse
# deb http://tw.archive.ubuntu.com/ubuntu hardy-proposed main restricted universe multiverse
#Sources name:Rootguide
deb http://mirror.rootguide.org/ubuntu/ hardy main restricted universe multiverse
deb http://mirror.rootguide.org/ubuntu/ hardy-security main restricted universe multiverse
deb http://mirror.rootguide.org/ubuntu/ hardy-updates main restricted universe multiverse
deb http://mirror.rootguide.org/ubuntu/ hardy-backports main restricted universe multiverse
deb http://mirror.rootguide.org/ubuntu/ hardy-proposed main restricted universe multiverse
#Sources name:ubuntu software
#Done
deb http://apt.schmidtke-hb.de hardy main
deb-src http://apt.schmidtke-hb.de hardy main
#The sources list is over.
我不知道大家装了sp1的是不是正常的!
回头看去,从申请到博客到现在已经有两年时间,说来惭愧啊!关于技术方面的文章一篇没有写,新的一年来到了,2008年一定要写,不能因为学习及工作的原因而耽误了,是该静下心来,把自已几年学习的与博客园的朋友交流一下了!
