[x264-devel] cabac-a.asm breaks build on Mac OS X (PIC related)

Drew Yao ayao at apple.com
Tue Mar 25 02:08:36 CET 2008


On Mac OS X 10.5.2 Intel,

$ make
(cd x264;  ./configure --enable-pic --prefix="/Volumes/data_apps/vlc/ 
extras/contrib" && make && make install)
./configure: line 310: [: -lt: unary operator expected
./configure: line 319: yasm: command not found
./version.sh: line 2: git-rev-list: command not found
Platform:   X86
System:     MACOSX
avis input: no
mp4 output: no
pthread:    yes
gtk:        no
debug:      no
gprof:      no
PIC:        yes
shared:     no
visualize:  no

...

nasm -O2 -f macho -DPREFIX -DHAVE_SSE3 -D__PIC__ -Icommon/x86/ -o  
common/x86/cabac-a.o common/x86/cabac-a.asm
make[2]: *** [common/x86/cabac-a.o] Bus error
make[2]: *** Deleting file `common/x86/cabac-a.o'
make[1]: *** [.x264] Error 2
make: *** [src] Error 2

nasm crashed with a null dereference.

$ yasm -O2 -f macho -DPREFIX -DHAVE_SSE3 -D__PIC__ -Icommon/x86/ -o  
common/x86/cabac-a.o common/x86/cabac-a.asm
common/x86/cabac-a.asm:86: undefined symbol `fakegot' (first use)
common/x86/cabac-a.asm:86:  (Each undefined symbol is reported only  
once.)

If I run nasm or yasm without -D__PIC__, it works, but OS X requires  
PIC.

$ nasm -v
NASM version 2.02 compiled on Mar 24 2008

$ yasm --version
yasm 0.6.2.1985

After reverting bf9bf7acf61da13d9cc45c35291f61e614d7414c, x264 built  
with no problems.

---
Drew Yao





More information about the x264-devel mailing list