[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Mac OSX make
From: |
David Sugar |
Subject: |
Re: Mac OSX make |
Date: |
Sun, 21 Sep 2003 23:59:56 -0400 |
User-agent: |
KMail/1.5 |
I generally have built Common C++ on a macosx machine with gcc 3.1, and macosx
10.2.x. Common C++ does a second stage link because there is a bug in the
way macosx handles c++ shared libraries that stretch over multiple object
modules; it fails to run constructors for embedded objects (statically
initialized classes) if they are spread out over multiple object modules when
the library is loaded. The second stage link sticks the seperate object
modules into a single object module. It seems, on your machine, that second
stage link is failing.
I would suggest doing a "rm libtool" and removing the configure support files
from the "config" subdirectory, and then runn ./reconfig and re-run
./configure and then "make clean". This will build a new configure script
and use the version of libtool provided on macosx. I suspect the default
libtool used in later distributions (which is what normally is distributed in
the tarball) are in some way no longer compatible; perhaps it is using
invalid compile options for building macosx shared objects. I generally test
and build on macosx right from cvs (using ./reconfig to build configure
locally on macosx) rather than from the dist tarballs.
On Sunday 21 September 2003 04:08 pm, ajstone wrote:
> Commoncpp developers,
>
> I am trying to build Commoncpp 2 on OSX with GCC 3.1. It fails during
> the make with the following:
>
> ld -r -o ccgnu2.lo thread.lo mutex.lo semaphore.lo threadkey.lo
> friends.lo event.lo slog.lo dir.lo file.lo inaddr.lo peer.lo port.lo
> socket.lo network.lo serial.lo mempager.lo keydata.lo dso.lo
> exception.lo process.lo urlstring.lo getopt.lo getopt1.lo
> ld: thread.lo bad magic number (not a Mach-O file)
> ld: mutex.lo bad magic number (not a Mach-O file)
> ld: semaphore.lo bad magic number (not a Mach-O file)
> ld: threadkey.lo bad magic number (not a Mach-O file)
> ld: friends.lo bad magic number (not a Mach-O file)
> ld: event.lo bad magic number (not a Mach-O file)
> ld: slog.lo bad magic number (not a Mach-O file)
> ld: dir.lo bad magic number (not a Mach-O file)
> ld: file.lo bad magic number (not a Mach-O file)
> ld: inaddr.lo bad magic number (not a Mach-O file)
> ld: peer.lo bad magic number (not a Mach-O file)
> ld: port.lo bad magic number (not a Mach-O file)
> ld: socket.lo bad magic number (not a Mach-O file)
> ld: network.lo bad magic number (not a Mach-O file)
> ld: serial.lo bad magic number (not a Mach-O file)
> ld: mempager.lo bad magic number (not a Mach-O file)
> ld: keydata.lo bad magic number (not a Mach-O file)
> ld: dso.lo bad magic number (not a Mach-O file)
> ld: exception.lo bad magic number (not a Mach-O file)
> ld: process.lo bad magic number (not a Mach-O file)
> ld: urlstring.lo bad magic number (not a Mach-O file)
> ld: getopt.lo bad magic number (not a Mach-O file)
> ld: getopt1.lo bad magic number (not a Mach-O file)
>
> What is wrong with my ld to cause this? Also reporting this as a bug.
>
> Full GCC version string: gcc (GCC) 3.1 20020420 (prerelease)
> OS: Darwin 6.6/OS 10.2.6
>
>
>
> _______________________________________________
> Bug-commoncpp mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/bug-commoncpp
- Mac OSX make, ajstone, 2003/09/21
- Re: Mac OSX make,
David Sugar <=