pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

gcc5 and Darwin



Hi,

I managed to get GCC 5.2.0 compiled on my OS X 10.10.4 system (had to
disable ccache and use MAKE_JOBS=1), but I'm unable to use it as the
main PKGSRC_COMPILER because it chokes on system headers in /usr/include
that some packages (gettext) seems to include indirectly.

It is one particular header, "/usr/include/dispatch/object.h", that is
causing the problem.  It has the following line in it:

    typedef void (^dispatch_block_t)(void);

... which I think is either ObjC or something Apple specific.

I built gcc5 with default options.  In etc/mk.conf I have:

    PKGSRC_COMPILER=    ccache gcc
    USE_PKGSRC_GCC=     yes
    USE_PKGSRC_RUNTIME= yes
    GCC_REQD=           5.2.0
    GCCBASE=            ${LOCALBASE}/gcc5

I can see /usr/include being used by the build process, but I don't
quite know how to force pkgsrc to avoid it.  I'm not even sure it's
resonable to want to avoid /usr/include, but that's the only solution I
can think of.  I tried setting "CPP_PRECOMP_FLAGS=-nostdinc" but that
obviously (?) didn't work.

Maybe I'm a bit naïve in thinking this would work out of the box, but it
would be nice if it did.

Thanks,

-- 
:: Andreas Kusalananda Kähäri, Bioinformatics Developer, BILS,
:: Uppsala University, Sweden
::----------------------------------------------------------------------
:: My other car is a cdr.


Home | Main Index | Thread Index | Old Index