Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 28 Jul 2012 07:46:12 -0400
From:      Robert Huff <roberthuff@rcn.com>
To:        "freebsd-ports@freebsd.org" <freebsd-ports@freebsd.org>
Subject:   Re: rxvt-unicode fails build 9 stable i386
Message-ID:  <20499.53508.240666.522994@jerusalem.litteratus.org>
In-Reply-To: <50139DA9.7030604@FreeBSD.org>
References:  <20120726191748.5fa39af3@vaio9bsd> <20120727091023.GB22954@megatron.madpilot.net> <20120727192724.09f82cca@dell64> <50139DA9.7030604@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help

Guido Falsi writes:

>  > If I put this clang information into /etc/make.conf will I need to
>  > rebuild all of my installed ports?
>  >
>  
>  The ports system is not ready to use clang as the only
>  compiler. If you want to add this hack to your make.conf it's
>  better if you do it conditionally only for this port like:
>  
>  .if ${.CURDIR:M*x11/rxvt-unicode*}
>     CC=                   clang
>     CXX=                  clang++
>     CPP=                  clang-cpp
>  .endif
>  
>  Binaries and library generated with gcc and clang should be
>  compatible with each other, so, if you just compile a few ports
>  with clang, no need to rebuild everything.

	There is at least one known exception: LibreOffice.

	Some time ago I was given the lines appended to put in
make.conf.  While they are probably (and hopefully!) out-of-date, I
have had only the one problem since.  (Corrections welcome.)



					Robert Huff


#
# PORTS: use clang unless gcc is explicitly required
#

#
# default to using clang for all port builds, with the following
# exceptions

# ports which will only build with the base system GNU compiler (4.2)
#
# the "make index" target also seems to need this, for some reason

.if target(index) | \
${.CURDIR:M*/devel/antlr*} | \
${.CURDIR:M*/devel/google-perftools* } | \
${.CURDIR:M*/graphics/ImageMagick* } | \
${.CURDIR:M*/graphics/opencv*} | \
${.CURDIR:M*/www/libxul*} | \
${.CURDIR:M*/x11/kdelibs4*} | \
${.CURDIR:M*/x11-toolkits/swt-devel*}
USE_GCC?=4.2
.endif

# ports which need *some* version of the GNU compiler (won't build with
# clang or have runtime issues if built with clang)
# use the highest version of gcc we have installed from ports (4.6)

.if ${.CURDIR:M*/accessibility/jovie*} | \
${.CURDIR:M*/accessibility/kdeaccessibility4*} | \
${.CURDIR:M*/audio/grip*} | \
${.CURDIR:M*/audio/mpg123*} | \
${.CURDIR:M*/audio/rosegarden*} | \
${.CURDIR:M*/databases/virtuoso*} | \
${.CURDIR:M*/deskutils/kdepimlibs4*} | \
${.CURDIR:M*/devel/apache-ant*} | \
${.CURDIR:M*/devel/binutils*} | \
${.CURDIR:M*/devel/icu*} | \
${.CURDIR:M*/devel/kdevelop-kde4*} | \
${.CURDIR:M*/devel/kdevplatform*} | \
${.CURDIR:M*/devel/log4j*} | \
${.CURDIR:M*/games/kdegames4*} | \
${.CURDIR:M*/graphics/tonicpoint-viewer*} | \
${.CURDIR:M*/java/* } | \
${.CURDIR:M*/lang/gcc*} | \
${.CURDIR:M*/math/fftw3*} | \
${.CURDIR:M*/multimedia/avidemux2*} | \
${.CURDIR:M*/multimedia/kdemultimedia4*} | \
${.CURDIR:M*/multimedia/vlc*} | \
${.CURDIR:M*/multimedia/xbmc*} | \
${.CURDIR:M*/net/kdenetwork4*} | \
${.CURDIR:M*/net/mpich2*} | \
${.CURDIR:M*/net/opal3*} | \
${.CURDIR:M*/net-p2p/ktorrent*} | \
${.CURDIR:M*/net-p2p/vuze*} | \
${.CURDIR:M*/sysutils/lsof*} | \
${.CURDIR:M*/textproc/docbook-xsl*} | \
${.CURDIR:M*/textproc/fop*} | \
${.CURDIR:M*/www/firefox*} | \
${.CURDIR:M*/x11/kde4-baseapps*} | \
${.CURDIR:M*/x11/kde4-workspace*} | \
${.CURDIR:M*/x11/lxpanel*} | \
${.CURDIR:M*/x11-toolkits/swt*}
USE_GCC?=4.6+
.endif

.if ${.CURDIR:M*/usr/ports/*}
.if !defined(USE_GCC)
.if !defined(CC) || ${CC} == "cc"
CC=clang
.endif
.if !defined(CXX) || ${CXX} == "c++"
CXX=clang++
.endif
.if !defined(CPP) || ${CPP} == "cpp"
CPP=clang-cpp
.endif
.endif
.endif



		






Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20499.53508.240666.522994>