Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#28537 closed defect (invalid)

db46: cannot run C compiled programs

Reported by: jbasch94@… Owned by: blair (Blair Zajac)
Priority: Normal Milestone:
Component: ports Version: 1.9.2
Keywords: Cc: ryandesign (Ryan Carsten Schmidt)
Port: db46

Description

db46 fails during configure on Mac OS X 10.6.6 with Xcode 3.2.5 and the Java Developer Update installed.

NOTE: This is not the Java header issue, it's a different error and I have tried the fixes supplied in those threads to no avail.

The log file is attached.

It seems to be a problem with the C compiler.

Attachments (2)

main.log.zip (2.0 KB) - added by jbasch94@… 14 years ago.
config.log.zip (3.8 KB) - added by jbasch94@… 14 years ago.

Download all attachments as: .zip

Change History (9)

Changed 14 years ago by jbasch94@…

Attachment: main.log.zip added

comment:1 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign@… added; blair removed
Keywords: db46 configure removed
Owner: changed from macports-tickets@… to blair@…
Summary: db46 configure shell command faileddb46: cannot run C compiled programs

FYI, the Cc field must contain complete email addresses.

The log says:

:info:configure checking whether the C compiler works... configure: error: cannot run C compiled programs.
:info:configure If you meant to cross compile, use `--host'.
:info:configure See `config.log' for more details.

So please attach that config.log so we can see what it says.

Changed 14 years ago by jbasch94@…

Attachment: config.log.zip added

comment:2 Changed 14 years ago by jmroot (Joshua Root)

configure:3955: checking for C compiler default output file name
configure:3982: /usr/bin/gcc-4.2 -O2 -arch x86_64 -I/opt/local/include -L/opt/local/lib -arch x86_64 conftest.c  >&5
configure:3985: $? = 0
configure:4023: result: a.out
configure:4040: checking whether the C compiler works
configure:4050: ./a.out
../dist/configure: line 4051: ./a.out: Bad CPU type in executable

Is your machine 32-bit?

comment:3 in reply to:  2 ; Changed 14 years ago by jbasch94@…

Replying to jmr@…:

Is your machine 32-bit?

Yes.

comment:4 in reply to:  3 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to jbasch94@…:

Replying to jmr@…:

Is your machine 32-bit?

Yes.

Then you shouldn't try to build 64-bit. :)

Look in your macports.conf. Set build_arch to i386, and set universal_archs to i386 ppc. Then clean db46 and try again.

sudo port clean db46

comment:5 Changed 14 years ago by jbasch94@…

Thanks. New install. I overlooked that.

comment:6 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: invalid
Status: newclosed

MacPorts ships with a macports.conf where the build_arch is commented out, meaning the code in MacPorts base takes over, and it chooses the default build_arch based on your machine's capabilities. That code is here: trunk/base/src/macports1.0/macports.tcl?rev=74924#L826 and its behavior is described by the comment in macports.conf, which reads:

# CPU architecture to compile for. Defaults to i386 or ppc on Mac OS X 10.5
# and earlier, depending on the CPU type detected at runtime. On Mac OS X 10.6
# the default is x86_64 if the CPU supports it, i386 otherwise.
#build_arch			i386

So I don't know how you ended up with a configuration that tried to build 64-bit on a machine that can't do that, unless you changed the macports.conf yourself to say that.

comment:7 in reply to:  6 Changed 14 years ago by jbasch94@…

So I don't know how you ended up with a configuration that tried to build 64-bit on a machine that can't do that, unless you changed the macports.conf yourself to say that.

It's a mystery to me. I hadn't changed it, but it was set to x86_64 somehow.

Thanks for your help.

Note: See TracTickets for help on using tickets.