Skip to content
This repository was archived by the owner on Sep 18, 2021. It is now read-only.
This repository was archived by the owner on Sep 18, 2021. It is now read-only.

Compare Ant version used expr command , maybe is a wrong way. #1

@gimlyu

Description

@gimlyu

execute ./configure output

Building Java Library ........ : no

javac,java ,ant command available, and the ant version is 1.10.1 (bottled)
use vim open configure file and find the code at 18844 line is :

ANT_VALID=expr $($ANT -version 2>/dev/null | sed -n 's/.*version \([0-9\.]*\).*/\1/p') \>= 1.7

Maybe use expr command comparing version is inadvisable.

test :

➜ a=expr 1.10.1 \>= 1.8
➜ echo $a
0
➜ a=expr 1.10.1 \>= 1.0
➜ echo $a
1

It is a bug ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions