On 9/17/2017 8:30 PM, Öö Tiib wrote:
> On Sunday, 17 September 2017 05:32:36 UTC+3,
pedr...@lycos.com wrote:
>> I have some package, that builds find with old gcc/g++ 4.4 and 4.8 (working with
>> enterprise linux). I had a go with a distro that has newer gcc 7.2
>> All went fine except a heap of errors related to stl_algobase.hh such as:
>>
>> /usr/include/c++/7/bits/stl_algobase.h:243:56: error: macro "min" passed 3 arguments, but takes just 2
>> min(const _Tp& __a, const _Tp& __b, _Compare __comp)
>>
>> the chain of includes leading up to this is:
>> In file included from /usr/include/c++/7/bits/char_traits.h:39:0,
>> from /usr/include/c++/7/ios:40,
>> from /usr/include/c++/7/ostream:38,
>> from /usr/include/c++/7/iostream:39,
>>
>> so something has changed since the ancient versions I used before.
>>
>> Trying various compiler flags -std=c++98 or gnu++98 helps not.
>
> Somehow the authors of your package have managed to do same stupid
> thing that Microsoft did. Microsoft did so that the windows.h declared
> macros named "min" and "max" and so standard library did not work.