Linux上构筑iPhone OS3.1.2开发环境之编译HELLO WORLD
终于到了编译范例的时候了,范例在APPS目录里,好兴奋呀。。。
开始编译:
zhaowei@zhaowei-ubuntu:~/toolchain/apps/HelloToolchain$ make
arm-apple-darwin9-gcc -lobjc -bind_at_load -framework Foundation -framework CoreFoundation -framework UIKit -w -o HelloToolchain HelloToolchain.o
ld: library not found for -lobjc
collect2: ld returned 1 exit status
make: *** [HelloToolchain] 错误 1
看见没有,又报错了。在官方讨论区我找到解决方法。看下面:
Here's the solution I used (thanks brian.cr...):
Build the toolchain
In ~/Projects/iphone/toolchain/toolchain/sys, rename folder System to System2
In ~/Projects/iphone/toolchain/toolchain/sys/usr, rename folder lib to lib2
Copy folder ~/Projects/iphone/toolchain/sdks/iPhoneOS3.1.2.sdk/System to ~/Projects/iphone/toolchain/toolchain/sys
Copy folder ~/Projects/iphone/toolchain/sdks/iPhoneOS3.1.2.sdk/usr/lib to ~/Projects/iphone/toolchain/toolchain/sys/usr
Try to build HelloToolchain? again using instructions on this page (above).
Hope that helps. This was the only error I encountered using the toolchain.sh script
重新编译,看输出结果,证明我们编译成功了。呼呼,接下来就是要上传到IPHONE了。
zhaowei@zhaowei-ubuntu:~/toolchain/apps/HelloToolchain$ make
/home/zhaowei/toolchain/toolchain/pre/bin/arm-apple-darwin9-gcc -lobjc -bind_at_load -framework Foundation -framework CoreFoundation -framework UIKit -w -o HelloToolchain HelloToolchain.o
使用这个命令上传到IPHONE:
Navigate to the apps/HelloToolchain directory and run the following commands, noting that you must set "IP" to the address of your iPhone and change the path as appropriate:
cd ~/toolchain/apps/HelloToolchain
IP=xxx.xxx.xxx.xxx PATH=../../toolchain/pre/bin/:$PATH make deploy
上传会需要你输入密码,我居然试了半天,密码错误,怎么可能,默认的密码都进不去,后来才想起,是自己当初玩的时候修改了密码
默认密码:!1.02 的系统密码是dottie. 1.1.1密码是alpine.
我的密码是:***** 。哈哈。
记得修改密码哦。
上传成功的样子:
zhaowei@zhaowei-ubuntu:~/toolchain/a
相关文档:
1. linux下启动oracle
su - oracle
sqlplus /nolog
conn /as sysdba
startup
exit
lsnrctl start
exit
2. linux下关闭oracle
su - oracle
sqlplus /nolog
conn /as sysdba
shutdown immediate
exit
lsnrctl stop
exit
可以使用lsnrctl 进去后用status查看状态,类似:
lsnrctl
status
http://hi.baidu.c ......
1,网络整体流量查看
ifconfig -s
cat /proc/net/dev
sar -n DEV/EDEV interval(时间隔) count(次数)
nload -m [-d interface]
2,详细查看网络流量,比如查看某一个ip/port,某一个协议
iptraf,文本窗口界面
ntop,web网页界面 ......
由bootload进入linux后由head.s进入了start_kernel了.
asmlinkage void __init start_kernel(void)
{
char * command_line;
extern struct kernel_param __start___param[], __stop___param[];
&hel ......
昨天郁闷了一天,因为不管我如何编译,总是有错误产生。
没想到今天我清理掉所有文件,重新操作了一编,居然神奇般编译成功了。挖哈哈。。。太高兴了,终于离编译可运行在IPHONE
机器上的HELLO world 不远了,太激动了。。
总结一下:我昨天安装了管方列出的所有包,还有就是不放弃,多试几次。
Here we provide a list ......