Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 24 Aug 2012 15:20:15 +0200
From:      Dimitry Andric <dimitry@andric.com>
To:        fluffy@FreeBSD.org
Cc:        Dima Panov <fluffy@fluffy.khv.ru>, current@freebsd.org
Subject:   Re: build error at rpc code
Message-ID:  <50377F8F.8000005@andric.com>
In-Reply-To: <50377C8A.40000@fluffy.khv.ru>
References:  <5036FB4E.4080407@fluffy.khv.ru> <50373763.50608@andric.com> <50377C8A.40000@fluffy.khv.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2012-08-24 15:07, Dima Panov wrote:
> 24.08.2012 19:12, Dimitry Andric =D0=BF=D0=B8=D1=88=D0=B5=D1=82:
=2E..
>> You are most likely setting CPP as follows:
>>
>>    CPP=3Dclang -E
>>
>> Don't do that, use the following instead:
>>
>>    CPP=3Dclang-cpp
>>
>> If there is no clang-cpp symlink in /usr/bin yet, just make it manuall=
y
>> for now.  It will also be created by installworld.
>
> Oh, indeed. Thanks for advice.
> However, why such different results in preprocessor invocation style?

When you invoke either clang or gcc with -E, files with unknown
extensions are not preprocessed, and considered to be linker input
files.

When you invoke clang-cpp or cpp, files with unknown extensions are
considered to be C instead.

Since our RPC-related files use the .x extension, -E doesn't work as
expected, and the resulting files will give a compile error later on.




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