For the past couple of weeks I’ve been trying to get the Redland RDF toolkit installed on my powerbook. I initially tried installing it using the vanilla tools, but kept running into the error:

ld: common symbols not allowed with MH_DYLIB output format with the
-multi_module option
/usr/local/mysql/lib/libmysqlclient.a(my_error.o) definition of common
_errbuff (size 512)
make[2]: *** [librdf.la] Error 1

I upgraded a few of the standard tools (such as libtool) using the latest sources from the GNU website, and Raptor and Rasqal compiled without a hitch. But Redland still threw that same error and google turned up little in the way of help.

Having googled over and over again, it seemed the only way anyone had managed to get Redland installed on OS X was using either fink or darwinports, so I installed fink, but once again ran into the same error.

In the end, a solution came in removing the MySQL instance that I had installed using the binaries on the MySQL website and switching to the fink version of MySQL.

Removing MySQL allowed me to install Redland, and build the perl language bindings, but the python bindings kept throwing the error:

gcc -g -O2  -I/usr/local/include -I/usr/local/include -I/usr/local/include
-I/sw/include/db4  -g -O2   -Wl,-F. -Wl,-F. -bundle Redland_wrap.so
`redland-config --libs` -o Redland.so
ld: Undefined symbols:
_PyArg_ParseTuple

followed by a long list of other python symbols. My system seemed to be using the fink-installed python rather than the system default, so I tried configuring with:

./configure --with-python=/usr/bin/python

Which seems to have done the trick. At least, ‘import RDF’ works from the system python.