plan9port/bin/9l
2003-11-25 02:11:11 +00:00

18 lines
331 B
Bash
Executable file

#!/bin/sh
extralibs=-lm
tag="`uname`-`uname -m`"
case "$tag" in
*FreeBSD*) ld=gcc ;;
*BSD*) ld=gcc ;;
*Linux*) ld=gcc ;;
*Darwin*) ld=gcc ;;
*SunOS*) ld="${CC9:-cc} -g"
extralibs="$extralibs -lrt -lpthread -lsocket -lnsl"
;;
*)
echo do not know how to link on "$tag" 1>&2
exit 1
esac
exec $ld -L$PLAN9/lib "$@" $extralibs