在运行OS X 10.7 Lion的Mac上从源代码编译SDL

时间:2011-08-24 03:03:09

标签: c++ sdl osx-lion

我已经从libsdl网站下载了SDL源SDL-1.2.14.zip并进入了make步骤。 当我./configure时,我没有任何问题。但是,当我make时,它在编译过程中看起来很长,并且在输出中死掉了:

/bin/sh ./libtool --mode=compile gcc -g -O2  -I./include -D_GNU_SOURCE=1 -DTARGET_API_MAC_CARBON -DTARGET_API_MAC_OSX -fvisibility=hidden  -I/usr/X11R6/include -DXTHREADS -D_THREAD_SAFE -force_cpusubtype_ALL -fpascal-strings -c ./src/video/SDL_RLEaccel.c  -o build/SDL_RLEaccel.lo
libtool: compile:  gcc -g -O2 -I./include -D_GNU_SOURCE=1 -DTARGET_API_MAC_CARBON -DTARGET_API_MAC_OSX -fvisibility=hidden -I/usr/X11R6/include -DXTHREADS -D_THREAD_SAFE -force_cpusubtype_ALL -fpascal-strings -c ./src/video/SDL_RLEaccel.c  -fno-common -DPIC -o build/.libs/SDL_RLEaccel.o
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:1168:suffix or operands invalid for `movq'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:1829:suffix or operands invalid for `movq'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:2566:suffix or operands invalid for `movq'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:2836:suffix or operands invalid for `movd'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:2934:suffix or operands invalid for `movq'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:3884:suffix or operands invalid for `movq'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:4433:suffix or operands invalid for `movq'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:4992:suffix or operands invalid for `movq'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:5207:suffix or operands invalid for `movd'
/var/folders/l_/_b6srsss7sggnnclplzx59280000gn/T//ccG8MUwb.s:5307:suffix or operands invalid for `movq'
make: *** [build/SDL_RLEaccel.lo] Error 1

我已经尝试了所有我能想到的事情并完成了我认为对此主题的大量搜索,但找不到任何看起来密切相关的内容。

有没有人尝试为Lion编译SDL并成功了?

2 个答案:

答案 0 :(得分:8)

尝试./configure --disable-assembly

答案 1 :(得分:1)

假设你不想取消禁用所有程序集的性能影响,它实际上是one character change to fix the build on LLVM