From 48971e5ed0ace208018b3adf8807118157b3c40d Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Fri, 23 Jan 1998 17:06:36 +0000 Subject: Cleaned up a bit. --- tools/cpu/generic/size_rtems.in | 40 +++++++++++++++++++++++++++++++--------- 1 file changed, 31 insertions(+), 9 deletions(-) (limited to 'tools/cpu') diff --git a/tools/cpu/generic/size_rtems.in b/tools/cpu/generic/size_rtems.in index 6ab8f04d92..15d14d433e 100644 --- a/tools/cpu/generic/size_rtems.in +++ b/tools/cpu/generic/size_rtems.in @@ -34,16 +34,38 @@ if [ $# -ne 1 ] ; then exit 1 fi +bsp=$1 +board=$1 + cpu=`echo $target | sed -e 's/-.*//'` -case $cpu in - hppa1.1) rtems_cpu=hppa1_1 ;; - powerpc) rtems_cpu=ppc ;; - *) rtems_cpu=$cpu ;; + +echo $target +case $target in + sparc-sun-solaris*) + rtems_cpu=unix + bsp=solaris2 + ;; + i[3456]86-pc-linux-gnu) + echo linux + rtems_cpu=unix + bsp=linux1 + ;; + *-rtems*) + cpu=`echo $target | sed -e 's/-.*//'` + case $cpu in + hppa1.1) rtems_cpu=hppa1_1 ;; + powerpc) rtems_cpu=ppc ;; + *) rtems_cpu=$cpu ;; + esac + ;; + *) + echo unknown target $target + exit 1 + ;; esac -bsp=$1 echo -echo Generating sizes for CPU ${cpu} on board ${bsp} +echo Generating sizes for CPU ${cpu} on board ${board} echo # @@ -59,8 +81,8 @@ else EOL="\\c" fi -if [ ! -d ${bsp} ] ; then - echo "${bsp} does not exist ... is the current directory the build directory?" +if [ ! -d ${board} ] ; then + echo "${board} does not exist ... is the current directory the build directory?" exit 1 fi @@ -69,7 +91,7 @@ CPUOBJ=c/src/exec/score/cpu/${rtems_cpu}/o-${bsp} COREOBJ=c/src/exec/score/src/o-${bsp} RTEMSOBJ=c/src/exec/rtems/src/o-${bsp} SAPIOBJ=c/src/exec/sapi/src/o-${bsp} -OPTOBJ=${bsp}/lib +OPTOBJ=${board}/lib MANLIST=" \ ${RTEMSOBJ}/clock.o \ -- cgit v1.2.3