svn commit: r285284 - head/lib/liblzma
Warner Losh
imp at bsdimp.com
Wed Jul 8 22:32:04 UTC 2015
Not in this context, no. Nor should you want to in this context (inside the compiling module).
Generally in Makefiles it would be a bad idea too, but there’s sometimes you need to know.
But there’s currently not any such instances in the tree.
Warner
> On Jul 8, 2015, at 4:04 PM, Adrian Chadd <adrian.chadd at gmail.com> wrote:
>
> Is there a blessed way to see whether the compiler we're using is an
> external compiler, or an internal one?
>
> eg, the version check isn't enough - it's just a number. how do I know
> if it's freebsd clang versus upstream clang?
> (Or in my instance, freebsd-gcc versus upstream-gcc.)
>
>
> -a
>
>
> On 8 July 2015 at 14:09, Pedro Giffuni <pfg at freebsd.org> wrote:
>>
>>
>> On 07/08/15 13:36, Luigi Rizzo wrote:
>>>
>>> Author: luigi
>>> Date: Wed Jul 8 18:36:37 2015
>>> New Revision: 285284
>>> URL: https://svnweb.freebsd.org/changeset/base/285284
>>>
>>> Log:
>>> only enable immintrin when clang is used. The base gcc does not support
>>> it.
>>> Reviewed by: delphij
>>>
>>> Modified:
>>> head/lib/liblzma/config.h
>>>
>>> Modified: head/lib/liblzma/config.h
>>>
>>> ==============================================================================
>>> --- head/lib/liblzma/config.h Wed Jul 8 18:12:24 2015 (r285283)
>>> +++ head/lib/liblzma/config.h Wed Jul 8 18:36:37 2015 (r285284)
>>> @@ -150,7 +150,8 @@
>>> #define HAVE_ICONV 1
>>> /* Define to 1 if you have the <immintrin.h> header file. */
>>> -#if defined(__FreeBSD__) && defined(__amd64__)
>>> +/* FreeBSD - only with clang because the base gcc does not support it */
>>> +#if defined(__clang__) && defined(__FreeBSD__) && defined(__amd64__)
>>> #define HAVE_IMMINTRIN_H 1
>>> #endif
>>>
>>
>> FWIW, gcc 4.3+ does have it so this may some undesired (but hidden)
>> effect when building with an external gcc.
>>
>> Pedro.
>>
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freebsd.org/pipermail/svn-src-all/attachments/20150708/bec08340/attachment.bin>
More information about the svn-src-all
mailing list