Files
annotate/config/guess_port
Eric Coissac 3d9be22e1d Small changes
Former-commit-id: bf83f19efe2590803c089697858590aee4720089
Former-commit-id: e7d0bae099d6449b97c431f7ba82568f45bcc005
2023-05-11 14:29:43 +02:00

36 lines
932 B
Bash
Executable File

#! /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;;
x*86*:Darwin:* ) echo i386-darwin;;
arm64:Darwin:* ) echo arm64-darwin;;
IP*:IRIX*:* ) echo mips-irix;;
i*86:MINGW32*:* ) echo x86-mingw32;;
*) echo unknown ${mach}:${syst}:${rels}; exit 1;;
esac
exit 0