C 交叉编译Prex

C 交叉编译Prex,c,gcc,compilation,makefile,configure,C,Gcc,Compilation,Makefile,Configure,我正试图使用以下指南编译prex: 我想用它制作一个可启动的USB,并在任何计算机上运行它 现在,我使用的是x86_64 linux系统 uname -a Linux xbaremenos 3.19.0-32-generic #37~14.04.1-Ubuntu SMP Thu Oct 22 09:41:40 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux 我跑 ./configure --target=x86-pc --cross-prefix=x86_64-

我正试图使用以下指南编译prex:

我想用它制作一个可启动的USB,并在任何计算机上运行它

现在,我使用的是x86_64 linux系统

uname -a
Linux xbaremenos 3.19.0-32-generic #37~14.04.1-Ubuntu SMP Thu Oct 22 09:41:40 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
我跑

./configure --target=x86-pc --cross-prefix=x86_64-linux-gnu-
它指定我希望它为x86平台构建,但当我尝试运行make时,我收到了以下消息

 ~/Downloads/prex-0.9.0 $ make
x86_64-linux-gnu-cpp -D__ASSEMBLY__  -D__x86__ -D__pc__ -DKERNEL -I. -I/home/xbaremenos/Downloads/prex-0.9.0 -I/home/xbaremenos/Downloads/prex-0.9.0/include -I/home/xbaremenos/Downloads/prex-0.9.0/bsp/boot/include -I/home/xbaremenos/Downloads/prex-0.9.0/bsp/boot/x86 x86/pc/head.S x86/pc/head.tmp
x86_64-linux-gnu-as  -o x86/pc/head.o x86/pc/head.tmp
rm -f x86/pc/head.tmp
x86_64-linux-gnu-gcc  -c -Os -ansi -pedantic -Wall -Wundef -Wstrict-prototypes -Wpointer-arith -nostdinc -fno-strict-aliasing -fno-stack-protector -march=i386 -mpreferred-stack-boundary=2 -fomit-frame-pointer -fno-builtin  -D__x86__ -D__pc__ -DKERNEL -I. -I/home/xbaremenos/Downloads/prex-0.9.0 -I/home/xbaremenos/Downloads/prex-0.9.0/include -I/home/xbaremenos/Downloads/prex-0.9.0/bsp/boot/include -I/home/xbaremenos/Downloads/prex-0.9.0/bsp/boot/x86 -o x86/pc/startup.o x86/pc/startup.c
x86/pc/startup.c:1:0: error: CPU you selected does not support x86-64 instruction set
 /*-
 ^
x86/pc/startup.c:1:0: error: CPU you selected does not support x86-64 instruction set
x86/pc/startup.c:1:0: error: -mpreferred-stack-boundary=2 is not between 3 and 12
make[2]: *** [x86/pc/startup.o] Error 1
make[1]: *** [boot] Error 2
make: *** [bsp] Error 2

我做错了什么

是否确实要使用
--交叉前缀
?如果省略它,结果相同。一开始我尝试不使用它,但没有运气:(你确定你想要
--交叉前缀吗?
?如果省略它,结果是一样的。一开始我尝试不使用它,但没有运气:(