[OSX] milter won't build
sdm7g at Virginia.EDU
Mon Feb 4 00:43:21 CET 2002
On 3 Feb 2002, rdack wrote:
> trying to build milter module 0.3.9 on OSX 10.1.2 i get this error:
> cc -bundle -undefined suppress build/temp.darwin-5.2-Power
> Macintosh-2.1/miltermodule.o -lmilter -lsm -o
> build/lib.darwin-5.2-Power Macintosh-2.1/milter.so
> /usr/bin/ld: -undefined error must be used when -twolevel_namespace is
> in effect
> error: command 'cc' failed with exit status 1
> is it telling me i need an '-undefined error' option? or that it
> doesn't like the 'undefined suppress' option?
I don't know what the milter module is, but:
OSX gcc/ld doesn't like that combination. You can use either of:
-twolevel_namespace -undefined error
-flat_namespace -undefined suppress
But I think the defaults are:
So, you get generate that error with only one of those switches
with the wrong default for the other.
Python modules on OSX is usually built with:
-bundle -flat_namespace -undefined suppress
> where is the 'cc -bundle' command set up? can i edit it?
> is it possible that it finished and the module is ready to go?
Is milter using distutils ? i.e. is it using a 'setup.py' file to
build and install, or does it use a Makefile ?
What command did you use to build it?
(Distutils should get the build command right, but if you have more
than one version of Python installed, you need to make sure that
you're running the version that you're going to link to. )
> where would the milter module end up after install?
> what will its name be?
> are python modules '.pyo' files? do they end up in the
> /usr/local/lib/python2.1 directory?
If it's a dynamic shared lib, it'll usually be an .so file, and it
should usually install in the site-packages directory, likely in
/usr/local/lib/python[v.n]/ . ( It might also go in plat-darwin*/
or somewhere else in that tree. )
Are you building 2.1.2 ? or just 2.1 ?
You probably ought to stick to 2.1.2 or 2.2 on OSX.
More information about the Python-list