You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "James E. King, III (JIRA)" <ji...@apache.org> on 2017/10/05 03:26:00 UTC

[jira] [Reopened] (THRIFT-4109) Configure Script uses string comparison for versions

     [ https://issues.apache.org/jira/browse/THRIFT-4109?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James E. King, III reopened THRIFT-4109:
----------------------------------------

Reopening so I can edit it.

> Configure Script uses string comparison for versions
> ----------------------------------------------------
>
>                 Key: THRIFT-4109
>                 URL: https://issues.apache.org/jira/browse/THRIFT-4109
>             Project: Thrift
>          Issue Type: Bug
>          Components: Build Process
>    Affects Versions: 0.10.0
>            Reporter: Devin Avery
>            Assignee: James E. King, III
>             Fix For: 0.11.0
>
>
> I am running the configure script as outlined here for MAC OSx -
> http://thrift.apache.org/docs/install/os_x
> I found that the configure script is doing string based comparison for
> performing version verification which breaks as soon as a version changes from one digit to two. For example, homebrew installs ant version 1.10.x now (as of March 7th, 2017) which is clearly greater than 1.7 which thrift requires. However the thrift configure script fails to detect ant because it thinks the version is wrong.
> This is because this line in the configure script (around line 18844 in
> version 0.9.3) - 
> {code}
> ANT_VALID=expr $($ANT -version 2>/dev/null | sed -n 's/.*version \([0-9\.]*\).*/\1/p') \>= 1.7`
> {code}
> Notice how you are using the >= which is STRING comparison, not version
> comparison. When 1.10.1 compares to 1.7 it is considered LESS than instead
> of greater than.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)