2015-10-02 21:12:35 +02:00
|
|
|
#! /bin/sh
|
|
|
|
#
|
|
|
|
# $Id: guess_port 1825 2013-02-26 09:39:47Z viari $
|
|
|
|
#
|
|
|
|
# @file: guess_port
|
|
|
|
# @desc: attempt to guess the portname
|
|
|
|
# @usage: guess_port
|
|
|
|
#
|
|
|
|
# @history:
|
|
|
|
# @+ <Gloup> Nov. 2000 first draft adapted from GNU config.guess
|
|
|
|
# @+ <Gloup> Feb. 2010 moved to sh
|
|
|
|
#
|
|
|
|
|
|
|
|
mach=`uname -m`
|
|
|
|
syst=`uname -s`
|
|
|
|
rels=`uname -r`
|
|
|
|
|
|
|
|
case ${mach}:${syst}:${rels} in
|
|
|
|
|
|
|
|
alpha:OSF1:* ) echo alpha-osf1;;
|
|
|
|
sun4*:SunOS:5.* ) echo sparc-solaris;;
|
|
|
|
i86pc:SunOS:5.* ) echo i386-solaris;;
|
|
|
|
sun4*:SunOS:* ) echo sparc-sunos;;
|
|
|
|
Power*:Darwin:* ) echo ppc-darwin;;
|
|
|
|
i*86:Linux:* ) echo i386-linux;;
|
|
|
|
x*86*:Linux:* ) echo i386-linux;;
|
|
|
|
i*86:Darwin:* ) echo i386-darwin;;
|
2015-10-02 21:44:13 +02:00
|
|
|
x*86*:Darwin:* ) echo i386-darwin;;
|
2023-05-11 14:29:43 +02:00
|
|
|
arm64:Darwin:* ) echo arm64-darwin;;
|
2015-10-02 21:12:35 +02:00
|
|
|
IP*:IRIX*:* ) echo mips-irix;;
|
|
|
|
i*86:MINGW32*:* ) echo x86-mingw32;;
|
|
|
|
|
|
|
|
*) echo unknown ${mach}:${syst}:${rels}; exit 1;;
|
|
|
|
esac
|
|
|
|
exit 0
|