mxcl/homebrew — Issue #8180: bdw-gc fails with LLVM and with --use-gcc
Author: amesign
Created: 2011-10-18 23:56:16+00:00
State: open

`brew install bdw-gc` results in this error:

/bin/sh ./libtool --tag=CC --mode=compile /usr/bin/llvm-gcc -DPACKAGE_NAME=\"gc\" -DPACKAGE_TARNAME=\"gc\" -DPACKAGE_VERSION=\"7.1\" -DPACKAGE_STRING=\"gc\ 7.1\" -DPACKAGE_BUGREPORT=\"Hans.Boehm@hp.com\" -DGC_VERSION_MAJOR=7 -DGC_VERSION_MINOR=1 -DPACKAGE=\"gc\" -DVERSION=\"7.1\" -DGC_DARWIN_THREADS=1 -DTHREAD_LOCAL_ALLOC=1 -DHAS_X86_THREAD_STATE32___EAX=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DNO_EXECUTE_PERMISSION=1 -DALL_INTERIOR_POINTERS=1 -DGC_GCJ_SUPPORT=1 -DJAVA_FINALIZATION=1 -DATOMIC_UNCOLLECTABLE=1 -I./include -D_XOPEN_SOURCE -fexceptions -I libatomic_ops/src -O3 -march=core2 -w -pipe -c -o pcr_interface.lo pcr_interface.c
libatomic_ops/src/atomic_ops/sysdeps/gcc/x86_64.h: In function 'AO_test_and_set_full':
libatomic_ops/src/atomic_ops/sysdeps/gcc/x86_64.h:127: error: unsupported inline asm: input constraint with a matching output constraint of incompatible type!

I see that the formula for bdw-gc includes `fails_with_llvm "LLVM gives an unsupported inline asm error", :build => 2335`, but it still seems to break.

If I run `brew install --use-gcc bdw-gc`, I get this:

Error: type mismatch: String given
Please report this bug:
https://github.com/mxcl/homebrew/wiki/checklist-before-filing-a-new-issue
/usr/local/Library/Homebrew/extend/ENV.rb:138:in `=~'
/usr/local/Library/Homebrew/extend/ENV.rb:138:in `gcc'
/usr/local/Library/Homebrew/extend/ENV.rb:27:in `setup_build_environment'
/usr/local/Library/Homebrew/build.rb:23
/usr/local/Library/Formula/bdw-gc.rb:10

`brew doctor` gives:

Your gcc 4.2.x version is older than the recommended version. It may be advisable
to upgrade to the latest release of Xcode.

Some "config" scripts were found in your path, but not in system or Homebrew folders.

`./configure` scripts often look for *-config scripts to determine if software packages
are installed, and what additional flags to use when compiling and linking.

Having additional scripts in your path can confuse software installed via Homebrew if
the config script overrides a system or Homebrew provided script of the same name.

/Library/Frameworks/Python.framework/Versions/Current/bin
python-config python2.7-config

This is on Mac OS 10.6.8, Xcode 4.2 (4C199). `gcc --version` gives:

i686-apple-darwin10-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.1.00)