Date: Wed, 8 Jul 2015 16:31:58 -0600 From: Warner Losh <imp@bsdimp.com> To: Adrian Chadd <adrian.chadd@gmail.com> Cc: Pedro Giffuni <pfg@freebsd.org>, Luigi Rizzo <luigi@freebsd.org>, "src-committers@freebsd.org" <src-committers@freebsd.org>, "svn-src-all@freebsd.org" <svn-src-all@freebsd.org>, "svn-src-head@freebsd.org" <svn-src-head@freebsd.org> Subject: Re: svn commit: r285284 - head/lib/liblzma Message-ID: <95059F59-AE24-42A3-A43B-5B08903B68E2@bsdimp.com> In-Reply-To: <CAJ-Vmo=m0Y%2BE0oi5ec5RzyziqObOj=fKY1K-8HzqK8x7D_TcKg@mail.gmail.com> References: <201507081836.t68IacJu069563@repo.freebsd.org> <559D9172.9040305@FreeBSD.org> <CAJ-Vmo=m0Y%2BE0oi5ec5RzyziqObOj=fKY1K-8HzqK8x7D_TcKg@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --] 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@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@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. >> > [-- Attachment #2 --] -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJVnaTeAAoJEGwc0Sh9sBEAL18QAJLSYP+nWC34q6dYxJ6Nh+r6 ziy1atDiTdKcQgf5ldqO+LSfmf2FP1+bzjpwtZEFtUbqwUCOL/3GK1WWmgTWlp3A 07BXlud3/9YeC4o71b86uUWerjGbHLqYWjBaMJTNsQqM3uYC4jYukcpTnGTKCAOv nRtc0HJr8iYgL5zT6MxjdLxm0eq5gNxMGPaZvc9xqQQsW8QQEFigxSaOo4ZzqoQl 3sSw4yzOOPQaFJ5ES8RSDki7NzBx2WwXaMy2RGeXXZ9P48M55RLdVzlFIAupYXgv 6vCCEWS8IX9OyZZE6T2B+8Hghawukc9qBbzt0IsIDDwEd1XYfJFy8sXnPdAX+2Wt J5ivNpM0SRL9fBa/627Iwz0bKa2BDqWbdAbMO0SAATVb1Rnx6jy3Bn5KB6AMdLlW liMlvqPC2yPzVD0czqIK/dSkT8DnzlFb5HpQSf6id1eqWS9EjdPDtwq309y+1hDS uFQ2ofAQcKF+aQwCoS6c2T0AmuVgZc4nbPbhU7v1Xr/fv4S5V14MfXluGAwjWFlW tfdwy/7oQZ5ZqScrmthiyYSSQU7Wx+fDsikCaDaa34v9v7SMk2SfcqNwglRoNlnN izUasKHbfuh39JE6zD0hBtveuL1uDYY3g8c8A17FCL1FJdcm6HvjD7VcAk3TuOiL CoW3ZGxTr+zzrLcCk67f =5JOb -----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?95059F59-AE24-42A3-A43B-5B08903B68E2>
