さて。。。

朝活はしてみているものの、どうしたものか。。

一先ず、-vオプションを追加して再度実行。

 

$ make run

make -r img

make -r haribote.img

x86_64-elf-gcc -v -march=i486 -m32 -nostdlib -T hrb.ld bootpack.c -o bootpack.hrb

組み込み spec を使用しています。

COLLECT_GCC=x86_64-elf-gcc

COLLECT_LTO_WRAPPER=/usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/9.3.0/lto-wrapper

ターゲット: x86_64-elf

configure 設定: ../configure --target=x86_64-elf --enable-targets=all --enable-multilib --prefix=/usr/local/Cellar/x86_64-elf-gcc/9.3.0 --without-isl --disable-werror --without-headers --with-as=/usr/local/opt/x86_64-elf-binutils/bin/x86_64-elf-as --with-ld=/usr/local/opt/x86_64-elf-binutils/bin/x86_64-elf-ld --enable-languages=c,c++

スレッドモデル: single

gcc バージョン 9.3.0 (GCC) 

COLLECT_GCC_OPTIONS='-v' '-march=i486' '-m32' '-nostdlib' '-T' 'hrb.ld' '-o' 'bootpack.hrb'

 /usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/9.3.0/cc1 -quiet -v bootpack.c -quiet -dumpbase bootpack.c -march=i486 -m32 -auxbase bootpack -version -o /var/folders/lq/kk7l39qx0j322v4gdb0whjlr0000gn/T//ccAYy3Hc.s

GNU C17 (GCC) version 9.3.0 (x86_64-elf)

compiled by GNU C version 4.2.1 Compatible Apple LLVM 11.0.0 (clang-1100.0.33.17), GMP version 6.2.0, MPFR version 4.0.2, MPC version 1.1.0, isl version none

GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072

存在しないディレクトリ "/usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/9.3.0/../../../../x86_64-elf/sys-include" を無視します

存在しないディレクトリ "/usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/9.3.0/../../../../x86_64-elf/include" を無視します

#include "..." の探索はここから始まります:

#include <...> の探索はここから始まります:

 /usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/9.3.0/include

 /usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/9.3.0/include-fixed

探索リストの終わりです。

GNU C17 (GCC) version 9.3.0 (x86_64-elf)

compiled by GNU C version 4.2.1 Compatible Apple LLVM 11.0.0 (clang-1100.0.33.17), GMP version 6.2.0, MPFR version 4.0.2, MPC version 1.1.0, isl version none

GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072

Compiler executable checksum: f18cf4e0852ad54c121674364b652e96

COLLECT_GCC_OPTIONS='-v' '-march=i486' '-m32' '-nostdlib' '-T' 'hrb.ld' '-o' 'bootpack.hrb'

 /usr/local/opt/x86_64-elf-binutils/bin/x86_64-elf-as -v --32 -o /var/folders/lq/kk7l39qx0j322v4gdb0whjlr0000gn/T//ccnHSgBg.o /var/folders/lq/kk7l39qx0j322v4gdb0whjlr0000gn/T//ccAYy3Hc.s

GNU アセンブラ バージョン 2.34 (x86_64-elf)、BFD バージョン (GNU Binutils) 2.34 を使用

COMPILER_PATH=/usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/9.3.0/:/usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/9.3.0/:/usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/:/usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/9.3.0/:/usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/

LIBRARY_PATH=/usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/9.3.0/

COLLECT_GCC_OPTIONS='-v' '-march=i486' '-m32' '-nostdlib' '-T' 'hrb.ld' '-o' 'bootpack.hrb'

 /usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/9.3.0/collect2 -plugin /usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/9.3.0/liblto_plugin.so -plugin-opt=/usr/local/Cellar/x86_64-elf-gcc/9.3.0/libexec/gcc/x86_64-elf/9.3.0/lto-wrapper -plugin-opt=-fresolution=/var/folders/lq/kk7l39qx0j322v4gdb0whjlr0000gn/T//ccExyhUa.res -o bootpack.hrb -L/usr/local/Cellar/x86_64-elf-gcc/9.3.0/lib/gcc/x86_64-elf/9.3.0 /var/folders/lq/kk7l39qx0j322v4gdb0whjlr0000gn/T//ccnHSgBg.o -T hrb.ld

/usr/local/opt/x86_64-elf-binutils/bin/x86_64-elf-ld: i386 architecture of input file `/var/folders/lq/kk7l39qx0j322v4gdb0whjlr0000gn/T//ccnHSgBg.o' is incompatible with i386:x86-64 output

collect2: エラー: ld はステータス 1 で終了しました

make[2]: *** [bootpack.hrb] Error 1

make[1]: *** [img] Error 2

make: *** [run] Error 2

まぁ、原因は明らかに64bit環境との不整合なのだろうが、

で、どうするぅ〜。。。。。

詳しい人なら一発なんだろうが、自分はそんな事もなく調べて試していくしかない。

どっからやろうかな。。(Orz..)