Opened 9 years ago
Closed 9 years ago
#5865 closed defect (fixed)
[PATCH] Remove bashism introduced into configure by changeset 28265
Reported by: | tvrusso | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | default | Version: | svn-trunk |
Severity: | normal | Keywords: | |
Cc: |
Description
The commit in changeset 28265 introduced a bash-specific construct into configure.in that breaks it on operating systems where "/bin/sh" is the Bourne shell, not Bash (FreeBSD is such an example).
The specific problematic construct is:
ecw_license_types=( "Desktop_Read-Write" "Server_Read-Only_EndUser" "Server_Read-Only" "Server_Read-Write" "Desktop_Read-Only" ) for ecw_license_type in ${ecw_license_types@<:@@@:>@};
This the assignment of a list to a shell variable is not accepted in the Bourne shell, and causes the error message:
./configure: 22882: Syntax error: word unexpected (expecting ")")
Specifying the list directly on the "for" line fixes the incompatibility, rendering configure portable to systems where /bin/sh is not an alias for bash.
for ecw_license_type in "Desktop_Read-Write" "Server_Read-Only_EndUser" "Server_Read-Only" "Server_Read-Write" "Desktop_Read-Only"
Attachments (1)
Change History (3)
by , 9 years ago
Attachment: | gdalpatch_configure added |
---|
comment:1 by , 9 years ago
Summary: | Bashism introduced into configure by changeset 28265 → [PATCH] Remove bashism introduced into configure by changeset 28265 |
---|
comment:2 by , 9 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Patch to remove bashism from configure.