1 # $NetBSD: mkconf,v 1.1.1.1 1997/07/24 21:20:12 christos Exp $
4 # Generate local configuration parameters for amd
8 eval `LC_ALL=C egrep '^[A-Z]+=' $1 | grep -v COPYRIGHT`
9 OS=`echo ${TYPE} | LC_ALL=C tr 'A-Z' 'a-z'`
10 echo '/* Define name and version of host machine (eg. solaris2.5.1) */'
11 echo "#define HOST_OS \"${OS}${REVISION}\""
12 echo '/* Define only name of host machine OS (eg. solaris2) */'
13 echo "#define HOST_OS_NAME \"${OS}${REVISION}\"" \
14 | sed -e 's/\.[-._0-9]*//'
15 echo '/* Define only version of host machine (eg. 2.5.1) */'
16 echo "#define HOST_OS_VERSION \"${REVISION}\""
18 cat << __NO_newvers_sh
20 /* Define name and version of host machine (eg. solaris2.5.1) */
21 #define HOST_OS "`uname -s | LC_ALL=C tr 'A-Z' 'a-z'``uname -r`"
23 /* Define only name of host machine OS (eg. solaris2) */
24 #define HOST_OS_NAME "`uname -s | LC_ALL=C tr 'A-Z' 'a-z'``uname -r | sed -e 's/\..*$//'`"
26 /* Define only version of host machine (eg. 2.5.1) */
27 #define HOST_OS_VERSION "`uname -r | sed -e 's/[-([:alpha:]].*//'`"