[x265] [PATCH] cmake: switch to c++11 for Clang and GCC

Mateusz Brzostek mateusz at msystem.waw.pl
Wed Apr 26 12:27:05 CEST 2017


I will make speed test -std=c++11 vs. -std=gnu++11 (in the night) and if x265 build with GCC -std=c++11 is not slower than with -std=gnu++11 I will be convinced to -std=c++11.


W dniu 2017-04-26 o 08:07, Michael Lackner pisze:
> Actually, I compiled x265 2.4+2 just yesterday using GCC 6.2.0 on Linux, and I had it set
> to '-std=c++11'. It compiled and ran just fine doing a quick test run with some 1080p content.
>
> On a side note: Also worked just fine with clang/llvm 3.9.1 on FreeBSD 10.3 UNIX,
> currently encoding 4K/UHD stuff.
>
> On 04/25/2017 04:43 PM, Stephen Hutchinson wrote:
>> On 4/25/2017 4:25 AM, Mateusz Brzostek wrote:
>>> After tests with GCC from 4.8 to 8.0 I think it is OK to change to c++11 from c++98 (for
>>> -DENABLE_DYNAMIC_HDR10=ON and OFF).
>>>
>>> Selur (Hybrid author) wrote that for Clang it should be c++11 instead of gnu++11, so we
>>> can set for Clang c++11, for GCC gnu++11.
>>>
>>> Please review.
>>>
>> Something that's been on my mind since the discussion around
>> the -std= being set started is: is x265 even using the GNU
>> extensions that require setting gnu++* variants as the -std?
>> Or is it just being set like that because it's GCC?
>>
>> If GCC-specific stuff isn't being used, or if Clang is tolerant
>> enough of any GNU extensions that are used, you could just set
>> it as -std=c++11 for both Clang and GCC and not have to branch.



More information about the x265-devel mailing list