zeek/bro-path-dev.in
Jon Siwek abd92115f4 Add alternative way to set BROPATH for running bro from build/ dir.
Adds two extra shell scripts, one to handle either the c-shell
or bourne-shell syntax for setting environment variables, that can
be sourced in order to set the BROPATH directly in the current
shell/environment in a way that's compatible with running bro
from the build/ directory.
2011-03-02 14:14:07 -06:00

21 lines
838 B
Bash
Executable file

#!/bin/sh
# After configured by CMake, this file prints the absolute path to policy
# files that come with the source distributions of Bro and Broctl as well
# as policy files that are generated by the BIF compiler at compile time
#
# The intended use of this script is to make it easier to run Bro from
# the build directory, avoiding the need to install it. This could be
# done like:
#
# BROPATH=`./bro-path-dev` ./src/bro
#
broPolicies=${PROJECT_SOURCE_DIR}/policy:${PROJECT_SOURCE_DIR}/policy/sigs:${PROJECT_SOURCE_DIR}/policy/time-machine
broGenPolicies=${CMAKE_BINARY_DIR}/src
broctlPolicies=${PROJECT_SOURCE_DIR}/aux/broctl/policy:${CMAKE_BINARY_DIR}/aux/broctl/policy/local
installedPolicies=${POLICYDIR}:${POLICYDIR}/sigs:${POLICYDIR}/time-machine:${POLICYDIR}/site
echo .:$broPolicies:$broGenPolicies:$broctlPolicies