summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-07-15 08:52:24 +0000
committerStephen Hemminger <shemminger@vyatta.com>2011-08-31 10:56:12 -0700
commit44e743e588bcc737b7a2a5891f90279c58934ad7 (patch)
tree1b35a795a5402775280620e40583c2b6d4264ad3 /configure
parent05fb9184f2129c50cd0e406e9eda80509307af25 (diff)
Make iproute2 configure script more flexible
On Arch Linux, we still install the iptables shared libraries in /usr/lib/iptables/, even though the main library is installed to /usr/lib/libxtables.so. This change checks all available locations to correctly find the iptables library directory. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure11
1 files changed, 3 insertions, 8 deletions
diff --git a/configure b/configure
index 69797ab2..0795df85 100755
--- a/configure
+++ b/configure
@@ -3,8 +3,6 @@
#
INCLUDE=${1:-"$PWD/include"}
-TABLES=
-
check_atm()
{
cat >/tmp/atmtest.c <<EOF
@@ -141,9 +139,6 @@ check_ipt()
if ! grep TC_CONFIG_XT Config > /dev/null
then
echo "using iptables"
- TABLES="iptables"
- else
- TABLES="xtables"
fi
}
@@ -152,10 +147,10 @@ check_ipt_lib_dir()
IPT_LIB_DIR=""
for dir in /lib /usr/lib /usr/local/lib
do
- for file in $dir/$TABLES/lib*t_*so ; do
+ for file in $dir/{xtables,iptables}/lib*t_*so ; do
if [ -f $file ]; then
- echo $dir/$TABLES
- echo "IPT_LIB_DIR:=$dir/$TABLES" >> Config
+ echo ${file%/*}
+ echo "IPT_LIB_DIR:=${file%/*}" >> Config
return
fi
done