#include <"ftw.h">
int Size;
int sum(const char *fpath, const struct stat *sb, int typeflag) {
Size += sb->st_size;
return 0;
}
void main()
{
ftw("/tmp", &sum, 1);
printf("the /tmp folder size:%d\n",Size);
return;
}
2013年3月5日 星期二
[Linux]計算目錄的大小
2012年7月7日 星期六
Linux Debug Tool - GDB
這次要寫一些有關Debug Tool -- GDB的筆記,分為三個部分來討論
1.建構 remote gdb + gdbserver 環境 for arm
2.常用gdb指令
3.core dump
參考資料
1.Debugging a Linux Application with MontaVista 5.0
2.DAVINCI调试ARM端应用程序
3.arm-linux-gdb+gdbserver环境搭建以及远程调试 及调试core文件
4.GDB指令
5.gdb stops at SIGPIPE
6.打開 core dump 和使用 cgdb 檢查程式掛點原因
7.產生 core dump 的方法
8.setting the core dump name schema
9.http://sourceware.org/gdb/wiki/FAQ
1.建構 remote gdb + gdbserver 環境 for arm
2.常用gdb指令
3.core dump
參考資料
1.Debugging a Linux Application with MontaVista 5.0
2.DAVINCI调试ARM端应用程序
3.arm-linux-gdb+gdbserver环境搭建以及远程调试 及调试core文件
4.GDB指令
5.gdb stops at SIGPIPE
6.打開 core dump 和使用 cgdb 檢查程式掛點原因
7.產生 core dump 的方法
8.setting the core dump name schema
9.http://sourceware.org/gdb/wiki/FAQ
訂閱:
文章 (Atom)