#!/bin/sh # # Shorewall 3.2 -- /usr/share/shorewall/functions # # This program is under GPL [http://www.gnu.org/copyleft/gpl.htm] # # (c) 1999,2000,2001,2002,2003,2004,2005,2006 - Tom Eastep (teastep@shorewall.net) # # Complete documentation is available at http://shorewall.net # # This program is free software; you can redistribute it and/or modify # it under the terms of Version 2 of the GNU General Public License # as published by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA LIBVERSION=30192 # # Load a run-time library # lib_load() # $1 = library name, $2=name of 'loaded' symbol, $3-n = Fatal Error Message { eval local loaded="\$${2}" if [ -z "$loaded" ]; then local lib=${SHAREDIR}/lib.${1} if [ -x $lib ]; then . $lib else shift 2 fatal_error "$@" fi fi } [ -n "${VARDIR:=/var/lib/shorewall}" ] [ -n "${SHAREDIR:=/usr/share/shorewall}" ] [ -n "${CONFDIR:=/etc/shorewall}" ] SHOREWALL_LIBRARY=Loaded lib_load base LIB_BASE_LOADED "Installation Error: ${SHAREDIR}/lib.base not found"