Compiling Sphinx on OSX Leopard
Wednesday, January 7th, 2009Here’s a quicky – I have recently moved my dev env from Ubuntu/Gnome on a Dell XPS m1330 laptop to a MacBook Pro laptop. My dev env requires the Sphinx search engine so here’s how to compile it on Leopard.
With a straight ./configure; make you will get the following error:
ld: warning in indexer.o, file is not of required architecture
ld: warning in libsphinx.a, file is not of required architecture
ld: warning in /usr/local/mysql/lib/libmysqlclient.dylib, file is not of required architecture
ld: warning in /usr/local/mysql/lib/libmygcc.a, file is not of required architecture
Undefined symbols:
"_main", referenced from:
start in crt1.10.5.o
ld: symbol(s) not found
Here’s what you need to do:
export LDFLAGS="-arch x86_64"; ./configure
