Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 14 Jun 2010 18:17:06 +0400
From:      Anonymous <swell.k@gmail.com>
To:        Alexander Best <alexbestms@uni-muenster.de>
Cc:        freebsd-current@freebsd.org
Subject:   Re: two buildworld problems
Message-ID:  <86y6ehsnq5.fsf@gmail.com>
In-Reply-To: <AANLkTile6CNUPNg-LHbiblge9ADpKShy1OMFPCTGcsb2@mail.gmail.com> (Alexander Best's message of "Mon, 14 Jun 2010 12:44:46 %2B0200")
References:  <AANLkTinchxOQRJ8qsfS1VDcnALSi1L06dl8W4GMSj20b@mail.gmail.com> <20100614100500.GA35142@freebsd.org> <AANLkTile6CNUPNg-LHbiblge9ADpKShy1OMFPCTGcsb2@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Alexander Best <alexbestms@uni-muenster.de> writes:

> On Mon, Jun 14, 2010 at 12:05 PM, Roman Divacky <rdivacky@freebsd.org> wrote:
>> On Sun, Jun 13, 2010 at 10:28:23PM +0200, Alexander Best wrote:
>>> hi there. i'm experiencing two problems during buildworld. i'm not
>>> sure if these are the result of me doing weird stuff or a problem in
>>> the src structure:
>>>
>>> 1. i have the following in my make.conf:
>>>
>>> .if empty(.CURDIR:M/usr/src/*) && empty(.CURDIR:M/usr/obj/*) &&
>>> exists(/usr/local/bin/gcc44)
>>> CC = gcc44
>>> CXX = g++44
>>> CPP = cpp44
>>> .endif
>>
>> you may want to reverse the condition, ie.
>>
>> .if !empty(.CURDIR:M/usr/ports/*)
>
> yeah i had something like that in my make.conf beforehand. the problem
> was however that this would only use gcc44 when 'make' was run in the
> ports directory. however i want make to ALWAYS use gcc44 apart from
> /usr/src.

It may be easier to make gcc44 symlinks for cc/c++/gcc/g++ in
e.g. HOME/.bin and add it to PATH before /usr/bin[1]. make buildworld
overrides its own PATH and shouldn't be affected but pretty much
anything else will use gcc44, not only make(1) targets.

You can create basegcc/baseg++ symlinks then for things that don't
compile by gcc44 but in case of portmaster you'd have to teach it
respect user-defined PATH in order for CC=basegcc in make.conf to work.

[1] *after* ccache if you have it installed, e.g.
    PATH=$LOCALBASE/libexec/ccache:$HOME/.bin:...:/usr/bin:...



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