############ Cadence software #############

setenv CADENCE /import/cadence1

setenv CDS_LIC_FILE ${CADENCE}/license/license.dat

setenv OSU_FREEPDK /import/vlsi1/osu_freepdk_1.0

setenv LD_ASSUME_KERNEL 2.4.1

#=========================================
# NCSU Setup:
#=========================================

setenv CDSHOME          /import/cadence1/IC611.500.28
setenv OA_HOME		/import/cadence1/OpenAccess2.2
setenv CNI_ROOT         /import/other/pycell411
setenv CNI_PLAT_ROOT    ${CNI_ROOT}/plat_linux_32

# New Path Entries
set newdirs = ( \
		$CDSHOME/tools/bin \
		$CDSHOME/tools/dfII/bin \
		$OA_HOME/bin \
		$CNI_PLAT_ROOT/3rd/bin \
		$CNI_PLAT_ROOT/3rd/oa/bin/linux_rhel30_32/opt \
		$CNI_PLAT_ROOT/bin \
		$CNI_ROOT/bin \
		/import/cadence1/SOC62USR2/bin \
		)

# New LD_LIBRARY_PATH Entries
set newlibs = ( \
		$CDSHOME/tools/lib \
		$OA_HOME/lib \
		$CNI_PLAT_ROOT/3rd/lib \
		$CNI_PLAT_ROOT/3rd/oa/lib/linux_rhel30_32/opt \
		$CNI_PLAT_ROOT/lib \
		)

# New Environment Variables
setenv SKIP_CDS_DIALOG
setenv CDS_Netlisting_Mode Analog
setenv PYTHONHOME $CNI_PLAT_ROOT/3rd
setenv PYTHONPATH $CNI_ROOT/pylib:$CNI_PLAT_ROOT/pyext:$CNI_PLAT_ROOT/lib:.
# The following gets rid of the annoying messages that pycell prints to stdout
setenv CNI_LOG_DEFAULT /dev/null

# END customizable section

# Extend path
foreach dir ($newdirs)
    set present = `printenv PATH | /bin/grep $dir`
    if ($present == "") then
        set path= ( $dir $path )
    endif
    unset present
end
unset dir newdirs

# Extend LD_LIBRARY_PATH
foreach dir ($newlibs)
    set present = `printenv LD_LIBRARY_PATH | /bin/grep $dir`
    if ($present == "") then
        setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:${dir}
    endif
    unset present
end
unset dir newdirs

#=========================================

source /import/other/FreePDK45/cdssetup/setup.csh

#==========================================
echo "You are now set up to use Cadence properly to use FreePDK"
#=========================================


