Well one can do that, yes, but by default any configure script is going to
look for g++ first, find an ancient g++4.2 installed in /usr/bin/g++ and
use that unless the user specifically sets CC. I'm a bit fuzzy on the
timeline of FreeBSD's transition to clang over the last few years and so
was hoping for a autoconf recipe that prefers the appropriate compiler
(e.g. did we have clang on FreeBSD 7?) when the user doesn't manually
specify CC.
Given the preference for gcc in configure I guess I could just use
something as simple as :
if uname="FreeBSD"
# override configure preference for gcc since FreeBSD ships an ancient
one.
AC_PROG_CC(clang llvm-gcc gcc)
AC_PROG_CXX(clang++ llvm-g++ g++)
else
AC_PROG_CC
AC_PROG_CXX
fi
?
- Murray
On Thu, Sep 12, 2013 at 6:56 PM, Warner Losh <[email protected]> wrote:
>
> On Sep 12, 2013, at 7:32 PM, Murray Stokely wrote:
>
> > Some application software I use seems to prefer ancient gcc release or
> > gcc46 from ports rather than clang.
> >
> > Is there a recommended autoconf recipe for third party software to use
> the
> > right compilers across FreeBSD versions?
>
> I thought the compiler was passed with the CC variable to gnu configure...
> Or are you asking for something else?
>
> Warner
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-toolchain
To unsubscribe, send any mail to "[email protected]"