ghidra/Ghidra/RuntimeScripts/Linux/support/bsim_ctl
caheckman 0865a3dfb0 GP-4009 Introduced BSim functionality including support for postgresql,
elasticsearch and h2 databases.  Added BSim correlator to Version
Tracking.
2023-12-05 08:30:51 -05:00

30 lines
741 B
Bash
Executable file

#!/bin/bash
#
# Command-line script for controlling (start/stop) the BSim database
# maximum heap memory (may be increased)
MAXMEM=768M
# launch mode (fg, bg, debug, debug-suspend)
LAUNCH_MODE=fg
#set debug port for debug mode if used
OS=`uname -s`
MACHINE=`uname -m`
SED=/bin/sed
if [ "$OS" = "Darwin" ]; then
SED=/usr/bin/sed
fi
LAUNCH_DIR=`echo $0 | $SED -e 's/[^\/]*$//'`
if [ "$LAUNCH_DIR" = "" ]; then
LAUNCH_DIR="./";
fi
# Some JVM's with class data sharing enabled have issues with BSim starting with Ghidra's custom
# classloader, so we will disable sharing
VMARG_LIST="-Xshare:off"
${LAUNCH_DIR}launch.sh $LAUNCH_MODE jdk "BSimControl" $MAXMEM "${VMARG_LIST}" ghidra.features.bsim.query.BSimControlLaunchable "$@"