Testing the host's iptables-translate by default is unintuitive. Since
the ipset-translate symlink is created upon 'make install', add a local
symlink to the repository pointing at a built binary in src/. Using this
by default is consistent with the regular testsuite.
Signed-off-by: Phil Sutter <phil@nwl.cc>
--- /dev/null
+../../src/ipset
\ No newline at end of file
exit 1
fi
-IPSET_XLATE=$(which ipset-translate)
-if [ ! -x "$IPSET_XLATE" ] ; then
- echo "ERROR: ipset-translate is not installed yet"
- exit 1
-fi
+ipset_xlate=${IPSET_XLATE_BIN:-$(dirname $0)/ipset-translate}
TMP=$(mktemp)
-ipset-translate restore < xlate.t &> $TMP
+$ipset_xlate restore < xlate.t &> $TMP
if [ $? -ne 0 ]
then
cat $TMP