https://github.com/teuben/nemo
Raw File
Tip revision: d0f673bdaeabe8dffa77528c13d81063a20d29f6 authored by Peter Teuben on 03 April 2024, 01:39:10 UTC
format
Tip revision: d0f673b
nemo_start.sh.in
#! /bin/sh
#
#   nemo_start.sh:   source this script to enable your NEMO environment
#
#   @WARNING@
#
#   source this file to start NEMO; the csh counterpart has some commented 
#   lines, which you can place in your personal 
#            ~/.nemo_local.sh 
#   or site installation
#            $NEMO/nemo_local.sh
#   
#   BASH interactive shell uses ~/.bashrc     
#        login shell       uses ~/.bash_login (or .bash_profile)
#   Note Linux uses the interactive shell, Mac uses the login shell
#   ZSH users should also be able to use this file.
#
#                                       Things via configure
export          NEMO=@NEMO@
export      NEMOHOST=@NEMOHOST@

#  				        Basic derived environment variables
export NEMOLIB=$NEMO/lib
export NEMOBIN=$NEMO/bin
export NEMOOBJ=$NEMO/obj
export NEMODOC=$NEMO/man/doc
export NEMODAT=$NEMO/data
export NEMOINC=$NEMO/inc
export NEMOSRC=$NEMO/src
export BTRPATH=.:$NEMO/obj/bodytrans
export POTPATH=.:$NEMO/obj/potential:$NEMO/obj/acc
export ACCPATH=.:$NEMO/obj/potential:$NEMO/obj/acc
export MANIPPATH=.:$NEMO/obj/manip:$NEMO/usr/dehnen/falcON/manip
export NEMOVER=`cat $NEMO/VERSION`
export NEMOSYS=`uname -s`
export NEMOSITE=`hostname`

export YAPP=@YAPP_DEF@
export PGPLOT_DIR=@PGPLOT_DIR@


if [ -z "$MANPATH" ]; then
  export MANPATH=$NEMO/man:$(manpath)
else
  export MANPATH=$NEMO/man:$MANPATH
fi
# $NEMO/usr/dehnen/falcON/ was manually merged into $NEMO/man


#  If you use the VoGL library for xyzview, this is the only reasonable default
export VDEVICE=X11

if [ 1 ]; then
  if [ -z "$PKG_CONFIG_PATH" ]; then
    export PKG_CONFIG_PATH=$NEMO/opt/lib/pkgconfig
  else
    export PKG_CONFIG_PATH=$NEMO/opt/lib/pkgconfig:$PKG_CONFIG_PATH
  fi
  if [ -z "$LD_LIBRARY_PATH" ]; then
    export LD_LIBRARY_PATH=$NEMOLIB:$NEMO/opt/lib
  else
    export LD_LIBRARY_PATH=$NEMOLIB:$NEMO/opt/lib:$LD_LIBRARY_PATH
  fi
  # if ("$PGPLOT_DIR" != "$NEMOLIB") then

  # Hack for Mac, i guess it won't hurt on linux
  # on Mac here's another problem:  might need to use DYLD_INSERT_LIBRARIES
  # similar to the LD_PRELOAD on linux.  This might be needed for
  # libunsio.{dylib,so} is a case where this was needed
  if [ -z "$DYLD_LIBRARY_PATH" ]; then
    export DYLD_LIBRARY_PATH=$LD_LIBRARY_PATH:$NEMO/opt/lib
  else
    export DYLD_LIBRARY_PATH=$LD_LIBRARY_PATH:$NEMO/opt/lib:$DYLD_LIBRARY_PATH
  fi
fi

# for unsio 1.0.0: $NEMO/py/modules
if [ -z "$PYTHONPATH" ]; then
  export PYTHONPATH=$NEMO/py/modules
else
  export PYTHONPATH=$NEMO/py/modules:$PYTHONPATH
fi


# ZENO has no bash support yet
test -f $NEMO/usr/zeno/ZENORC   &&     echo "No ZENO support for bash yet"

test -f $NEMO/nemo_local.sh     &&     source $NEMO/nemo_local.sh
test -f $HOME/.nemo_local.sh    &&     source $HOME/.nemo_local.sh

# optional python (anaconda3 should win)
test -f $NEMO/python_start.sh             &&     source $NEMO/python_start.sh
test -f $NEMO/anaconda3/python_start.sh   &&     source $NEMO/anaconda3/python_start.sh


# optional dot check?
export PATH=$NEMOBIN:$NEMO/opt/bin:$PATH

# falcON 
export FALCON=$NEMO/usr/dehnen/falcON
source $FALCON/falcON_start.sh

# aliases
alias ni=nemoinp
back to top