diff options
author | midipix <writeonce@midipix.org> | 2019-01-01 01:04:21 -0500 |
---|---|---|
committer | midipix <writeonce@midipix.org> | 2019-01-01 01:07:41 -0500 |
commit | 185910e2d271b5b20e992951c5e3a9d1aef87c93 (patch) | |
tree | 4c53dcd929b86813098cd8301e2252052fdaaa51 /sofort/ccenv | |
parent | 3cdb2f52a3517a7a5ef5943faccb47399d4b8ff2 (diff) | |
download | slibtool-185910e2d271b5b20e992951c5e3a9d1aef87c93.tar.bz2 slibtool-185910e2d271b5b20e992951c5e3a9d1aef87c93.tar.xz |
build system: ccenv: refined the os detection logic.
Diffstat (limited to 'sofort/ccenv')
-rw-r--r-- | sofort/ccenv/ccenv.sh | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/sofort/ccenv/ccenv.sh b/sofort/ccenv/ccenv.sh index 31b7dd5..c786f90 100644 --- a/sofort/ccenv/ccenv.sh +++ b/sofort/ccenv/ccenv.sh @@ -700,14 +700,19 @@ ccenv_set_os() case "$ccenv_cchost" in *-*-*-* ) - ccenv_tip=${ccenv_host%-*} + ccenv_tip=${ccenv_cchost%-*} ccenv_os=${ccenv_tip#*-*-} ;; - - *-*-* ) - ccenv_tip=${ccenv_host%-*} + *-*-musl | *-*-gnu ) + ccenv_tip=${ccenv_cchost%-*} ccenv_os=${ccenv_tip#*-} ;; + *-*-* ) + ccenv_os=${ccenv_cchost#*-*-} + ;; + *-* ) + ccenv_os=${ccenv_cchost#*-} + ;; esac if [ -z "$ccenv_os" ]; then |