-
Notifications
You must be signed in to change notification settings - Fork 60
Incorrect comparison of version number on Darwin #440
Copy link
Copy link
Closed
Description
Hi,
In src/tools/darwin.jam, there's the following code:
# - GCC 4.0 and higher in Darwin does not have -fcoalesce-templates.
if $(real-version) < "4.0.0"
{
flags darwin.compile.c++ OPTIONS $(condition) : -fcoalesce-templates ;
}
This adds a command-line flag only when the version of the compiler is less than "4.0.0". Now, I don't know much about BJam, however this seems to be doing a simple lexicographical comparison, not a version-like comparison of the strings. As a result, the version string "10.0.0" (for example) ends up comparing less than "4.0.0", and we (incorrectly) add the flag.
I believe that comparison (and the subsequent comparisons too) should be using a version-like comparison function, but I don't know whether that exists in BJam.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels