#!/usr/bin/ksh # IBM_PROLOG_BEGIN_TAG # This is an automatically generated prolog. # # cde720 src/cde/cde1/dtversion/dtversion 1.1 # # Licensed Materials - Property of IBM # # COPYRIGHT International Business Machines Corp. 1995 # All Rights Reserved # # US Government Users Restricted Rights - Use, duplication or # disclosure restricted by GSA ADP Schedule Contract with IBM Corp. # # IBM_PROLOG_END_TAG # @(#)68 1.1 src/cde/cde1/dtversion/dtversion, desktop, cde720 4/27/95 06:42:34 # # COMPONENT_NAME: desktop # # FUNCTIONS: none # # ORIGINS: 27 # # # (C) COPYRIGHT International Business Machines Corp. 1995 # All Rights Reserved # Licensed Materials - Property of IBM # US Government Users Restricted Rights - Use, duplication or # disclosure restricted by GSA ADP Schedule Contract with IBM Corp. # # ------------------------------------------------- # # dtversion : A utility to determine the version, release, and # modification level for the X11.Dt.rte desktop fileset. # fileset. # # format : dtversion # # ------------------------------------------------- # # Trap the output of lslpp -lc X11.Dt.rte # LSLPPOUT=`lslpp -lc X11.Dt.rte` #echo LSLPPOUT= $LSLPPOUT # # if the previous command fails to produce needed output # print appropriate message and exit with 1 # otherwise print appropriate message and continue # # if [[ $? != 0 || "$LSLPPOUT" = "" ]] then echo "**************************************************************" echo "AIX CDE desktop is not installed on this system" echo "**************************************************************" exit 1 fi # # Extract relevant information # LSLPPOUT1=${LSLPPOUT#\#*X11.Dt.rte:} #echo LSLPPOUT1= $LSLPPOUT1 VRMF=${LSLPPOUT1%%:*} #echo VRMF= $VRMF let VERSION=${VRMF%%.*} #echo VERSION= $VERSION TEMP1=${VRMF#*.} let RELEASE=${TEMP1%%.*} #echo RELEASE= $RELEASE TEMP2=${VRMF#*.*.} let MOD=${TEMP2%%.*} #echo MOD= $MOD if [[ $VERSION -gt 4 || \ ($VERSION -eq 4 && $RELEASE -gt 1) || \ ($VERSION -eq 4 && $RELEASE -eq 1 && $MOD -ge 3) ]] then echo ">=CDE1.0" exit 0 else echo "