#! /bin/sh

binlinks="b2m bringover codemgr codemgrtool debugger def.dir.flp \
	eserve etags filemerge freezept freezepttool gcmonitor \
	gnuattach gnuclient gnudoit gvim hbvi.4 install-sid \
	makeprd maketool memdb nc nedit \
	pstogif putback rcs-checkin rcs2ws resolve sbrowser \
	send-pr showWarning teamware twbuild twconfig twfreeze \
	twmerge twversion vertool workspace ws_undo \
	xemacs xemacs-20.4 xemacs-20.4-mule xemacs-ctags xemacs-mule"

WS6U2binlinks="bil2xd gil2xd small_visu uil2xd \
	visu visu_capture visu_config visu_help visu_record \
	visu_replay visuroot visutosj"
	
modified="false"

# create symlink path to Nozomi installation for use in "workshop" script
if [ ! -h ${BASEDIR}/SUNWspro/bin/.fd6u2path ]; then
   installf ${PKGINST} ${BASEDIR}/SUNWspro/bin/.fd6u2path=${FD6U2PATH} s
   modified="true"
fi

# create symlinks in FD7 pointing to stuff in FD6u2
for F in ${binlinks}; do
   if [ ! -h ${BASEDIR}/SUNWspro/bin/$F ]; then
      installf ${PKGINST} ${BASEDIR}/SUNWspro/bin/$F=.fd6u2path/bin/$F s
      modified="true"
   fi 
done
for F in ${WS6U2binlinks}; do
   if [ ! -h ${BASEDIR}/SUNWspro/bin/$F ]; then
      installf ${PKGINST} ${BASEDIR}/SUNWspro/bin/$F=.fd6u2path/WS6U2/bin/$F s
      modified="true"
   fi 
done

# Finish the job; really create the symlinks
if [ "X$modified" = "Xtrue" ]; then
   installf -f ${PKGINST}
fi
