diff --git a/Shorewall-common/lib.base b/Shorewall-common/lib.base index 35a6da92d..5dfcd2b1c 100644 --- a/Shorewall-common/lib.base +++ b/Shorewall-common/lib.base @@ -1,6 +1,6 @@ #!/bin/sh # -# Shorewall 3.4 -- /usr/share/shorewall/lib.base +# Shorewall 4.0 -- /usr/share/shorewall/lib.base # # This program is under GPL [http://www.gnu.org/copyleft/gpl.htm] # diff --git a/Shorewall-perl/Shorewall/Compiler.pm b/Shorewall-perl/Shorewall/Compiler.pm index 6a14e88e8..a4ed682ed 100644 --- a/Shorewall-perl/Shorewall/Compiler.pm +++ b/Shorewall-perl/Shorewall/Compiler.pm @@ -122,30 +122,18 @@ sub generate_script_1() { } emitj ( 'initialize()', - '{' + '{', + ' #', + ' # These variables are required by the library functions called in this script', + ' #' ); push_indent; if ( $export ) { - emitj ( '#', - '# These variables are required by the library functions called in this script', - '#', - 'CONFIG_PATH="/etc/shorewall-lite:/usr/share/shorewall-lite"' ); + emit ( 'CONFIG_PATH="/etc/shorewall-lite:/usr/share/shorewall-lite"' ); } else { - emitj ( 'if [ ! -f ${SHAREDIR}/version ]; then', - ' fatal_error "This script requires Shorewall which do not appear to be installed on this system (did you forget \"-e\" when you compiled?)"', - 'fi', - '', - 'local version=$(cat ${SHAREDIR}/version)', - '', - 'if [ ${SHOREWALL_LIBVERSION:-0} -lt 30403 ]; then', - ' fatal_error "This script requires Shorewall version 3.4.3 or later; current version is $version"', - 'fi', - '#', - '# These variables are required by the library functions called in this script', - '#', - qq(CONFIG_PATH="$config{CONFIG_PATH}") ); + emit ( qq(CONFIG_PATH="$config{CONFIG_PATH}") ); } propagateconfig;