Blacklisting gcc

Ryan Schmidt ryandesign at macports.org
Tue Mar 27 06:31:35 UTC 2018


> On Mar 26, 2018, at 01:25, Mojca Miklavec wrote:
>> On 26 March 2018 at 02:49, Ryan Schmidt wrote:
>>> On Mar 25, 2018, at 14:37, David B. Evans wrote:
>>> 
>>>> +# blacklist compilers that do not support C11 (redefinition of typedef ‘GtkSourceTag’ at gtksourceview/gtksourcetag.h:35)
>>>> +compiler.blacklist  *gcc* {clang < 300}
>>> 
>>> Please be more specific here, such as "*gcc-3.* *gcc-4.*". Newer versions of gcc do support C11, and a change was already committed to MacPorts base which will let PowerPC systems fall back to gcc6 instead of clang (since clang doesn't work on PowerPC). Other ports may need more-specific blacklists too.
>> 
>> Is there any chance to implement something like
>>   compiler.blacklist {gcc < 4.7} {macports-clang < 3.7}
>> ?

There is no code currently written that would allow that to work. If we were to add code to the compilers_blacklist_versions for that, how should it work?

Currently, the above line would mean "blacklist versions of the compiler named 'gcc' that are earlier than 4.7" and "blacklist versions of the compiler named 'macports-clang' that are earlier than 3.7". There are no compilers in MacPorts named "gcc" or "macports-clang" so these statements would currently have no effect. Are you proposing that the names "gcc" and "macports-clang" be special-cased in the portgroup, and taken to mean "the set of ports whose names start with 'gcc'" (or maybe even "...whose names contain 'gcc'"?) and "the set of ports whose names start with 'macports-clang'"? That's a plausible solution, I'm just pointing out that it would be special-case code.


On Mar 26, 2018, at 09:18, Ken Cunningham wrote:

> I think blacklisting *gcc-4* would achieve the desired goal.

*gcc-4.* is more correct.

> gcc-3.x is no longer a compiler macports puts forward for use, so can be ignored now.

A stable version of MacPorts containing that change has not yet been released. Until it is, *gcc-3.* will have to be blacklisted as well, if its use is not desired.




More information about the macports-dev mailing list