Subject: Re: Processor types and uname data on AIX (proposed change)
To: None <tech-pkg@netbsd.org>
From: Peter Schmiedeskamp <pschmied@yahoo.com>
List: tech-pkg
Date: 05/07/2004 13:02:13
O.K.  Patching machine.sh turned out to be easier than
I had anticipated.

--- machine.orig        Fri May  7 12:26:29 2004
+++ machine.sh  Fri May  7 12:27:08 2004
@@ -66,11 +66,23 @@
        OSREL=`uname -v`
        OSMAJOR=`IFS=.; set $OSREL; echo $1`
        ;;
+AIX)
+       OSMAJOR=`uname -v`
+       OSMINOR=`uname -r`
+       MACHINE=$OS$OSMAJOR.$OSMINOR
+       case "$OSMAJOR" in
+       4)
+               MACHINE_ARCH=`bootinfo -T`
+               ;;
+       5)
+               MACHINE_ARCH=`uname -p`
+               ;;
+       esac
+       ;;
 esac
 
 MACHINE=${MACHINE:-$OS$OSMAJOR}
 MACHINE_ARCH=${MACHINE_ARCH:-$machine}
-
 
 (
 case "$0" in


This results in the following:
root@foo:/usr/pkgsrc/devel/patch $
/usr/pkgsrc/bootstrap/bmake/machine.sh
aix5.1

root@bar:/home/root $
/usr/pkgsrc/bootstrap/bmake/machine.sh 
aix4.3

Let me know if that works for everyone.  One potential
downside is that the platform naming conventions will
be different between 4.x and 5.x (i.e. rspc vs.
powerpc).

Now I can take binary packages back and forth between
my similar 5.1 machines. (Yay!)

-Peter


	
		
__________________________________
Do you Yahoo!?
Win a $20,000 Career Makeover at Yahoo! HotJobs  
http://hotjobs.sweepstakes.yahoo.com/careermakeover