attach -q telnet
set srcdir=/mit/telnet/src
set blddir=/usr/tmp/$USER/telnet94

# make build directory
mkdirhier $blddir
/usr/athena/etc/synctree -q -s $srcdir -d $blddir
pushd $blddir

# create Makefiles with Imake
if (-r /usr/athena/config/Imake.tmpl) then
        # 90% of the time it's this easy....
        xmkmf /usr/athena
else
        if (-r /source/support/config/cf/Imake.tmpl) then
                # Athena SGI March '95
                imake -I/source/support/config/cf -DTOPDIR=/source
        else
                attach -q source
                xmkmf /source
        endif
endif

# build
make Makefiles all |& tee all.log
