On Sep 10, 2009, at 11:42 PM, Richard Jones wrote: On 11/09/2009, at 1:10 PM, John Ralls wrote: On Sep 10, 2009, at 5:37 PM, Richard Jones wrote:
I have no Fink, DarwinPorts, MacPorts or similar environment set up.
My system is an upgrade from Leopard. I had installed Python 2.6 (a
32-bit build) under Leopard using the installer from python.org and
that remains the active python 2.6 on the system (Snow Leopard
upgrade did not overwrite it). I have some things installed in /usr/
local/ but I don't believe any of it is relevant. Other than that I
cannot think of anything that would affect the build of glib, yet
when I run "jhbuild build meta-gtk-osx-core" I get the attached
output.
Please advise if there's any other information that would help debug
this problem.
Did you run jhbuild bootstrap and jhbuild build meta-gtk-osx-bootstrap
before attempting to jhbuild build meta-gtk-osx-core?
Yep, I followed the instructions as given at: http://sourceforge.net/apps/trac/gtk-osx/wiki/BuildAnd there are no problems reported building those things. Other than that, does `which gcc` report /usr/bin/gcc, and /usr/bin/
gcc point to /usr/bin/gcc-4.2?
Yes. Is this an absolutely clean start on 10.6, or might there be
leftovers from 10.5?
The system was upgraded from 10.5 but the build was started in 10.6 Gatomic.c has a bunch of assembly routines. While %rdx isn't mentioned
explicitly in the source file, it might be something mis-generated
somewhere. Just to be sure that /usr/local doesn't have anything
strange and that there are no leftovers, try the following:
$ rm -rf ~/gtk
$ export PATH=/usr/bin:/bin:~/.local/bin
$ jhbuild bootstrap
$ jhbuild build meta-gtk-osx-bootstrap meta-gtk-osx-core
I went one step further and removed ~/.local as well, but I had to include git's install directory: $ rm -rf ~/gtk ~/.local $ export PATH=/usr/bin:/bin:~/.local/bin:/usr/local/git/bin $ jhbuild bootstrap $ jhbuild build meta-gtk-osx-bootstrap meta-gtk-osx-core With the same outcome - the error compiling "gatomic.c". I tried it twice, just to be sure. I googled the error and found a discussion on an unrelated project's site which suggested using "-m32" switch to gcc. I used that and got "gatomic.c" to compile. Unfortunately I can't figure how to work that into the jhbuild process.
Aha! So it is a 64-bit issue. I was wondering about that as I went to sleep last night.
There are several ways to get a 32-bit build. The most consistent is to add the following to your .jhbuildrc-custom:
environ_append("CFLAGS", " -arch i386") environ_append("CXXFLAGS", " -arch i386") environ_append("LDFLAGS", " -arch i386")
Do note that you'll need to do a clean start. 32-bit and 64 bit libraries don't mix.
Note the leading space, to separate the flag from the last one already in *FLAGS. You could also use -m32 instead of -arch 386. Another user, in gtk-osx-devs, worked out a way to get glib to build in 64-bit mode by editing config.h, though perhaps at the expense of not building glib's atomic operations. That part will be a matter for study later.
Regards, John Ralls
|