Skip to content
Snippets Groups Projects
Commit f7a0636f authored by Christoph Knote's avatar Christoph Knote
Browse files

Remove boxmox_path for now

parent 1e29c0bf
No related branches found
No related tags found
No related merge requests found
......@@ -9,6 +9,10 @@ doc/boxmox*aux
doc/boxmox*log
doc/boxmox*pdf
src/bison.c
src/bison.h
src/yacc.c
**~
# bc we create this automatically using build_dist.sh
......
......@@ -39,6 +39,12 @@ dist_bin_SCRIPTS = scripts/list_BOXMOX_mechanisms \
scripts/prepare_BOXMOX_mechanism \
scripts/validate_BOXMOX_installation
install-data-local:
$(MKDIR_P) $(DESTDIR)$(pkgdatadir)/compiled_mechs
uninstall-local:
rmdir $(DESTDIR)$(pkgdatadir)/compiled_mechs 2>/dev/null || :
all-local:
@echo " "
@echo " --- YOU ARE GOOD TO GO ---"
......@@ -47,7 +53,7 @@ all-local:
@echo "your .bashrc, .profile (a hidden file in your home directory)"
@echo "or similar, so they are executed upon login:"
@echo " "
@echo "export KPP_HOME=${prefix}"
@echo "export PATH=\$$KPP_HOME/bin:\$$KPP_HOME/boxmox/bin:\$$PATH"
@echo "export KPP_HOME=${prefix}/share/boxmox"
@echo "export PATH=${prefix}/bin:\$$PATH"
@echo " "
......@@ -8,6 +8,7 @@ AM_INIT_AUTOMAKE([-Wall foreign tar-pax])
AC_PROG_CC
AC_PROG_LEX(noyywrap)
AC_PROG_YACC
AC_PROG_MKDIR_P
AC_CONFIG_FILES([
Makefile
src/Makefile
......
......@@ -14,8 +14,6 @@ done
shift $(($OPTIND - 1))
BOXMOX_PATH=${KPP_HOME}/boxmox
# sanity checks
if $help
then
......@@ -28,16 +26,20 @@ fi
# check if BOXMOX is correctly set up
validate_BOXMOX_installation || { echo "Validating BOXMOX installation failed"; exit 1; }
BOXMOX_MECH_PATH=${BOXMOX_PATH}/compiled_mechs
BOXMOX_MECH_PATH=${KPP_HOME}/compiled_mechs
for mech in $(ls -1 -d ${BOXMOX_MECH_PATH}/*)
do
mechList+=($(basename $mech))
done
if [ -z $(ls -A ${BOXMOX_MECH_PATH}) ]; then
echo No mechanisms compiled yet.
else
for mech in $(find ${BOXMOX_MECH_PATH}/*)
do
mechList+=($(basename $mech))
done
fi
if $all
then
for mech in $(ls -1 ${BOXMOX_PATH}/models/*.eqn)
for mech in $(find ${KPP_HOME}/models/*.eqn)
do
mechi=$(basename $mech)
mechList+=(${mechi/.eqn/})
......@@ -46,4 +48,3 @@ fi
echo $( for i in "${mechList[@]}"; do echo $i; done | sort -u )
......@@ -12,8 +12,6 @@ done
shift $(($OPTIND - 1))
BOXMOX_PATH=${KPP_HOME}/boxmox
# sanity checks
if [[ $# -lt 1 ]] || [[ $# -gt 2 ]]
then
......@@ -29,9 +27,9 @@ mech_req=$1
# check if BOXMOX is correctly set up
validate_BOXMOX_installation || { echo "Validating BOXMOX installation failed"; exit 1; }
BOXMOX_MECH_PATH=${BOXMOX_PATH}/compiled_mechs
BOXMOX_MECH_PATH=${KPP_HOME}/compiled_mechs
default_nml=${BOXMOX_PATH}/examples/BOXMOX.nml
default_nml=${KPP_HOME}/case_studies/BOXMOX.nml
mech_path=${BOXMOX_MECH_PATH}/${mech_req}
mech_exe=${mech_path}/${mech_req}.exe
......
......@@ -12,15 +12,13 @@ done
shift $(($OPTIND - 1))
BOXMOX_PATH=${KPP_HOME}/boxmox
# sanity checks
if [[ $# -lt 1 ]] || [[ $# -gt 2 ]]
then
echo "Call with <example name> (<experiment path>)."
echo "If you omit <experiment path>, a subfolder with the name <example name> will be used."
echo "Use -f to force removal of existing experiment folder."
echo "Examples available: "$(find ${BOXMOX_PATH}/examples/* -maxdepth 1 -type d -exec basename {} \;)
echo "Examples available: "$(find ${KPP_HOME}/examples/* -maxdepth 1 -type d -exec basename {} \;)
exit 1
fi
......@@ -30,7 +28,7 @@ example_req=$1
# check if BOXMOX is correctly set up
validate_BOXMOX_installation || { echo "Validating BOXMOX installation failed"; exit 1; }
example_dir=${BOXMOX_PATH}/examples/${example_req}
example_dir=${KPP_HOME}/examples/${example_req}
# check if example exists
if [ ! -d ${example_dir} ]
......
......@@ -14,8 +14,6 @@ done
shift $(($OPTIND - 1))
BOXMOX_PATH=${KPP_HOME}/boxmox
# sanity checks
if [ $# -ne 1 ]
then
......@@ -32,7 +30,7 @@ mech_req=$1
# check if BOXMOX is correctly set up
validate_BOXMOX_installation || { echo "Validating BOXMOX installation failed."; exit 1; }
BOXMOX_MECH_PATH=${BOXMOX_PATH}/compiled_mechs
BOXMOX_MECH_PATH=${KPP_HOME}/compiled_mechs
work_path=${KPP_HOME}/tmp_${mech_req}_${RANDOM}_BOXMOX
......
......@@ -7,17 +7,15 @@
echo "Set it with"
echo ""
echo "export KPP_HOME=<full path to BOXMOX installation> (bash)"
echo "setenv KPP_HOME <full path to BOXMOX installation> (*csh)"
echo "setenv KPP_HOME <full path to BOXMOX installation > (*csh)"
echo ""
exit 1
}
BOXMOX_PATH=${KPP_HOME}/boxmox
[ ! -d ${BOXMOX_PATH} ] && {
[ ! -d ${KPP_HOME} ] && {
echo ""
echo "No BOXMOX found at ${BOXMOX_PATH}."
echo "No BOXMOX found at ${KPP_HOME}."
echo ""
echo "Please reinstall or correctly set the \$KPP_HOME environment variable."
echo ""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment