xref: /csrg-svn/local/toolchest/ksh/sh/makelib (revision 35153)
1*35153SmarcCMD=${CMD-/bin/make}
2*35153SmarcARK=${ARK-libedit.a}
3*35153Smarc#
4*35153Smarc# This script will make various version of editlib for different machines
5*35153Smarc#
6*35153Smarccommand=$1
7*35153SmarcU370= DBSD= VIRAW= SYSCALL=
8*35153Smarcif	test -f /vmunix -o "$SYSTYPE" = bsd4.1 -o "$SYSTYPE" = bsd4.2 # true for BSD unix
9*35153Smarcthen	DBSD=-DBSD
10*35153Smarcfi
11*35153Smarcif	test -f /bin/u3b && /bin/u3b
12*35153Smarcthen	SYSCALL=syscall.o
13*35153Smarcfi
14*35153Smarcif	uname -m 2> /dev/null > /dev/null
15*35153Smarcthen	set -- `uname -m`
16*35153Smarc	case "$1" in
17*35153Smarc	*370)
18*35153Smarc		U370=U370 VIRAW='-DRAWONLY'
19*35153Smarc		;;
20*35153Smarc	ibm-pc*)
21*35153Smarc		VIRAW='-DRAWONLY'
22*35153Smarc		;;
23*35153Smarc	esac
24*35153Smarcfi
25*35153Smarcset -- `uname -r`
26*35153Smarccase "$1" in
27*35153Smarc*[23].*)
28*35153Smarc	VIRAW='-DRAWONLY'
29*35153Smarc	;;
30*35153Smarcesac
31*35153Smarc$CMD -f Makefile DBSD=$DBSD U370=$U370 VIRAW=$VIRAW SYSCALL=$SYSCALL $command
32