ude:~# apt-get update
ude:~# apt-get install make gcc Reading Package Lists... Done Building Dependency Tree... Done The following extra packages will be installed: binutils cpp cpp-3.3 gcc-3.3 Suggested packages: binutils-doc cpp-doc manpages-dev autoconf automake libtool flex bison gdb gcc-doc gcc-3.3-doc Recommended packages: libc-dev libc6-dev The following NEW packages will be installed: binutils cpp cpp-3.3 gcc gcc-3.3 make 0 upgraded, 6 newly installed, 0 to remove and 0 not upgraded. Need to get 5371kB of archives. After unpacking 14.0MB of additional disk space will be used. Do you want to continue? [Y/n] y Get:1 http://ftp.jp.debian.org sarge/main binutils 2.15-6 [2072kB] Get:2 http://ftp.jp.debian.org sarge/main cpp-3.3 1:3.3.5-13 [1275kB] Get:3 http://ftp.jp.debian.org sarge/main cpp 4:3.3.5-3 [29.6kB] Get:4 http://ftp.jp.debian.org sarge/main gcc-3.3 1:3.3.5-13 [1558kB] Get:5 http://ftp.jp.debian.org sarge/main gcc 4:3.3.5-3 [4920B] Get:6 http://ftp.jp.debian.org sarge/main make 3.80-9 [431kB] Fetched 5371kB in 30s (178kB/s) Selecting previously deselected package binutils. (Reading database ... 7661 files and directories currently installed.) Unpacking binutils (from .../binutils_2.15-6_arm.deb) ... Selecting previously deselected package cpp-3.3. Unpacking cpp-3.3 (from .../cpp-3.3_1%3a3.3.5-13_arm.deb) ... Selecting previously deselected package cpp. Unpacking cpp (from .../cpp_4%3a3.3.5-3_arm.deb) ... Selecting previously deselected package gcc-3.3. Unpacking gcc-3.3 (from .../gcc-3.3_1%3a3.3.5-13_arm.deb) ... Selecting previously deselected package gcc. Unpacking gcc (from .../gcc_4%3a3.3.5-3_arm.deb) ... Selecting previously deselected package make. Unpacking make (from .../archives/make_3.80-9_arm.deb) ... Setting up binutils (2.15-6) ... Setting up cpp-3.3 (3.3.5-13) ... Setting up cpp (3.3.5-3) ... Setting up gcc-3.3 (3.3.5-13) ... Setting up gcc (3.3.5-3) ... Setting up make (3.80-9) ... ude:~#
ude:~# cd /tmp ude:/tmp# cat > a.c main() { printf("Why don't you hack LS-GL?\n"); } CTRL-D ude:/tmp#コンパイルして、実行。。。と思ったら、、、
ude:/tmp# cc a.c /usr/bin/ld: crt1.o: No such file: No such file or directory collect2: ld returned 1 exit status ude:/tmp#こういうとき debian 素人には、 次どうやったらいいのか全く心当たりもつかなくて困ってしまうのね。
Recommended packages: libc-dev libc6-devと言われているので、これらをインストールしたら良いらしい。
ude:/tmp# apt-get install libc-dev libc6-dev Reading Package Lists... Done Building Dependency Tree... Done Note, selecting libc6-dev instead of libc-dev Suggested packages: glibc-doc manpages-dev The following NEW packages will be installed: libc6-dev linux-kernel-headers 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded. Need to get 4298kB of archives. After unpacking 17.7MB of additional disk space will be used. Get:1 http://ftp.jp.debian.org sarge/main linux-kernel-headers 2.5.999-test7-bk-17 [1473kB] Get:2 http://ftp.jp.debian.org sarge/main libc6-dev 2.3.2.ds1-22sarge4 [2825kB] Fetched 4298kB in 25s (166kB/s) Selecting previously deselected package linux-kernel-headers. (Reading database ... 7888 files and directories currently installed.) Unpacking linux-kernel-headers (from .../linux-kernel-headers_2.5.999-test7-bk-17_arm.deb) ... Selecting previously deselected package libc6-dev. Unpacking libc6-dev (from .../libc6-dev_2.3.2.ds1-22sarge4_arm.deb) ... Setting up linux-kernel-headers (2.5.999-test7-bk-17) ... Setting up libc6-dev (2.3.2.ds1-22sarge4) ... ude:/tmp#
ude:/tmp# !cc cc a.c ude:/tmp# ./a.out Why don't you hack LS-GL? ude:/tmp#だーん
← LS-GL:debian:9時間ずれ |
ハックの記録 LinkStation/玄箱 をハックしよう |
→ LS-GL:debian:mkimage の make |