diff --git a/Shorewall-core/configure b/Shorewall-core/configure index 860976aa6..377c92073 100755 --- a/Shorewall-core/configure +++ b/Shorewall-core/configure @@ -180,7 +180,8 @@ for on in \ SYSCONFDIR \ SPARSE \ ANNOTATED \ - VARDIR + VARDIR \ + DIGEST do echo "$on=${options[${on}]}" echo "$on=${options[${on}]}" >> shorewallrc diff --git a/Shorewall-core/configure.pl b/Shorewall-core/configure.pl index 439c3ca7e..8485692f4 100755 --- a/Shorewall-core/configure.pl +++ b/Shorewall-core/configure.pl @@ -141,7 +141,8 @@ for ( qw/ HOST SYSCONFDIR SPARSE ANNOTATED - VARDIR / ) { + VARDIR + DIGEST / ) { my $val = $options{$_} || ''; diff --git a/Shorewall/install.sh b/Shorewall/install.sh index 9601e5ccb..941974517 100755 --- a/Shorewall/install.sh +++ b/Shorewall/install.sh @@ -250,9 +250,13 @@ OWNERSHIP="-o $OWNER -g $GROUP" if [ $PRODUCT = shorewall -a "$BUILD" = "$HOST" ]; then # - # Fix up 'use Digest::' if SHA is installed + # Fix up 'use Digest::' if SHA1 is installed # - if ! perl -e 'use Digest::SHA;' 2> /dev/null ; then + if [ -n "$DIGEST" ]; then + if [ "$DIGEST" != SHA ]; then + eval sed -i \'s/Digest::SHA/Digest::$DIGEST/\' Perl/Shorewall/Chains.pm + fi + elif ! perl -e 'use Digest::SHA;' 2> /dev/null ; then if perl -e 'use Digest::SHA1;' 2> /dev/null ; then sed -i 's/Digest::SHA/Digest::SHA1/' Perl/Shorewall/Chains.pm else